From 759b048287f6f242aca34555ca6bd19186912f90 Mon Sep 17 00:00:00 2001 From: tcit Date: Tue, 20 May 2014 16:25:29 +0200 Subject: [PATCH] changed everything from Poche to Wallabag --- .gitignore | 4 +-- README.md | 8 ++--- app/app.php | 20 +++++------ app/controllers/front.php | 26 +++++++------- app/views/_footer.twig | 2 +- app/views/_login.twig | 2 +- app/views/_top.twig | 2 +- app/views/layout.twig | 2 +- composer.json | 2 +- console | 4 +-- phpunit.xml | 2 +- .../Api/ContentFullTextRssApi.php | 4 +-- src/{Poche => Wallabag}/Api/EntryApi.php | 2 +- .../Command/CreateSchemaCommand.php | 4 +-- .../Command/UnitTestsCommand.php | 2 +- .../Controller/ArchiveController.php | 2 +- .../Controller/BookmarkController.php | 2 +- .../Controller/EntryController.php | 2 +- src/{Poche => Wallabag}/Model/Entry.php | 2 +- .../Repository/EntryRepository.php | 2 +- src/{Poche => Wallabag}/Schema.php | 6 ++-- src/{Poche => Wallabag}/Twig/Filter.php | 8 ++--- src/{Poche => Wallabag}/User/UserProvider.php | 2 +- .../Util/DummySingleItem.php | 2 +- .../Util/DummySingleItemFeed.php | 2 +- src/{Poche => Wallabag}/Util/Encoding.php | 2 +- src/{Poche => Wallabag}/Util/Token.php | 2 +- src/{Poche => Wallabag}/Util/Url.php | 10 +++--- .../Util/WallabagReadability.php} | 4 +-- tests/functionals/ApiTest.php | 6 ++-- tests/functionals/Fixtures.php | 4 +-- ...ebTestCase.php => WallabagWebTestCase.php} | 10 +++--- tests/functionals/bootstrap.php | 2 +- tests/units/Entry.php | 4 +-- tests/units/Token.php | 4 +-- web/assets/img/logo.png | Bin 1350 -> 2247 bytes web/assets/js/app.js | 8 ++--- web/assets/js/event.js | 34 +++++++++--------- web/assets/js/item.js | 18 +++++----- web/assets/js/nav.js | 2 +- 40 files changed, 113 insertions(+), 113 deletions(-) rename src/{Poche => Wallabag}/Api/ContentFullTextRssApi.php (83%) rename src/{Poche => Wallabag}/Api/EntryApi.php (98%) rename src/{Poche => Wallabag}/Command/CreateSchemaCommand.php (93%) rename src/{Poche => Wallabag}/Command/UnitTestsCommand.php (97%) rename src/{Poche => Wallabag}/Controller/ArchiveController.php (96%) rename src/{Poche => Wallabag}/Controller/BookmarkController.php (96%) rename src/{Poche => Wallabag}/Controller/EntryController.php (98%) rename src/{Poche => Wallabag}/Model/Entry.php (92%) rename src/{Poche => Wallabag}/Repository/EntryRepository.php (98%) rename src/{Poche => Wallabag}/Schema.php (96%) rename src/{Poche => Wallabag}/Twig/Filter.php (82%) rename src/{Poche => Wallabag}/User/UserProvider.php (98%) rename src/{Poche => Wallabag}/Util/DummySingleItem.php (96%) rename src/{Poche => Wallabag}/Util/DummySingleItemFeed.php (95%) rename src/{Poche => Wallabag}/Util/Encoding.php (96%) rename src/{Poche => Wallabag}/Util/Token.php (94%) rename src/{Poche => Wallabag}/Util/Url.php (98%) rename src/{Poche/Util/PocheReadability.php => Wallabag/Util/WallabagReadability.php} (94%) rename tests/functionals/{PocheWebTestCase.php => WallabagWebTestCase.php} (71%) diff --git a/.gitignore b/.gitignore index b3c377c..3c38f45 100644 --- a/.gitignore +++ b/.gitignore @@ -2,8 +2,8 @@ assets/* cache/* composer.phar composer.lock -poche.db -poche_test.db +wallabag.db +wallabag_test.db vendor/atoum vendor/bin vendor/autoload.php diff --git a/README.md b/README.md index e2c2b61..3ce6b4d 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ -# Poche v2 [![Build Status](https://travis-ci.org/inthepoche/poche.png?branch=v2-silex)](https://travis-ci.org/inthepoche/poche) +# wallabag v2 [![Build Status](https://api.travis-ci.org/wallabag/wallabag.png?branch=v2-silex)](https://travis-ci.org/wallabag/wallabag) -This is a Proof of Concept of Poche v2 using the PHP micro-framework [Silex](http://silex.sensiolabs.org). +This is a Proof of Concept of wallabag v2 using the PHP micro-framework [Silex](http://silex.sensiolabs.org). # Installation @@ -11,11 +11,11 @@ Get Composer and install Silex: Then configure your webserver to point to the `web/` directory. Some documentation is available on the [Silex documentation page](http://silex.sensiolabs.org/doc/web_servers.html). -If you are using PHP 5.4 you can run Poche v2 by using the embedded webserver: +If you are using PHP 5.4 you can run wallabag v2 by using the embedded webserver: php -S localhost:8080 -t web web/index.php -Poche should now be running at [http://localhost:8080](http://localhost:8080). +wallabag should now be running at [http://localhost:8080](http://localhost:8080). Then you should initialize your database by running: diff --git a/app/app.php b/app/app.php index 977fdab..fae3d64 100644 --- a/app/app.php +++ b/app/app.php @@ -1,9 +1,9 @@ before(function () use ($app) { }); $app['twig'] = $app->share($app->extend('twig', function($twig) { - $twig->addFilter(new Twig_SimpleFilter('getDomain', 'Poche\Twig\Filter::getDomain')); + $twig->addFilter(new Twig_SimpleFilter('getDomain', 'Wallabag\Twig\Filter::getDomain')); return $twig; })); $app['twig'] = $app->share($app->extend('twig', function($twig) { - $twig->addFilter(new Twig_SimpleFilter('getReadingTime', 'Poche\Twig\Filter::getReadingTime')); + $twig->addFilter(new Twig_SimpleFilter('getReadingTime', 'Wallabag\Twig\Filter::getReadingTime')); return $twig; })); $app['twig'] = $app->share($app->extend('twig', function($twig) { - $twig->addFilter(new Twig_SimpleFilter('getPicture', 'Poche\Twig\Filter::getPicture')); + $twig->addFilter(new Twig_SimpleFilter('getPicture', 'Wallabag\Twig\Filter::getPicture')); return $twig; })); $app->register(new ConsoleServiceProvider(), [ - 'console.name' => 'Poche console', + 'console.name' => 'Wallabag console', 'console.version' => '0.1', 'console.project_directory' => __DIR__.'/..', ]); @@ -46,7 +46,7 @@ $app->register(new ConsoleServiceProvider(), [ $app->register(new Silex\Provider\DoctrineServiceProvider(), array( 'db.options' => array( 'driver' => 'pdo_sqlite', - 'path' => __DIR__.'/../poche.db', + 'path' => __DIR__.'/../wallabag.db', ), )); @@ -67,7 +67,7 @@ $app->register(new SecurityServiceProvider(), array( 'form' => array('login_path' => '/', 'check_path' => 'login'), 'logout' => array('logout_path' => '/logout'), 'users' => $app->share(function() use ($app) { - return new Poche\User\UserProvider($app['db']); + return new Wallabag\User\UserProvider($app['db']); }), ), ), diff --git a/app/controllers/front.php b/app/controllers/front.php index 78cf6d7..a407e7f 100644 --- a/app/controllers/front.php +++ b/app/controllers/front.php @@ -1,34 +1,34 @@ get('/', 'Poche\Controller\EntryController::indexAction'); -$front->get('/view/{id}', 'Poche\Controller\EntryController::showAction') +$front->get('/', 'Wallabag\Controller\EntryController::indexAction'); +$front->get('/view/{id}', 'Wallabag\Controller\EntryController::showAction') ->bind('view_entry'); -$front->match('/add', 'Poche\Controller\EntryController::addAction') +$front->match('/add', 'Wallabag\Controller\EntryController::addAction') ->bind('add'); -$front->get('/remove/{id}', 'Poche\Controller\EntryController::removeAction') +$front->get('/remove/{id}', 'Wallabag\Controller\EntryController::removeAction') ->bind('remove_entry'); -$front->get('/restore/{id}', 'Poche\Controller\EntryController::restoreAction') +$front->get('/restore/{id}', 'Wallabag\Controller\EntryController::restoreAction') ->bind('restore_entry'); // bookmarks -$front->get('/bookmarks', 'Poche\Controller\BookmarkController::indexAction'); -$front->match('/star/{id}', 'Poche\Controller\BookmarkController::addAction') +$front->get('/bookmarks', 'Wallabag\Controller\BookmarkController::indexAction'); +$front->match('/star/{id}', 'Wallabag\Controller\BookmarkController::addAction') ->bind('star_entry'); -$front->match('/unstar/{id}', 'Poche\Controller\BookmarkController::removeAction') +$front->match('/unstar/{id}', 'Wallabag\Controller\BookmarkController::removeAction') ->bind('unstar_entry'); // archive -$front->get('/archive', 'Poche\Controller\ArchiveController::indexAction'); -$front->match('/mark-read/{id}', 'Poche\Controller\ArchiveController::readAction') +$front->get('/archive', 'Wallabag\Controller\ArchiveController::indexAction'); +$front->match('/mark-read/{id}', 'Wallabag\Controller\ArchiveController::readAction') ->bind('mark_entry_read'); -$front->match('/mark-unread/{id}', 'Poche\Controller\ArchiveController::unreadAction') +$front->match('/mark-unread/{id}', 'Wallabag\Controller\ArchiveController::unreadAction') ->bind('mark_entry_unread'); return $front; diff --git a/app/views/_footer.twig b/app/views/_footer.twig index 2d6c255..688bb87 100644 --- a/app/views/_footer.twig +++ b/app/views/_footer.twig @@ -1,3 +1,3 @@ diff --git a/app/views/_login.twig b/app/views/_login.twig index 097c290..3e852f7 100644 --- a/app/views/_login.twig +++ b/app/views/_login.twig @@ -2,7 +2,7 @@
{{ error }}
{% endif %}
-

+

\ No newline at end of file diff --git a/app/views/_top.twig b/app/views/_top.twig index 75c6698..380202b 100644 --- a/app/views/_top.twig +++ b/app/views/_top.twig @@ -3,7 +3,7 @@ {% endif %}