aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--Makefile11
-rw-r--r--application/SessionManager.php6
-rw-r--r--application/Updater.php1
-rw-r--r--doc/md/Download-and-Installation.md32
-rw-r--r--doc/md/Unit-tests.md10
-rw-r--r--inc/languages/fr/LC_MESSAGES/shaarli.po115
-rw-r--r--tests/SessionManagerTest.php31
-rw-r--r--tests/utils/FakeConfigManager.php12
-rw-r--r--tpl/default/img/apple-touch-icon.pngbin0 -> 18276 bytes
-rw-r--r--tpl/default/includes.html3
-rw-r--r--tpl/default/pluginsadmin.html18
11 files changed, 126 insertions, 113 deletions
diff --git a/Makefile b/Makefile
index c2d55946..d659d908 100644
--- a/Makefile
+++ b/Makefile
@@ -1,17 +1,6 @@
1# The personal, minimalist, super-fast, database free, bookmarking service. 1# The personal, minimalist, super-fast, database free, bookmarking service.
2# Makefile for PHP code analysis & testing, documentation and release generation 2# Makefile for PHP code analysis & testing, documentation and release generation
3 3
4# Prerequisites:
5# - install Composer, either:
6# - from your distro's package manager;
7# - from the official website (https://getcomposer.org/download/);
8# - install/update test dependencies:
9# $ composer install # 1st setup
10# $ composer update
11# - install Xdebug for PHPUnit code coverage reports:
12# - see http://xdebug.org/docs/install
13# - enable in php.ini
14
15BIN = vendor/bin 4BIN = vendor/bin
16PHP_SOURCE = index.php application tests plugins 5PHP_SOURCE = index.php application tests plugins
17PHP_COMMA_SOURCE = index.php,application,tests,plugins 6PHP_COMMA_SOURCE = index.php,application,tests,plugins
diff --git a/application/SessionManager.php b/application/SessionManager.php
index 3aa4ddfc..71f0b38d 100644
--- a/application/SessionManager.php
+++ b/application/SessionManager.php
@@ -12,12 +12,12 @@ class SessionManager
12 * Constructor 12 * Constructor
13 * 13 *
14 * @param array $session The $_SESSION array (reference) 14 * @param array $session The $_SESSION array (reference)
15 * @param ConfigManager $conf ConfigManager instance (reference) 15 * @param ConfigManager $conf ConfigManager instance
16 */ 16 */
17 public function __construct(& $session, & $conf) 17 public function __construct(& $session, $conf)
18 { 18 {
19 $this->session = &$session; 19 $this->session = &$session;
20 $this->conf = &$conf; 20 $this->conf = $conf;
21 } 21 }
22 22
23 /** 23 /**
diff --git a/application/Updater.php b/application/Updater.php
index bc859536..8d2bd577 100644
--- a/application/Updater.php
+++ b/application/Updater.php
@@ -443,6 +443,7 @@ class Updater
443 public function updateMethodReorderDatastore() 443 public function updateMethodReorderDatastore()
444 { 444 {
445 $this->linkDB->save($this->conf->get('resource.page_cache')); 445 $this->linkDB->save($this->conf->get('resource.page_cache'));
446 return true;
446 } 447 }
447} 448}
448 449
diff --git a/doc/md/Download-and-Installation.md b/doc/md/Download-and-Installation.md
index be848c97..e64d1a43 100644
--- a/doc/md/Download-and-Installation.md
+++ b/doc/md/Download-and-Installation.md
@@ -17,40 +17,44 @@ Using one of the following methods:
17- by cloning the Git repository 17- by cloning the Git repository
18- using Docker: [see the documentation](docker/shaarli-images) 18- using Docker: [see the documentation](docker/shaarli-images)
19 19
20--- 20--------------------------------------------------------------------------------
21 21
22## Latest release (recommended) 22## Latest release (recommended)
23
23### Download as an archive 24### Download as an archive
24Get the latest released version from the [releases](https://github.com/shaarli/Shaarli/releases) page.
25 25
26**Download our *shaarli-full* archive** to include dependencies. 26In most cases, you should download the latest Shaarli release from the [releases](https://github.com/shaarli/Shaarli/releases) page. **Download our *shaarli-full* archive** to include dependencies.
27 27
28The current latest released version is `v0.9.1` 28The current latest released version is `v0.9.1`
29 29
30Or in command lines:
31
32```bash 30```bash
33$ wget https://github.com/shaarli/Shaarli/releases/download/v0.9.1/shaarli-v0.9.1-full.zip 31$ wget https://github.com/shaarli/Shaarli/releases/download/v0.9.1/shaarli-v0.9.1-full.zip
34$ unzip shaarli-v0.9.1-full.zip 32$ unzip shaarli-v0.9.1-full.zip
35$ mv Shaarli /path/to/shaarli/ 33$ mv Shaarli /path/to/shaarli/
36``` 34```
37 35
38In most cases, download Shaarli from the [releases](https://github.com/shaarli/Shaarli/releases) page.
39Cloning using `git` or downloading Github branches as zip files requires additional steps (see below).
40
41### Using git 36### Using git
42 37
38Cloning using `git` or downloading Github branches as zip files requires additional steps:
39
40 * Install [Composer](Unit-tests.md#install_composer) to manage Shaarli dependencies.
41 * Install [python3-virtualenv](https://pypi.python.org/pypi/virtualenv) to build the local HTML documentation.
42
43``` 43```
44$ mkdir -p /path/to/shaarli && cd /path/to/shaarli/ 44$ mkdir -p /path/to/shaarli && cd /path/to/shaarli/
45$ git clone -b latest https://github.com/shaarli/Shaarli.git . 45$ git clone -b latest https://github.com/shaarli/Shaarli.git .
46$ composer install --no-dev --prefer-dist 46$ composer install --no-dev --prefer-dist
47$ make translate 47$ make translate
48$ make htmldoc
48``` 49```
49 50
51--------------------------------------------------------------------------------
52
50## Stable version 53## Stable version
51 54
52The stable version has been experienced by Shaarli users, and will receive security updates. 55The stable version has been experienced by Shaarli users, and will receive security updates.
53 56
57
54### Download as an archive 58### Download as an archive
55 59
56As a .zip archive: 60As a .zip archive:
@@ -69,9 +73,9 @@ $ tar xvf stable.tar.gz
69$ mv Shaarli-stable /path/to/shaarli/ 73$ mv Shaarli-stable /path/to/shaarli/
70``` 74```
71 75
72### Clone with Git 76### Using git
73 77
74[Composer](https://getcomposer.org/) is required to build a functional Shaarli installation when pulling from git. 78Install [Composer](Unit-tests.md#install_composer) to manage Shaarli dependencies.
75 79
76```bash 80```bash
77$ git clone https://github.com/shaarli/Shaarli.git -b stable /path/to/shaarli/ 81$ git clone https://github.com/shaarli/Shaarli.git -b stable /path/to/shaarli/
@@ -80,10 +84,15 @@ $ cd /path/to/shaarli/
80$ composer install --no-dev --prefer-dist 84$ composer install --no-dev --prefer-dist
81``` 85```
82 86
87
88--------------------------------------------------------------------------------
89
83## Development version (mainline) 90## Development version (mainline)
84 91
85_Use at your own risk!_ 92_Use at your own risk!_
86 93
94Install [Composer](Unit-tests.md#install_composer) to manage Shaarli dependencies.
95
87To get the latest changes from the `master` branch: 96To get the latest changes from the `master` branch:
88 97
89```bash 98```bash
@@ -93,8 +102,11 @@ $ git clone https://github.com/shaarli/Shaarli.git -b master /path/to/shaarli/
93$ cd /path/to/shaarli 102$ cd /path/to/shaarli
94$ composer install --no-dev --prefer-dist 103$ composer install --no-dev --prefer-dist
95$ make translate 104$ make translate
105$ make htmldoc
96``` 106```
97 107
108-------------------------------------------------------------------------------
109
98## Finish Installation 110## Finish Installation
99 111
100Once Shaarli is downloaded and files have been placed at the correct location, open it this location your favorite browser. 112Once Shaarli is downloaded and files have been placed at the correct location, open it this location your favorite browser.
diff --git a/doc/md/Unit-tests.md b/doc/md/Unit-tests.md
index d200634f..f6030d5c 100644
--- a/doc/md/Unit-tests.md
+++ b/doc/md/Unit-tests.md
@@ -2,12 +2,12 @@
2 2
3The framework used is [PHPUnit](https://phpunit.de/); it can be installed with [Composer](https://getcomposer.org/), which is a dependency management tool. 3The framework used is [PHPUnit](https://phpunit.de/); it can be installed with [Composer](https://getcomposer.org/), which is a dependency management tool.
4 4
5Regarding Composer, you can either use: 5### Install composer
6 6
7- a system-wide version, e.g. installed through your distro's package manager 7You can either use:
8- a local version, downloadable [here](https://getcomposer.org/download/)
9 8
10#### Sample usage 9- a system-wide version, e.g. installed through your distro's package manager
10- a local version, downloadable [here](https://getcomposer.org/download/).
11 11
12```bash 12```bash
13# system-wide version 13# system-wide version
@@ -29,6 +29,8 @@ $ composer update
29 29
30#### Install and enable Xdebug to generate PHPUnit coverage reports 30#### Install and enable Xdebug to generate PHPUnit coverage reports
31 31
32See http://xdebug.org/docs/install
33
32For Debian-based distros: 34For Debian-based distros:
33```bash 35```bash
34$ aptitude install php5-xdebug 36$ aptitude install php5-xdebug
diff --git a/inc/languages/fr/LC_MESSAGES/shaarli.po b/inc/languages/fr/LC_MESSAGES/shaarli.po
index 6b2de950..323c6111 100644
--- a/inc/languages/fr/LC_MESSAGES/shaarli.po
+++ b/inc/languages/fr/LC_MESSAGES/shaarli.po
@@ -1,8 +1,8 @@
1msgid "" 1msgid ""
2msgstr "" 2msgstr ""
3"Project-Id-Version: Shaarli\n" 3"Project-Id-Version: Shaarli\n"
4"POT-Creation-Date: 2017-10-22 13:13+0200\n" 4"POT-Creation-Date: 2017-11-11 10:59+0100\n"
5"PO-Revision-Date: 2017-10-22 13:14+0200\n" 5"PO-Revision-Date: 2017-11-11 11:00+0100\n"
6"Last-Translator: \n" 6"Last-Translator: \n"
7"Language-Team: Shaarli\n" 7"Language-Team: Shaarli\n"
8"Language: fr_FR\n" 8"Language: fr_FR\n"
@@ -161,11 +161,11 @@ msgstr ""
161"a été importé avec succès en %d secondes : %d liens importés, %d liens " 161"a été importé avec succès en %d secondes : %d liens importés, %d liens "
162"écrasés, %d liens ignorés." 162"écrasés, %d liens ignorés."
163 163
164#: application/PageBuilder.php:165 164#: application/PageBuilder.php:167
165msgid "The page you are trying to reach does not exist or has been deleted." 165msgid "The page you are trying to reach does not exist or has been deleted."
166msgstr "La page que vous essayez de consulter n'existe pas ou a été supprimée." 166msgstr "La page que vous essayez de consulter n'existe pas ou a été supprimée."
167 167
168#: application/PageBuilder.php:167 168#: application/PageBuilder.php:169
169msgid "404 Not Found" 169msgid "404 Not Found"
170msgstr "404 Introuvable" 170msgstr "404 Introuvable"
171 171
@@ -178,44 +178,44 @@ msgstr "Les fichiers de l'extension \"%s\" sont introuvables."
178msgid "Couldn't retrieve Updater class methods." 178msgid "Couldn't retrieve Updater class methods."
179msgstr "Impossible de récupérer les méthodes de la classe Updater." 179msgstr "Impossible de récupérer les méthodes de la classe Updater."
180 180
181#: application/Updater.php:485 181#: application/Updater.php:493
182msgid "An error occurred while running the update " 182msgid "An error occurred while running the update "
183msgstr "Une erreur s'est produite lors de l'exécution de la mise à jour " 183msgstr "Une erreur s'est produite lors de l'exécution de la mise à jour "
184 184
185#: application/Updater.php:525 185#: application/Updater.php:533
186msgid "Updates file path is not set, can't write updates." 186msgid "Updates file path is not set, can't write updates."
187msgstr "" 187msgstr ""
188"Le chemin vers le fichier de mise à jour n'est pas défini, impossible " 188"Le chemin vers le fichier de mise à jour n'est pas défini, impossible "
189"d'écrire les mises à jour." 189"d'écrire les mises à jour."
190 190
191#: application/Updater.php:530 191#: application/Updater.php:538
192msgid "Unable to write updates in " 192msgid "Unable to write updates in "
193msgstr "Impossible d'écrire les mises à jour dans " 193msgstr "Impossible d'écrire les mises à jour dans "
194 194
195#: application/Utils.php:406 tests/UtilsTest.php:398 195#: application/Utils.php:376 tests/UtilsTest.php:340
196msgid "Setting not set" 196msgid "Setting not set"
197msgstr "Paramètre non défini" 197msgstr "Paramètre non défini"
198 198
199#: application/Utils.php:413 tests/UtilsTest.php:396 tests/UtilsTest.php:397 199#: application/Utils.php:383 tests/UtilsTest.php:338 tests/UtilsTest.php:339
200msgid "Unlimited" 200msgid "Unlimited"
201msgstr "Illimité" 201msgstr "Illimité"
202 202
203#: application/Utils.php:416 tests/UtilsTest.php:393 tests/UtilsTest.php:394 203#: application/Utils.php:386 tests/UtilsTest.php:335 tests/UtilsTest.php:336
204#: tests/UtilsTest.php:408 204#: tests/UtilsTest.php:350
205msgid "B" 205msgid "B"
206msgstr "o" 206msgstr "o"
207 207
208#: application/Utils.php:416 tests/UtilsTest.php:387 tests/UtilsTest.php:388 208#: application/Utils.php:386 tests/UtilsTest.php:329 tests/UtilsTest.php:330
209#: tests/UtilsTest.php:395 209#: tests/UtilsTest.php:337
210msgid "kiB" 210msgid "kiB"
211msgstr "ko" 211msgstr "ko"
212 212
213#: application/Utils.php:416 tests/UtilsTest.php:389 tests/UtilsTest.php:390 213#: application/Utils.php:386 tests/UtilsTest.php:331 tests/UtilsTest.php:332
214#: tests/UtilsTest.php:406 tests/UtilsTest.php:407 214#: tests/UtilsTest.php:348 tests/UtilsTest.php:349
215msgid "MiB" 215msgid "MiB"
216msgstr "Mo" 216msgstr "Mo"
217 217
218#: application/Utils.php:416 tests/UtilsTest.php:391 tests/UtilsTest.php:392 218#: application/Utils.php:386 tests/UtilsTest.php:333 tests/UtilsTest.php:334
219msgid "GiB" 219msgid "GiB"
220msgstr "Go" 220msgstr "Go"
221 221
@@ -249,62 +249,62 @@ msgstr "Vous n'êtes pas autorisé à modifier la configuration."
249msgid "Error accessing" 249msgid "Error accessing"
250msgstr "Une erreur s'est produite en accédant à" 250msgstr "Une erreur s'est produite en accédant à"
251 251
252#: index.php:133 252#: index.php:135
253msgid "Shared links on " 253msgid "Shared links on "
254msgstr "Liens partagés sur " 254msgstr "Liens partagés sur "
255 255
256#: index.php:155 256#: index.php:157
257msgid "Insufficient permissions:" 257msgid "Insufficient permissions:"
258msgstr "Permissions insuffisantes :" 258msgstr "Permissions insuffisantes :"
259 259
260#: index.php:382 260#: index.php:384
261msgid "I said: NO. You are banned for the moment. Go away." 261msgid "I said: NO. You are banned for the moment. Go away."
262msgstr "NON. Vous êtes banni pour le moment. Revenez plus tard." 262msgstr "NON. Vous êtes banni pour le moment. Revenez plus tard."
263 263
264#: index.php:447 264#: index.php:449
265msgid "Wrong login/password." 265msgid "Wrong login/password."
266msgstr "Nom d'utilisateur ou mot de passe incorrects." 266msgstr "Nom d'utilisateur ou mot de passe incorrects."
267 267
268#: index.php:1107 268#: index.php:1092
269msgid "You are not supposed to change a password on an Open Shaarli." 269msgid "You are not supposed to change a password on an Open Shaarli."
270msgstr "" 270msgstr ""
271"Vous n'êtes pas censé modifier le mot de passe d'un Shaarli en mode ouvert." 271"Vous n'êtes pas censé modifier le mot de passe d'un Shaarli en mode ouvert."
272 272
273#: index.php:1112 index.php:1153 index.php:1229 index.php:1259 index.php:1359 273#: index.php:1097 index.php:1138 index.php:1214 index.php:1244 index.php:1344
274msgid "Wrong token." 274msgid "Wrong token."
275msgstr "Jeton invalide." 275msgstr "Jeton invalide."
276 276
277#: index.php:1117 277#: index.php:1102
278msgid "The old password is not correct." 278msgid "The old password is not correct."
279msgstr "L'ancien mot de passe est incorrect." 279msgstr "L'ancien mot de passe est incorrect."
280 280
281#: index.php:1137 281#: index.php:1122
282msgid "Your password has been changed" 282msgid "Your password has been changed"
283msgstr "Votre mot de passe a été modifié" 283msgstr "Votre mot de passe a été modifié"
284 284
285#: index.php:1190 285#: index.php:1175
286msgid "Configuration was saved." 286msgid "Configuration was saved."
287msgstr "La configuration a été sauvegardé." 287msgstr "La configuration a été sauvegardé."
288 288
289#: index.php:1241 289#: index.php:1226
290#, php-format 290#, php-format
291msgid "The tag was removed from %d link." 291msgid "The tag was removed from %d link."
292msgid_plural "The tag was removed from %d links." 292msgid_plural "The tag was removed from %d links."
293msgstr[0] "Le tag a été supprimé de %d lien." 293msgstr[0] "Le tag a été supprimé de %d lien."
294msgstr[1] "Le tag a été supprimé de %d liens." 294msgstr[1] "Le tag a été supprimé de %d liens."
295 295
296#: index.php:1242 296#: index.php:1227
297#, php-format 297#, php-format
298msgid "The tag was renamed in %d link." 298msgid "The tag was renamed in %d link."
299msgid_plural "The tag was renamed in %d links." 299msgid_plural "The tag was renamed in %d links."
300msgstr[0] "Le tag a été renommé dans %d lien." 300msgstr[0] "Le tag a été renommé dans %d lien."
301msgstr[1] "Le tag a été renommé dans %d liens." 301msgstr[1] "Le tag a été renommé dans %d liens."
302 302
303#: index.php:1458 303#: index.php:1443
304msgid "Note: " 304msgid "Note: "
305msgstr "Note : " 305msgstr "Note : "
306 306
307#: index.php:1567 307#: index.php:1552
308#, php-format 308#, php-format
309msgid "" 309msgid ""
310"The file you are trying to upload is probably bigger than what this " 310"The file you are trying to upload is probably bigger than what this "
@@ -314,7 +314,7 @@ msgstr ""
314"le serveur web peut accepter (%s). Merci de l'envoyer en parties plus " 314"le serveur web peut accepter (%s). Merci de l'envoyer en parties plus "
315"légères." 315"légères."
316 316
317#: index.php:1983 317#: index.php:1972
318#, php-format 318#, php-format
319msgid "" 319msgid ""
320"<pre>Sessions do not seem to work correctly on your server.<br>Make sure the " 320"<pre>Sessions do not seem to work correctly on your server.<br>Make sure the "
@@ -333,7 +333,7 @@ msgstr ""
333"cookies. Nous vous recommandons d'accéder à votre serveur depuis son adresse " 333"cookies. Nous vous recommandons d'accéder à votre serveur depuis son adresse "
334"IP ou un <em>Fully Qualified Domain Name</em>.<br>" 334"IP ou un <em>Fully Qualified Domain Name</em>.<br>"
335 335
336#: index.php:1993 336#: index.php:1982
337msgid "Click to try again." 337msgid "Click to try again."
338msgstr "Cliquer ici pour réessayer." 338msgstr "Cliquer ici pour réessayer."
339 339
@@ -608,84 +608,72 @@ msgstr "Continent"
608msgid "City" 608msgid "City"
609msgstr "Ville" 609msgstr "Ville"
610 610
611#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:163
612msgid "Redirector"
613msgstr "Redirecteur"
614
615#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:164
616msgid "e. g."
617msgstr "ex :"
618
619#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:164 611#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:164
620msgid "will mask the HTTP_REFERER"
621msgstr "masque le HTTP_REFERER"
622
623#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:179
624msgid "Disable session cookie hijacking protection" 612msgid "Disable session cookie hijacking protection"
625msgstr "Désactiver la protection contre le détournement de cookies" 613msgstr "Désactiver la protection contre le détournement de cookies"
626 614
627#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:181 615#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:166
628msgid "Check this if you get disconnected or if your IP address changes often" 616msgid "Check this if you get disconnected or if your IP address changes often"
629msgstr "" 617msgstr ""
630"Cocher cette case si vous êtes souvent déconnecté ou si votre adresse IP " 618"Cocher cette case si vous êtes souvent déconnecté ou si votre adresse IP "
631"change souvent" 619"change souvent"
632 620
633#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:198 621#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:183
634msgid "Private links by default" 622msgid "Private links by default"
635msgstr "Liens privés par défaut" 623msgstr "Liens privés par défaut"
636 624
637#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:199 625#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:184
638msgid "All new links are private by default" 626msgid "All new links are private by default"
639msgstr "Tous les nouveaux liens sont privés par défaut" 627msgstr "Tous les nouveaux liens sont privés par défaut"
640 628
641#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:214 629#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:199
642msgid "RSS direct links" 630msgid "RSS direct links"
643msgstr "Liens directs dans le flux RSS" 631msgstr "Liens directs dans le flux RSS"
644 632
645#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:215 633#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:200
646msgid "Check this to use direct URL instead of permalink in feeds" 634msgid "Check this to use direct URL instead of permalink in feeds"
647msgstr "" 635msgstr ""
648"Cocher cette case pour utiliser des liens directs au lieu des permaliens " 636"Cocher cette case pour utiliser des liens directs au lieu des permaliens "
649"dans le flux RSS" 637"dans le flux RSS"
650 638
651#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:230 639#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:215
652msgid "Hide public links" 640msgid "Hide public links"
653msgstr "Cacher les liens publics" 641msgstr "Cacher les liens publics"
654 642
655#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:231 643#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:216
656msgid "Do not show any links if the user is not logged in" 644msgid "Do not show any links if the user is not logged in"
657msgstr "N'afficher aucun lien sans être connecté" 645msgstr "N'afficher aucun lien sans être connecté"
658 646
659#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:246 647#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:231
660#: tmp/install.b91ef64efc3688266305ea9b42e5017e.rtpl.php:150 648#: tmp/install.b91ef64efc3688266305ea9b42e5017e.rtpl.php:150
661msgid "Check updates" 649msgid "Check updates"
662msgstr "Vérifier les mises à jour" 650msgstr "Vérifier les mises à jour"
663 651
664#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:247 652#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:232
665#: tmp/install.b91ef64efc3688266305ea9b42e5017e.rtpl.php:152 653#: tmp/install.b91ef64efc3688266305ea9b42e5017e.rtpl.php:152
666msgid "Notify me when a new release is ready" 654msgid "Notify me when a new release is ready"
667msgstr "Me notifier lorsqu'une nouvelle version est disponible" 655msgstr "Me notifier lorsqu'une nouvelle version est disponible"
668 656
669#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:262 657#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:247
670#: tmp/install.b91ef64efc3688266305ea9b42e5017e.rtpl.php:169 658#: tmp/install.b91ef64efc3688266305ea9b42e5017e.rtpl.php:169
671msgid "Enable REST API" 659msgid "Enable REST API"
672msgstr "Activer l'API REST" 660msgstr "Activer l'API REST"
673 661
674#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:263 662#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:248
675#: tmp/install.b91ef64efc3688266305ea9b42e5017e.rtpl.php:170 663#: tmp/install.b91ef64efc3688266305ea9b42e5017e.rtpl.php:170
676msgid "Allow third party software to use Shaarli such as mobile application" 664msgid "Allow third party software to use Shaarli such as mobile application"
677msgstr "" 665msgstr ""
678"Permets aux applications tierces d'utiliser Shaarli, par exemple les " 666"Permets aux applications tierces d'utiliser Shaarli, par exemple les "
679"applications mobiles" 667"applications mobiles"
680 668
681#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:278 669#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:263
682msgid "API secret" 670msgid "API secret"
683msgstr "Clé d'API secrète" 671msgstr "Clé d'API secrète"
684 672
685#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:289 673#: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:274
686#: tmp/editlink.b91ef64efc3688266305ea9b42e5017e.rtpl.php:74 674#: tmp/editlink.b91ef64efc3688266305ea9b42e5017e.rtpl.php:74
687#: tmp/pluginsadmin.b91ef64efc3688266305ea9b42e5017e.rtpl.php:139 675#: tmp/pluginsadmin.b91ef64efc3688266305ea9b42e5017e.rtpl.php:139
688#: tmp/pluginsadmin.b91ef64efc3688266305ea9b42e5017e.rtpl.php:192 676#: tmp/pluginsadmin.b91ef64efc3688266305ea9b42e5017e.rtpl.php:199
689msgid "Save" 677msgid "Save"
690msgstr "Enregistrer" 678msgstr "Enregistrer"
691 679
@@ -1130,6 +1118,10 @@ msgstr "dans la documentation"
1130msgid "Plugin configuration" 1118msgid "Plugin configuration"
1131msgstr "Configuration des extensions" 1119msgstr "Configuration des extensions"
1132 1120
1121#: tmp/pluginsadmin.b91ef64efc3688266305ea9b42e5017e.rtpl.php:195
1122msgid "No parameter available."
1123msgstr "Aucun paramètre disponible."
1124
1133#: tmp/tag.cloud.b91ef64efc3688266305ea9b42e5017e.rtpl.php:19 1125#: tmp/tag.cloud.b91ef64efc3688266305ea9b42e5017e.rtpl.php:19
1134#: tmp/tag.list.b91ef64efc3688266305ea9b42e5017e.rtpl.php:19 1126#: tmp/tag.list.b91ef64efc3688266305ea9b42e5017e.rtpl.php:19
1135msgid "tags" 1127msgid "tags"
@@ -1292,6 +1284,15 @@ msgstr ""
1292"Glisser ce lien dans votre barre de favoris ou cliquer droit dessus et « " 1284"Glisser ce lien dans votre barre de favoris ou cliquer droit dessus et « "
1293"Ajouter aux favoris »" 1285"Ajouter aux favoris »"
1294 1286
1287#~ msgid "Redirector"
1288#~ msgstr "Redirecteur"
1289
1290#~ msgid "e. g."
1291#~ msgstr "ex :"
1292
1293#~ msgid "will mask the HTTP_REFERER"
1294#~ msgstr "masque le HTTP_REFERER"
1295
1295#~ msgid "" 1296#~ msgid ""
1296#~ "An error occurred while parsing JSON configuration file (%s): error code #" 1297#~ "An error occurred while parsing JSON configuration file (%s): error code #"
1297#~ "%d" 1298#~ "%d"
diff --git a/tests/SessionManagerTest.php b/tests/SessionManagerTest.php
index a92c3ccc..aa75962a 100644
--- a/tests/SessionManagerTest.php
+++ b/tests/SessionManagerTest.php
@@ -1,4 +1,6 @@
1<?php 1<?php
2require_once 'tests/utils/FakeConfigManager.php';
3
2// Initialize reference data _before_ PHPUnit starts a session 4// Initialize reference data _before_ PHPUnit starts a session
3require_once 'tests/utils/ReferenceSessionIdHashes.php'; 5require_once 'tests/utils/ReferenceSessionIdHashes.php';
4ReferenceSessionIdHashes::genAllHashes(); 6ReferenceSessionIdHashes::genAllHashes();
@@ -8,18 +10,6 @@ use \PHPUnit\Framework\TestCase;
8 10
9 11
10/** 12/**
11 * Fake ConfigManager
12 */
13class FakeConfigManager
14{
15 public static function get($key)
16 {
17 return $key;
18 }
19}
20
21
22/**
23 * Test coverage for SessionManager 13 * Test coverage for SessionManager
24 */ 14 */
25class SessionManagerTest extends TestCase 15class SessionManagerTest extends TestCase
@@ -27,12 +17,16 @@ class SessionManagerTest extends TestCase
27 // Session ID hashes 17 // Session ID hashes
28 protected static $sidHashes = null; 18 protected static $sidHashes = null;
29 19
20 // Fake ConfigManager
21 protected static $conf = null;
22
30 /** 23 /**
31 * Assign reference data 24 * Assign reference data
32 */ 25 */
33 public static function setUpBeforeClass() 26 public static function setUpBeforeClass()
34 { 27 {
35 self::$sidHashes = ReferenceSessionIdHashes::getHashes(); 28 self::$sidHashes = ReferenceSessionIdHashes::getHashes();
29 self::$conf = new FakeConfigManager();
36 } 30 }
37 31
38 /** 32 /**
@@ -41,8 +35,7 @@ class SessionManagerTest extends TestCase
41 public function testGenerateToken() 35 public function testGenerateToken()
42 { 36 {
43 $session = []; 37 $session = [];
44 $conf = new FakeConfigManager(); 38 $sessionManager = new SessionManager($session, self::$conf);
45 $sessionManager = new SessionManager($session, $conf);
46 39
47 $token = $sessionManager->generateToken(); 40 $token = $sessionManager->generateToken();
48 41
@@ -61,9 +54,7 @@ class SessionManagerTest extends TestCase
61 $token => 1, 54 $token => 1,
62 ], 55 ],
63 ]; 56 ];
64 $conf = new FakeConfigManager(); 57 $sessionManager = new SessionManager($session, self::$conf);
65 $sessionManager = new SessionManager($session, $conf);
66
67 58
68 // check and destroy the token 59 // check and destroy the token
69 $this->assertTrue($sessionManager->checkToken($token)); 60 $this->assertTrue($sessionManager->checkToken($token));
@@ -79,8 +70,7 @@ class SessionManagerTest extends TestCase
79 public function testGenerateAndCheckToken() 70 public function testGenerateAndCheckToken()
80 { 71 {
81 $session = []; 72 $session = [];
82 $conf = new FakeConfigManager(); 73 $sessionManager = new SessionManager($session, self::$conf);
83 $sessionManager = new SessionManager($session, $conf);
84 74
85 $token = $sessionManager->generateToken(); 75 $token = $sessionManager->generateToken();
86 76
@@ -102,8 +92,7 @@ class SessionManagerTest extends TestCase
102 public function testCheckInvalidToken() 92 public function testCheckInvalidToken()
103 { 93 {
104 $session = []; 94 $session = [];
105 $conf = new FakeConfigManager(); 95 $sessionManager = new SessionManager($session, self::$conf);
106 $sessionManager = new SessionManager($session, $conf);
107 96
108 $this->assertFalse($sessionManager->checkToken('4dccc3a45ad9d03e5542b90c37d8db6d10f2b38b')); 97 $this->assertFalse($sessionManager->checkToken('4dccc3a45ad9d03e5542b90c37d8db6d10f2b38b'));
109 } 98 }
diff --git a/tests/utils/FakeConfigManager.php b/tests/utils/FakeConfigManager.php
new file mode 100644
index 00000000..f29760cb
--- /dev/null
+++ b/tests/utils/FakeConfigManager.php
@@ -0,0 +1,12 @@
1<?php
2
3/**
4 * Fake ConfigManager
5 */
6class FakeConfigManager
7{
8 public static function get($key)
9 {
10 return $key;
11 }
12}
diff --git a/tpl/default/img/apple-touch-icon.png b/tpl/default/img/apple-touch-icon.png
new file mode 100644
index 00000000..f29210ce
--- /dev/null
+++ b/tpl/default/img/apple-touch-icon.png
Binary files differ
diff --git a/tpl/default/includes.html b/tpl/default/includes.html
index 80c08333..b2bfec30 100644
--- a/tpl/default/includes.html
+++ b/tpl/default/includes.html
@@ -5,6 +5,7 @@
5<link rel="alternate" type="application/atom+xml" href="{$feedurl}?do=atom{$searchcrits}#" title="ATOM Feed" /> 5<link rel="alternate" type="application/atom+xml" href="{$feedurl}?do=atom{$searchcrits}#" title="ATOM Feed" />
6<link rel="alternate" type="application/rss+xml" href="{$feedurl}?do=rss{$searchcrits}#" title="RSS Feed" /> 6<link rel="alternate" type="application/rss+xml" href="{$feedurl}?do=rss{$searchcrits}#" title="RSS Feed" />
7<link href="img/favicon.png" rel="shortcut icon" type="image/png" /> 7<link href="img/favicon.png" rel="shortcut icon" type="image/png" />
8<link href="img/apple-touch-icon.png" rel="apple-touch-icon" sizes="180x180" />
8<link type="text/css" rel="stylesheet" href="css/pure.min.css?v={$version_hash}" /> 9<link type="text/css" rel="stylesheet" href="css/pure.min.css?v={$version_hash}" />
9<link type="text/css" rel="stylesheet" href="css/grids-responsive.min.css?v={$version_hash}"> 10<link type="text/css" rel="stylesheet" href="css/grids-responsive.min.css?v={$version_hash}">
10<link type="text/css" rel="stylesheet" href="css/pure-extras.css?v={$version_hash}"> 11<link type="text/css" rel="stylesheet" href="css/pure-extras.css?v={$version_hash}">
@@ -17,4 +18,4 @@
17{loop="$plugins_includes.css_files"} 18{loop="$plugins_includes.css_files"}
18 <link type="text/css" rel="stylesheet" href="{$value}?v={$version_hash}#"/> 19 <link type="text/css" rel="stylesheet" href="{$value}?v={$version_hash}#"/>
19{/loop} 20{/loop}
20<link rel="search" type="application/opensearchdescription+xml" href="?do=opensearch#" title="Shaarli search - {$shaarlititle}"/> \ No newline at end of file 21<link rel="search" type="application/opensearchdescription+xml" href="?do=opensearch#" title="Shaarli search - {$shaarlititle}"/>
diff --git a/tpl/default/pluginsadmin.html b/tpl/default/pluginsadmin.html
index 717cb517..ca17b435 100644
--- a/tpl/default/pluginsadmin.html
+++ b/tpl/default/pluginsadmin.html
@@ -27,7 +27,7 @@
27 27
28 <div> 28 <div>
29 {if="count($enabledPlugins)==0"} 29 {if="count($enabledPlugins)==0"}
30 <p>{'No plugin enabled.'|t}</p> 30 <p class="center">{'No plugin enabled.'|t}</p>
31 {else} 31 {else}
32 <table id="plugin_table"> 32 <table id="plugin_table">
33 <thead> 33 <thead>
@@ -77,7 +77,7 @@
77 77
78 <div> 78 <div>
79 {if="count($disabledPlugins)==0"} 79 {if="count($disabledPlugins)==0"}
80 <p>{'No plugin disabled.'|t}</p> 80 <p class="center">{'No plugin disabled.'|t}</p>
81 {else} 81 {else}
82 <table> 82 <table>
83 <thead> 83 <thead>
@@ -135,9 +135,11 @@
135 <section id="plugin_parameters"> 135 <section id="plugin_parameters">
136 <div> 136 <div>
137 {if="count($enabledPlugins)==0"} 137 {if="count($enabledPlugins)==0"}
138 <p>{'No plugin enabled.'|t}</p> 138 <p class="center">{'No plugin enabled.'|t}</p>
139 {else} 139 {else}
140 {$counter=0}
140 {loop="$enabledPlugins"} 141 {loop="$enabledPlugins"}
142 {$counter=$counter+count($value.parameters)}
141 {if="count($value.parameters) > 0"} 143 {if="count($value.parameters) > 0"}
142 <div class="plugin_parameters"> 144 <div class="plugin_parameters">
143 <h3 class="window-subtitle">{function="str_replace('_', ' ', $key)"}</h3> 145 <h3 class="window-subtitle">{function="str_replace('_', ' ', $key)"}</h3>
@@ -159,10 +161,14 @@
159 </div> 161 </div>
160 {/if} 162 {/if}
161 {/loop} 163 {/loop}
164 {if="$counter===0"}
165 <p class="center">{'No parameter available.'|t}</p>
166 {else}
167 <div class="center">
168 <input type="submit" name="parameters_form" value="{'Save'|t}"/>
169 </div>
170 {/if}
162 {/if} 171 {/if}
163 <div class="center">
164 <input type="submit" name="parameters_form" value="{'Save'|t}"/>
165 </div>
166 </div> 172 </div>
167 </section> 173 </section>
168 </div> 174 </div>