diff --git a/.gitattributes b/.gitattributes index 93900602..b191e227 100644 --- a/.gitattributes +++ b/.gitattributes @@ -22,6 +22,7 @@ Dockerfile text *.ttf binary *.min.css binary *.min.js binary +*.mo binary # Exclude from Git archives .editorconfig export-ignore diff --git a/.gitignore b/.gitignore index d546f248..3f6939a4 100644 --- a/.gitignore +++ b/.gitignore @@ -18,6 +18,7 @@ vendor/ # Release archives *.tar.gz *.zip +inc/languages/*/LC_MESSAGES/shaarli.mo # Development and test resources coverage diff --git a/.travis.yml b/.travis.yml index b6b9bddf..322e4337 100644 --- a/.travis.yml +++ b/.travis.yml @@ -13,6 +13,8 @@ install: - composer self-update - composer install --prefer-dist - locale -a +before_script: + - PATH=${PATH//:\.\/node_modules\/\.bin/} script: - make clean - make check_permissions diff --git a/Makefile b/Makefile index 300f1d7f..c2d55946 100644 --- a/Makefile +++ b/Makefile @@ -130,7 +130,7 @@ check_permissions: # See phpunit.xml for configuration # https://phpunit.de/manual/current/en/appendixes.configuration.html ## -test: +test: translate @echo "-------" @echo "PHPUNIT" @echo "-------" @@ -168,15 +168,15 @@ composer_dependencies: clean composer install --no-dev --prefer-dist find vendor/ -name ".git" -type d -exec rm -rf {} + -### generate a release tarball and include 3rd-party dependencies -release_tar: composer_dependencies htmldoc +### generate a release tarball and include 3rd-party dependencies and translations +release_tar: composer_dependencies htmldoc translate git archive --prefix=$(ARCHIVE_PREFIX) -o $(ARCHIVE_VERSION).tar HEAD tar rvf $(ARCHIVE_VERSION).tar --transform "s|^vendor|$(ARCHIVE_PREFIX)vendor|" vendor/ tar rvf $(ARCHIVE_VERSION).tar --transform "s|^doc/html|$(ARCHIVE_PREFIX)doc/html|" doc/html/ gzip $(ARCHIVE_VERSION).tar -### generate a release zip and include 3rd-party dependencies -release_zip: composer_dependencies htmldoc +### generate a release zip and include 3rd-party dependencies and translations +release_zip: composer_dependencies htmldoc translate git archive --prefix=$(ARCHIVE_PREFIX) -o $(ARCHIVE_VERSION).zip -9 HEAD mkdir -p $(ARCHIVE_PREFIX)/{doc,vendor} rsync -a doc/html/ $(ARCHIVE_PREFIX)doc/html/ @@ -213,3 +213,8 @@ htmldoc: mkdocs build' find doc/html/ -type f -exec chmod a-x '{}' \; rm -r venv + + +### Generate Shaarli's translation compiled file (.mo) +translate: + @find inc/languages/ -name shaarli.po -execdir msgfmt shaarli.po -o shaarli.mo \; \ No newline at end of file diff --git a/inc/languages/fr/LC_MESSAGES/shaarli.mo b/inc/languages/fr/LC_MESSAGES/shaarli.mo deleted file mode 100644 index d6b195da..00000000 Binary files a/inc/languages/fr/LC_MESSAGES/shaarli.mo and /dev/null differ diff --git a/inc/languages/fr/LC_MESSAGES/shaarli.po b/inc/languages/fr/LC_MESSAGES/shaarli.po index 8763581b..46b457e4 100644 --- a/inc/languages/fr/LC_MESSAGES/shaarli.po +++ b/inc/languages/fr/LC_MESSAGES/shaarli.po @@ -1,8 +1,8 @@ msgid "" msgstr "" "Project-Id-Version: Shaarli\n" -"POT-Creation-Date: 2017-05-20 13:54+0200\n" -"PO-Revision-Date: 2017-05-20 14:11+0200\n" +"POT-Creation-Date: 2017-05-20 15:36+0200\n" +"PO-Revision-Date: 2017-05-20 15:40+0200\n" "Last-Translator: \n" "Language-Team: Shaarli\n" "Language: fr_FR\n" @@ -16,17 +16,6 @@ msgstr "" "X-Poedit-KeywordsList: t:1,2;t\n" "X-Poedit-SearchPath-0: .\n" -#: application/ApplicationUtils.php:152 -#, php-format -msgid "" -"Your PHP version is obsolete! Shaarli requires at least PHP %s, and thus " -"cannot run. Your PHP version has known security vulnerabilities and should " -"be updated as soon as possible." -msgstr "" -"Votre version de PHP est obsolète ! Shaarli nécessite au moins PHP %s, et ne " -"peut donc pas fonctionner. Votre version de PHP a des failles de sécurités " -"connues et devrait être mise à jour au plus tôt." - #: application/ApplicationUtils.php:180 application/ApplicationUtils.php:192 msgid "directory is not readable" msgstr "le répertoire n'est pas accessible en lecture" @@ -54,8 +43,7 @@ msgstr "Liens directs" #: application/FeedBuilder.php:148 #: tmp/daily.b91ef64efc3688266305ea9b42e5017e.rtpl.php:88 -#: tmp/linklist.b91ef64efc3688266305ea9b42e5017e.rtpl.php:242 -#: tmp/linklist.b91ef64efc3688266305ea9b42e5017e.rtpl.php:245 +#: tmp/linklist.b91ef64efc3688266305ea9b42e5017e.rtpl.php:177 #: tmp/paper.b91ef64efc3688266305ea9b42e5017e.rtpl.php:88 msgid "Permalink" msgstr "Permalien" @@ -86,6 +74,7 @@ msgstr "La clé du tableau et l'ID du lien doivent être égaux." #: application/LinkDB.php:251 #: tmp/page.footer.cedf684561d925457130839629000a81.rtpl.php:14 +#: tmp/page.footer.cedf684561d925457130839629000a81.rtpl.php:45 msgid "" "The personal, minimalist, super-fast, database free, bookmarking service" msgstr "" @@ -153,8 +142,6 @@ msgid "The page you are trying to reach does not exist or has been deleted." msgstr "La page que vous essayez de consulter n'existe pas ou a été supprimée." #: application/PageBuilder.php:161 -#, fuzzy -#| msgid " 404 Not Found" msgid "404 Not Found" msgstr "404 Introuvable" @@ -208,22 +195,6 @@ msgstr "Mo" msgid "GiB" msgstr "Go" -#: application/config/ConfigJson.php:26 -#, php-format -msgid "" -"An error occurred while parsing JSON configuration file (%s): error code #%d" -msgstr "" -"Une erreur s'est produite lors de la lecture du fichier de configuration " -"JSON (%s) : code d'erreur #%d" - -#: application/config/ConfigJson.php:33 -msgid "" -"Please check your JSON syntax (without PHP comment tags) using a JSON lint " -"tool such as " -msgstr "" -"Merci de vérifier la syntaxe JSON (sans les balises de commentaires PHP) en " -"utilisant un validateur de JSON tel que " - #: application/config/ConfigJson.php:52 application/config/ConfigPhp.php:121 msgid "" "Shaarli could not create the config file. Please make sure Shaarli has the " @@ -254,22 +225,6 @@ msgstr "Vous n'êtes pas autorisé à modifier la configuration." msgid "Error accessing" msgstr "Une erreur s'est produite en accédant à" -#: index.php:48 -msgid "" -"Error: missing Composer dependencies\n" -"\n" -"If you installed Shaarli through Git or using the development branch,\n" -"please refer to the installation documentation to install PHP dependencies " -"using Composer:\n" -msgstr "" -"Erreur : les dépendances Composer sont manquantes\n" -"\n" -"Si vous avez installé Shaarli avec Git ou depuis la branche de " -"développement\n" -"merci de consulter la documentation d'installation pour installer les " -"dépendances Composer :\n" -"\n" - #: index.php:137 msgid "Shared links on " msgstr "Liens partagés sur " @@ -506,6 +461,23 @@ msgstr "URL de l'API Wallabag " msgid "Wallabag API version (1 or 2)" msgstr "Version de l'API Wallabag (1 ou 2)" +#: tests/LanguagesTest.php:186 tests/LanguagesTest.php:198 +#: tests/languages/fr/LanguagesFrTest.php:148 +#: tests/languages/fr/LanguagesFrTest.php:160 +msgid "car" +msgid_plural "car" +msgstr[0] "" +msgstr[1] "" + +#: tests/LanguagesTest.php:187 tests/LanguagesTest.php:199 +#: tests/languages/fr/LanguagesFrTest.php:149 +#: tests/languages/fr/LanguagesFrTest.php:161 +#: tmp/page.header.cedf684561d925457130839629000a81.rtpl.php:81 +msgid "Search" +msgid_plural "Search" +msgstr[0] "Rechercher" +msgstr[1] "Rechercher" + #: tmp/addlink.b91ef64efc3688266305ea9b42e5017e.rtpl.php:13 msgid "Shaare a new link" msgstr "Partager un nouveau lien" @@ -556,8 +528,7 @@ msgstr "Renommer" #: tmp/changetag.b91ef64efc3688266305ea9b42e5017e.rtpl.php:35 #: tmp/editlink.90100d2eaf5d3705e14b9b4f78ecddc9.rtpl.php:60 #: tmp/editlink.b91ef64efc3688266305ea9b42e5017e.rtpl.php:71 -#: tmp/linklist.b91ef64efc3688266305ea9b42e5017e.rtpl.php:288 -#: tmp/linklist.b91ef64efc3688266305ea9b42e5017e.rtpl.php:313 +#: tmp/linklist.b91ef64efc3688266305ea9b42e5017e.rtpl.php:171 msgid "Delete" msgstr "Supprimer" @@ -727,7 +698,7 @@ msgstr "Tags" #: tmp/editlink.b91ef64efc3688266305ea9b42e5017e.rtpl.php:52 #: tmp/export.b91ef64efc3688266305ea9b42e5017e.rtpl.php:36 -#: tmp/linklist.b91ef64efc3688266305ea9b42e5017e.rtpl.php:177 +#: tmp/linklist.b91ef64efc3688266305ea9b42e5017e.rtpl.php:167 msgid "Private" msgstr "Privé" @@ -885,22 +856,27 @@ msgstr "Retirer le tag" msgid "with status" msgstr "avec le statut" -#: tmp/linklist.b91ef64efc3688266305ea9b42e5017e.rtpl.php:181 +#: tmp/linklist.b91ef64efc3688266305ea9b42e5017e.rtpl.php:169 msgid "Edit" msgstr "Modifier" -#: tmp/linklist.b91ef64efc3688266305ea9b42e5017e.rtpl.php:182 +#: tmp/linklist.b91ef64efc3688266305ea9b42e5017e.rtpl.php:173 +#: tmp/page.footer.cedf684561d925457130839629000a81.rtpl.php:39 msgid "Fold" msgstr "Replier" -#: tmp/linklist.b91ef64efc3688266305ea9b42e5017e.rtpl.php:245 +#: tmp/linklist.b91ef64efc3688266305ea9b42e5017e.rtpl.php:175 msgid "Edited: " msgstr "Modifié :" -#: tmp/linklist.b91ef64efc3688266305ea9b42e5017e.rtpl.php:257 +#: tmp/linklist.b91ef64efc3688266305ea9b42e5017e.rtpl.php:179 msgid "permalink" msgstr "permalien" +#: tmp/linklist.b91ef64efc3688266305ea9b42e5017e.rtpl.php:181 +msgid "Add tag" +msgstr "Ajouter un tag" + #: tmp/linklist.paging.cedf684561d925457130839629000a81.rtpl.php:7 msgid "Filters" msgstr "Filtres" @@ -909,6 +885,11 @@ msgstr "Filtres" msgid "Filter private links" msgstr "Filtrer par liens privés" +#: tmp/linklist.paging.cedf684561d925457130839629000a81.rtpl.php:18 +#: tmp/page.footer.cedf684561d925457130839629000a81.rtpl.php:40 +msgid "Fold all" +msgstr "Replier tout" + #: tmp/linklist.paging.cedf684561d925457130839629000a81.rtpl.php:63 msgid "Links per page" msgstr "Liens par page" @@ -933,6 +914,7 @@ msgid "Remember me" msgstr "Rester connecté" #: tmp/page.footer.cedf684561d925457130839629000a81.rtpl.php:14 +#: tmp/page.footer.cedf684561d925457130839629000a81.rtpl.php:45 msgid "by the Shaarli community" msgstr "par la communauté Shaarli" @@ -940,6 +922,18 @@ msgstr "par la communauté Shaarli" msgid "Documentation" msgstr "Documentation" +#: tmp/page.footer.cedf684561d925457130839629000a81.rtpl.php:41 +msgid "Expand" +msgstr "Déplier" + +#: tmp/page.footer.cedf684561d925457130839629000a81.rtpl.php:42 +msgid "Expand all" +msgstr "Déplier tout" + +#: tmp/page.footer.cedf684561d925457130839629000a81.rtpl.php:43 +msgid "Are you sure you want to delete this link?" +msgstr "Êtes-vous sûr de vouloir supprimer ce lien ?" + #: tmp/page.header.cedf684561d925457130839629000a81.rtpl.php:31 msgid "Tools" msgstr "Outils" @@ -968,10 +962,6 @@ msgstr "Flux RSS" msgid "Logout" msgstr "Déconnexion" -#: tmp/page.header.cedf684561d925457130839629000a81.rtpl.php:81 -msgid "Search" -msgstr "Rechercher" - #: tmp/page.header.cedf684561d925457130839629000a81.rtpl.php:171 msgid "is available" msgstr "est disponible" @@ -1198,6 +1188,44 @@ msgstr "" "Glisser ce lien dans votre barre de favoris ou cliquer droit dessus et « " "Ajouter aux favoris »" +#~ msgid "" +#~ "Your PHP version is obsolete! Shaarli requires at least PHP %s, and thus " +#~ "cannot run. Your PHP version has known security vulnerabilities and " +#~ "should be updated as soon as possible." +#~ msgstr "" +#~ "Votre version de PHP est obsolète ! Shaarli nécessite au moins PHP %s, et " +#~ "ne peut donc pas fonctionner. Votre version de PHP a des failles de " +#~ "sécurités connues et devrait être mise à jour au plus tôt." + +#~ msgid "" +#~ "An error occurred while parsing JSON configuration file (%s): error code #" +#~ "%d" +#~ msgstr "" +#~ "Une erreur s'est produite lors de la lecture du fichier de configuration " +#~ "JSON (%s) : code d'erreur #%d" + +#~ msgid "" +#~ "Please check your JSON syntax (without PHP comment tags) using a JSON " +#~ "lint tool such as " +#~ msgstr "" +#~ "Merci de vérifier la syntaxe JSON (sans les balises de commentaires PHP) " +#~ "en utilisant un validateur de JSON tel que " + +#~ msgid "" +#~ "Error: missing Composer dependencies\n" +#~ "\n" +#~ "If you installed Shaarli through Git or using the development branch,\n" +#~ "please refer to the installation documentation to install PHP " +#~ "dependencies using Composer:\n" +#~ msgstr "" +#~ "Erreur : les dépendances Composer sont manquantes\n" +#~ "\n" +#~ "Si vous avez installé Shaarli avec Git ou depuis la branche de " +#~ "développement\n" +#~ "merci de consulter la documentation d'installation pour installer les " +#~ "dépendances Composer :\n" +#~ "\n" + #~ msgid "Sessions do not seem to work correctly on your server." #~ msgstr "Les sessions ne semblent "