Răsfoiți Sursa

Somewhere along the way the code to build the locales got removed

Adding it back again.
JC Brand 9 ani în urmă
părinte
comite
7eb453efa1
4 a modificat fișierele cu 16 adăugiri și 11107 ștergeri
  1. 14 0
      Gruntfile.js
  2. 1 0
      Makefile
  3. 0 11107
      builds/locales.js
  4. 1 0
      package.json

+ 14 - 0
Gruntfile.js

@@ -32,8 +32,22 @@ module.exports = function(grunt) {
                 dest: 'css/converse.min.css',
                 src: ['css/converse.css']
             }
+        },
+        json: {
+            main: {
+                options: {
+                    namespace: 'locales',
+                    includePath: true,
+                    processName: function(filename) {
+                        return filename.toLowerCase().match(/^locale\/(.*)\/lc_messages/)[1];
+                    }
+                },
+                src: ['locale/**/LC_MESSAGES/*.json'],
+                dest: 'builds/locales.js'
+            }
         }
     });
     grunt.loadNpmTasks('grunt-contrib-cssmin');
     grunt.loadNpmTasks('grunt-contrib-jst');
+    grunt.loadNpmTasks('grunt-json');
 };

+ 1 - 0
Makefile

@@ -170,6 +170,7 @@ converse:: stamp-npm
 build:: stamp-npm
 	$(GRUNT) jst
 	$(GRUNT) cssmin
+	$(GRUNT) json
 	make jsmin
 
 ########################################################################

Fișier diff suprimat deoarece este prea mare
+ 0 - 11107
builds/locales.js


+ 1 - 0
package.json

@@ -37,6 +37,7 @@
     "grunt-cli": "~0.1.13",
     "grunt-contrib-cssmin": "~0.9.0",
     "grunt-contrib-jst": "~0.6.0",
+    "grunt-json": "^0.1.3",
     "http-server": "^0.7.4",
     "jshint": "^2.8.0",
     "less": "~1.7.0",

Unele fișiere nu au fost afișate deoarece prea multe fișiere au fost modificate în acest diff