Explorar o código

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

Adding it back again.
JC Brand %!s(int64=9) %!d(string=hai) anos
pai
achega
7eb453efa1
Modificáronse 4 ficheiros con 16 adicións e 11107 borrados
  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
 
 ########################################################################

A diferenza do arquivo foi suprimida porque é demasiado grande
+ 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",

Algúns arquivos non se mostraron porque demasiados arquivos cambiaron neste cambio