diff --git a/README.md b/README.md
index 8dd93ec80a544f32ee9420b3903534a9baccd436..16b079c36573a5f02afb9c6342b8a71d4822be43 100644
--- a/README.md
+++ b/README.md
@@ -134,7 +134,7 @@ To build Cesium, you will have to:
       
   - Installing node.js build tools:
 ```
-   npm install -g gulp bower cordova ionic@1.7.16
+   npm install -g gulp bower@1.8.0 cordova@6.5.0 ionic@1.7.16
 ```
    
 ### Source code
diff --git a/config.xml b/config.xml
index f62f08785fa4ff0c903912bb7e95f703635478a4..f0253cb6c6f0a652054e570ca14af44437040572 100644
--- a/config.xml
+++ b/config.xml
@@ -94,20 +94,20 @@
     <platform name="ubuntu">
         <icon height="57" src="www/img/logo_57px.png" width="57" />
     </platform>
-    <plugin name="cordova-plugin-camera" spec="~2.2.0" />
-    <plugin name="cordova-plugin-console" spec="~1.0.3" />
-    <plugin name="cordova-plugin-device" spec="~1.1.2" />
-    <plugin name="cordova-plugin-dialogs" spec="~1.2.1" />
-    <plugin name="cordova-plugin-inappbrowser" spec="~1.6.1" />
-    <plugin name="cordova-plugin-minisodium" spec="~1.0.0" />
-    <plugin name="cordova-plugin-secure-storage" spec="~2.6.3" />
-    <plugin name="cordova-plugin-splashscreen" spec="~3.2.2" />
-    <plugin name="cordova-plugin-statusbar" spec="~2.1.3" />
-    <plugin name="cordova-plugin-vibration" spec="~2.1.1" />
-    <plugin name="cordova-plugin-websocket" spec="~0.12.0" />
-    <plugin name="cordova-plugin-whitelist" spec="~1.2.2" />
-    <plugin name="cordova-plugin-x-toast" spec="~2.6.0" />
-    <plugin name="ionic-plugin-keyboard" spec="~2.2.1" />
+    <plugin name="cordova-plugin-camera" spec="^2.4.1" />
+    <plugin name="cordova-plugin-console" spec="^1.0.7" />
+    <plugin name="cordova-plugin-device" spec="^1.1.6" />
+    <plugin name="cordova-plugin-dialogs" spec="^1.3.3" />
+    <plugin name="cordova-plugin-inappbrowser" spec="^1.6.1" />
+    <plugin name="cordova-plugin-minisodium" spec="^1.0.0" />
+    <plugin name="cordova-plugin-secure-storage" spec="^2.6.8" />
+    <plugin name="cordova-plugin-splashscreen" spec="^3.2.2" />
+    <plugin name="cordova-plugin-statusbar" spec="^2.2.3" />
+    <plugin name="cordova-plugin-vibration" spec="^2.1.5" />
+    <plugin name="cordova-plugin-websocket" spec="^0.12.2" />
+    <plugin name="cordova-plugin-whitelist" spec="^1.3.2" />
+    <plugin name="cordova-plugin-x-toast" spec="^2.6.0" />
+    <plugin name="ionic-plugin-keyboard" spec="^2.2.1" />
     <plugin name="phonegap-plugin-barcodescanner" spec="git+https://github.com/phonegap/phonegap-plugin-barcodescanner.git">
         <variable name="CAMERA_USAGE_DESCRIPTION" value=" " />
     </plugin>
diff --git a/doc/fr/development_tutorial-01.md b/doc/fr/development_tutorial-01.md
index a59badc1ebad445bf53bccafa3ef3a664a25aeae..ed50c0b0ed3d196f935ac4eeddf4338a80202807 100644
--- a/doc/fr/development_tutorial-01.md
+++ b/doc/fr/development_tutorial-01.md
@@ -126,13 +126,13 @@ cd cesium
 Puis, lancez le téléchargement et l'installation des modules Cesium à l'aide de la commande : 
 
 ```bash
-npm install -g bower gulp ionic cordova
+npm install -g gulp bower@1.8.0 cordova@6.5.0 ionic@1.7.16
 ```
 
 Puis pour les dépendances non globales :
 
 ```bash
-npm install
+npm installion
 ```
 
 > Le processus d'installation peut prendre plusieurs minutes. En effet, il faut télécharger toutes les dépendances de Cesium et même en compiler certaines.
diff --git a/hooks/after_prepare/020_remove_code.js b/hooks/after_prepare/020_remove_code.js
index 8b81ae40bbef3573fcfc9a78edd43ccdc48a4566..37c3c2f8c701156bbe5e831d0d7b80ab9d6d9c12 100755
--- a/hooks/after_prepare/020_remove_code.js
+++ b/hooks/after_prepare/020_remove_code.js
@@ -28,23 +28,35 @@ if (rootdir) {
 
     var pluginPath = path.join(wwwPath, 'plugins') + '/es';
 
-    process.stdout.write('Removing unused code for device \n');
+    // Log
+    //console.log('['+process.mainModule.filename+'] Removing code for platform '+platform+'\n');
 
     // Compute options {device-<platform>: true}
     var platformRemoveCodeOptions = {};
     platformRemoveCodeOptions[platform] = true; // = {<platform>: true}
 
+    var htmlminOptions = {removeComments: true, collapseWhitespace: true};
+
     // Removing unused code for device...
     es.concat(
       // Remove unused HTML tags
-      gulp.src([wwwPath + '/templates/**/*.html', pluginPath + '/templates/**/*.html'])
+      gulp.src(path.join(wwwPath, 'templates', '**', '*.html'))
+        .pipe(removeCode({device: true}))
+        .pipe(removeCode(platformRemoveCodeOptions))
+        .pipe(removeHtml('.hidden-xs.hidden-sm'))
+        .pipe(removeHtml('.hidden-device'))
+        .pipe(removeHtml('[remove-if][remove-if="device"]'))
+        .pipe(htmlmin(htmlminOptions))
+        .pipe(gulp.dest(wwwPath + '/templates')),
+
+      gulp.src(path.join(pluginPath, '**', '*.html'))
         .pipe(removeCode({device: true}))
         .pipe(removeCode(platformRemoveCodeOptions))
         .pipe(removeHtml('.hidden-xs.hidden-sm'))
         .pipe(removeHtml('.hidden-device'))
         .pipe(removeHtml('[remove-if][remove-if="device"]'))
-        .pipe(htmlmin())
-        .pipe(gulp.dest(".")),
+        .pipe(htmlmin(htmlminOptions))
+        .pipe(gulp.dest(pluginPath)),
 
       gulp.src(path.join(wwwPath, 'index.html'))
         .pipe(removeCode({device: true}))
@@ -52,11 +64,11 @@ if (rootdir) {
         .pipe(removeHtml('.hidden-xs.hidden-sm'))
         .pipe(removeHtml('.hidden-device'))
         .pipe(removeHtml('[remove-if][remove-if="device"]'))
-        .pipe(htmlmin())
+        .pipe(htmlmin(/*no options, to build comments*/))
         .pipe(gulp.dest(wwwPath)),
 
       // Remove unused JS code + add ng annotations
-      gulp.src([wwwPath + '/js/**/*.js'])
+      gulp.src(path.join(wwwPath, 'js', '**', '*.js'))
         .pipe(removeCode({device: true}))
         .pipe(removeCode(platformRemoveCodeOptions))
         .pipe(ngAnnotate({single_quotes: true}))
diff --git a/hooks/after_prepare/021_template_cache.js b/hooks/after_prepare/021_template_cache.js
index 13d7245bb59c2c657b1473dbdb5acaee3c212f60..ca22e0fb33c7112caa5cb15218d4b9446743d047 100755
--- a/hooks/after_prepare/021_template_cache.js
+++ b/hooks/after_prepare/021_template_cache.js
@@ -27,7 +27,7 @@ if (rootdir) {
 
     // Concat templates into a JS
     es.concat(
-      gulp.src(wwwPath + 'templates/**/*.html')
+      gulp.src(path.join(wwwPath, 'templates', '**', '*.html'))
         .pipe(templateCache({
           standalone:true,
           module:"cesium.templates",
@@ -35,11 +35,11 @@ if (rootdir) {
          }))
         .pipe(gulp.dest(distJsPath)),
 
-       gulp.src(wwwPath + 'plugins/*/templates/**/*.html')
+       gulp.src(path.join(wwwPath, 'plugins', '*', 'templates', '**', '*.html'))
          .pipe(templateCache({
            standalone:true,
            module:"cesium.plugins.templates",
-           root: "templates/"
+           root: "plugins/"
           }))
          .pipe(gulp.dest(pluginDistJsPath))
      );
diff --git a/hooks/after_prepare/050_clean_unused_directories.js b/hooks/after_prepare/050_clean_unused_directories.js
index ac1ba1d57ad61de55126dfce68870d7902f21120..7438efd3f9666f8127c98e994348bcaf4a5c2cc6 100755
--- a/hooks/after_prepare/050_clean_unused_directories.js
+++ b/hooks/after_prepare/050_clean_unused_directories.js
@@ -31,8 +31,10 @@ if (rootdir && !skip) {
       wwwPath = path.join(rootdir, 'platforms', platform, 'www');
     }
 
+    // Log
+    //console.log('['+process.mainModule.filename+'] Cleaning unused directories');
+
     // Clean unused directories
-    console.log('Cleaning dir ' + path.join(wwwPath, 'lib', '**'));
     del([
       path.join(wwwPath, 'i18n'),
       path.join(wwwPath, 'js'),
diff --git a/package.json b/package.json
index 6cfa637a713c1b908e3d9d47ce86ffd47b1bfb7d..b32113aa0f547a897bba1d7faa5106becb9fec8a 100644
--- a/package.json
+++ b/package.json
@@ -1,136 +1,137 @@
 {
-  "name": "cesium",
-  "version": "0.14.0",
-  "description": "Unhosted webapp client for Duniter network",
-  "repository": {
-    "type": "git",
-    "url": "git@github.com:duniter/cesium.git"
-  },
-  "scripts": {
-    "postinstall": "bower install",
-    "install-for-mobile": "ionic state restore",
-    "start": "ionic serve"
-  },
-  "keywords": [
-    "duniter",
-    "cesium",
-    "ionic",
-    "angular",
-    "cordova",
-    "crypto-currency"
-  ],
-  "author": "Duniter team",
-  "license": "GPL-3.0",
-  "readmeFilename": "README.md",
-  "bugs": {
-    "url": "https://github.com/duniter/cesium/issues",
-    "new": "https://github.com/duniter/cesium/issues/new?labels=bug"
-  },
-  "dependencies": {
-    "bower": "^1.8.0",
-    "cordova-plugin-camera": "~2.2.0",
-    "cordova-plugin-console": "~1.0.3",
-    "cordova-plugin-device": "~1.1.2",
-    "cordova-plugin-dialogs": "~1.2.1",
-    "cordova-plugin-inappbrowser": "~1.6.1",
-    "cordova-plugin-minisodium": "~1.0.0",
-    "cordova-plugin-secure-storage": "~2.6.3",
-    "cordova-plugin-splashscreen": "~3.2.2",
-    "cordova-plugin-statusbar": "~2.1.3",
-    "cordova-plugin-vibration": "~2.1.1",
-    "cordova-plugin-websocket": "~0.12.0",
-    "cordova-plugin-whitelist": "~1.2.2",
-    "cordova-plugin-x-toast": "~2.6.0",
-    "delete-empty": "^0.1.3",
-    "gulp": "^3.9.1",
-    "gulp-bump": "^2.1.0",
-    "gulp-concat": "^2.2.0",
-    "gulp-rename": "^1.2.0",
-    "gulp-sass": "^2.2.0",
-    "ionic": "^1.7.16",
-    "ionic-plugin-keyboard": "~2.2.1",
-    "node-sass": "^3.3.3",
-    "phonegap-plugin-barcodescanner": "git+https://github.com/phonegap/phonegap-plugin-barcodescanner.git"
-  },
-  "devDependencies": {
-    "cordova-uglify": "^0.2.3",
-    "del": "^2.2.0",
-    "fs": "0.0.2",
-    "gulp": "^3.9.1",
-    "gulp-angular-templatecache": "^1.8.0",
-    "gulp-angular-translate": "^0.1.4",
-    "gulp-base64": "^0.1.3",
-    "gulp-clean": "^0.3.2",
-    "gulp-clean-css": "^2.0.10",
-    "gulp-css-base64": "^1.3.4",
-    "gulp-csso": "^2.0.0",
-    "gulp-filter": "^4.0.0",
-    "gulp-header": "^1.7.1",
-    "gulp-html-remove": "^0.1.1",
-    "gulp-htmlmin": "^2.0.0",
-    "gulp-jshint": "^2.0.1",
-    "gulp-ng-annotate": "^2.0.0",
-    "gulp-ng-constant": "^1.1.0",
-    "gulp-remove-code": "^1.0.2",
-    "gulp-replace": "^0.5.4",
-    "gulp-rev": "^7.0.0",
-    "gulp-rev-replace": "^0.4.3",
-    "gulp-sourcemaps": "^1.6.0",
-    "gulp-uglify": "^1.5.3",
-    "gulp-useref": "^3.1.0",
-    "gulp-util": "^2.2.14",
-    "gulp-zip": "^3.2.0",
-    "ionic-minify": "^2.0.8",
-    "jshint": "^2.9.2",
-    "mv": "^2.1.1",
-    "playup": "^1.0.2",
-    "shelljs": "^0.3.0",
-    "yargs": "^4.3.1"
-  },
-  "cordovaPlugins": [
-    "cordova-plugin-whitelist",
-    "cordova-plugin-splashscreen",
-    "cordova-plugin-console",
-    "ionic-plugin-keyboard",
-    "cordova-plugin-device",
-    "cordova-plugin-statusbar",
-    "cordova-plugin-camera",
-    "cordova-plugin-websocket",
-    "cordova-plugin-vibration",
-    "cordova-plugin-dialogs",
-    "cordova-plugin-minisodium",
-    "cordova-plugin-secure-storage",
-    {
-      "locator": "https://github.com/phonegap/phonegap-plugin-barcodescanner.git",
-      "id": "phonegap-plugin-barcodescanner"
+    "name": "cesium",
+    "version": "0.14.0",
+    "description": "Unhosted webapp client for Duniter network",
+    "repository": {
+        "type": "git",
+        "url": "git@github.com:duniter/cesium.git"
     },
-    "cordova-plugin-inappbrowser",
-    "cordova-plugin-x-toast"
-  ],
-  "cordovaPlatforms": [
-    "ios",
-    "android",
-    "firefoxos"
-  ],
-  "cordova": {
-    "plugins": {
-      "cordova-plugin-camera": {},
-      "cordova-plugin-console": {},
-      "cordova-plugin-device": {},
-      "cordova-plugin-dialogs": {},
-      "cordova-plugin-inappbrowser": {},
-      "cordova-plugin-minisodium": {},
-      "cordova-plugin-secure-storage": {},
-      "cordova-plugin-splashscreen": {},
-      "cordova-plugin-statusbar": {},
-      "cordova-plugin-vibration": {},
-      "cordova-plugin-websocket": {},
-      "cordova-plugin-whitelist": {},
-      "cordova-plugin-x-toast": {},
-      "ionic-plugin-keyboard": {},
-      "phonegap-plugin-barcodescanner": {
-        "CAMERA_USAGE_DESCRIPTION": " "
-      }
+    "scripts": {
+        "postinstall": "bower install",
+        "install-for-mobile": "ionic state restore",
+        "start": "ionic serve"
+    },
+    "keywords": [
+        "duniter",
+        "cesium",
+        "ionic",
+        "angular",
+        "cordova",
+        "crypto-currency"
+    ],
+    "author": "Duniter team",
+    "license": "GPL-3.0",
+    "readmeFilename": "README.md",
+    "bugs": {
+        "url": "https://github.com/duniter/cesium/issues",
+        "new": "https://github.com/duniter/cesium/issues/new?labels=bug"
+    },
+    "dependencies": {
+        "bower": "^1.8.0",
+        "cordova-android": "^5.2.2",
+        "cordova-plugin-camera": "^2.4.1",
+        "cordova-plugin-compat": "^1.1.0",
+        "cordova-plugin-console": "^1.0.7",
+        "cordova-plugin-device": "^1.1.6",
+        "cordova-plugin-dialogs": "^1.3.3",
+        "cordova-plugin-inappbrowser": "^1.6.1",
+        "cordova-plugin-minisodium": "^1.0.0",
+        "cordova-plugin-secure-storage": "^2.6.8",
+        "cordova-plugin-splashscreen": "^3.2.2",
+        "cordova-plugin-statusbar": "^2.2.3",
+        "cordova-plugin-vibration": "^2.1.5",
+        "cordova-plugin-websocket": "^0.12.2",
+        "cordova-plugin-whitelist": "^1.3.2",
+        "cordova-plugin-x-toast": "^2.6.0",
+        "delete-empty": "^0.1.3",
+        "gulp": "^3.9.1",
+        "gulp-bump": "^2.1.0",
+        "gulp-concat": "^2.2.0",
+        "gulp-rename": "^1.2.0",
+        "gulp-sass": "^2.2.0",
+        "ionic": "^1.7.16",
+        "ionic-plugin-keyboard": "^2.2.1",
+        "node-sass": "^3.3.3",
+        "phonegap-plugin-barcodescanner": "git+https://github.com/phonegap/phonegap-plugin-barcodescanner.git"
+    },
+    "devDependencies": {
+        "cordova-uglify": "^0.2.3",
+        "del": "^2.2.0",
+        "fs": "0.0.2",
+        "gulp": "^3.9.1",
+        "gulp-angular-templatecache": "^1.8.0",
+        "gulp-angular-translate": "^0.1.4",
+        "gulp-base64": "^0.1.3",
+        "gulp-clean": "^0.3.2",
+        "gulp-clean-css": "^2.0.10",
+        "gulp-css-base64": "^1.3.4",
+        "gulp-csso": "^2.0.0",
+        "gulp-filter": "^4.0.0",
+        "gulp-header": "^1.7.1",
+        "gulp-html-remove": "^0.1.1",
+        "gulp-htmlmin": "^2.0.0",
+        "gulp-jshint": "^2.0.1",
+        "gulp-ng-annotate": "^2.0.0",
+        "gulp-ng-constant": "^1.1.0",
+        "gulp-remove-code": "^1.0.2",
+        "gulp-replace": "^0.5.4",
+        "gulp-rev": "^7.0.0",
+        "gulp-rev-replace": "^0.4.3",
+        "gulp-sourcemaps": "^1.6.0",
+        "gulp-uglify": "^1.5.3",
+        "gulp-useref": "^3.1.0",
+        "gulp-util": "^2.2.14",
+        "gulp-zip": "^3.2.0",
+        "ionic-minify": "^2.0.8",
+        "jshint": "^2.9.2",
+        "mv": "^2.1.1",
+        "playup": "^1.0.2",
+        "shelljs": "^0.3.0",
+        "yargs": "^4.3.1"
+    },
+    "cordovaPlugins": [
+        "cordova-plugin-whitelist",
+        "cordova-plugin-splashscreen",
+        "cordova-plugin-console",
+        "ionic-plugin-keyboard",
+        "cordova-plugin-device",
+        "cordova-plugin-statusbar",
+        "cordova-plugin-camera",
+        "cordova-plugin-websocket",
+        "cordova-plugin-vibration",
+        "cordova-plugin-dialogs",
+        "cordova-plugin-minisodium",
+        "cordova-plugin-secure-storage",
+        {
+            "locator": "https://github.com/phonegap/phonegap-plugin-barcodescanner.git",
+            "id": "phonegap-plugin-barcodescanner"
+        },
+        "cordova-plugin-inappbrowser",
+        "cordova-plugin-x-toast"
+    ],
+    "cordovaPlatforms": [
+        "android",
+        "firefoxos"
+    ],
+    "cordova": {
+        "plugins": {
+            "cordova-plugin-camera": {},
+            "cordova-plugin-console": {},
+            "cordova-plugin-device": {},
+            "cordova-plugin-dialogs": {},
+            "cordova-plugin-inappbrowser": {},
+            "cordova-plugin-minisodium": {},
+            "cordova-plugin-secure-storage": {},
+            "cordova-plugin-splashscreen": {},
+            "cordova-plugin-statusbar": {},
+            "cordova-plugin-vibration": {},
+            "cordova-plugin-websocket": {},
+            "cordova-plugin-whitelist": {},
+            "cordova-plugin-x-toast": {},
+            "ionic-plugin-keyboard": {},
+            "phonegap-plugin-barcodescanner": {
+                "CAMERA_USAGE_DESCRIPTION": " "
+            }
+        }
     }
-  }
-}
+}
\ No newline at end of file