瀏覽代碼

Merge pull request #621 from herby/johnnyt-bad-merge

grunt cleanup from johnnyt
Herbert Vojčík 10 年之前
父節點
當前提交
3f435205dc
共有 3 個文件被更改,包括 39 次插入112 次删除
  1. 0 60
      Gruntfile.js
  2. 0 17
      grunt/tasks/grunt-css2js.js
  3. 39 35
      package.json

+ 0 - 60
Gruntfile.js

@@ -3,8 +3,6 @@ module.exports = function(grunt) {
   grunt.loadTasks('./grunt/tasks');
 
   grunt.loadNpmTasks('grunt-contrib-jshint');
-//  grunt.loadNpmTasks('grunt-image-embed');
-//  grunt.loadNpmTasks('grunt-contrib-mincss');
 
   grunt.registerTask('default', ['peg', 'amberc:all']);
 
@@ -115,64 +113,6 @@ module.exports = function(grunt) {
       repl: ['repl/*.js'],
       tests: ['test/*.js'],
       grunt: ['grunt.js', 'grunt/**/*.js']
-    },
-/*
-    concat: {
-      deploy: {
-        src: ['tmp/amber-compiled.deploy.js'],
-        dest: 'dist/amber-<%= pkg.version %>.deploy.js'
-      },
-
-      css: {
-        src: [
-          'css/amber.css',
-          'js/lib/CodeMirror/codemirror.css',
-          'js/lib/CodeMirror/amber.css'
-        ],
-        dest: 'tmp/amber.css'
-      },
-
-      dev: {
-        src: [
-          'js/lib/jQuery/jquery-ui-1.8.16.custom.min.js',
-          'js/lib/jQuery/jquery.textarea.js',
-          'js/lib/CodeMirror/codemirror.js',
-          'js/lib/CodeMirror/smalltalk.js',
-          'tmp/amber-compiled.js',
-          'tmp/css.js'
-        ],
-        dest: 'dist/amber-<%= pkg.version %>.js'
-      }
-    },
-
-    imageEmbed: {
-      dev: {
-        src: ['tmp/amber.css'],
-        dest: 'tmp/amber-images.css',
-        options: {baseDir: 'public'}
-      }
-    },
-
-    mincss: {
-      dev: {
-        src: ['tmp/amber-images.css'],
-        dest: 'tmp/amber.min.css'
-      }
-    },
-
-    css2js: {
-      dev: {
-        src: 'tmp/amber.min.css',
-        dest: 'tmp/css.js'
-      }
-    },
-
-    min: {
-      deploy: {
-        src: 'dist/amber-<%= pkg.version %>.deploy.js',
-        dest: 'dist/amber-<%= pkg.version %>.deploy.min.js'
-      }
     }
-*/
   });
 };

+ 0 - 17
grunt/tasks/grunt-css2js.js

@@ -1,17 +0,0 @@
-module.exports = function(grunt) {
-  grunt.registerMultiTask('css2js', 'Embed CSS into JS', function() {
-    var cssContent = grunt.task.directive(grunt.file.expandFiles(this.data.src)[0], grunt.file.read);
-    var content =
-      'var css="' + cssContent + '";' +
-      'var cssTag = document.createElement("link");' +
-      'document.head = document.head || document.getElementsByTagName("head")[0];' +
-      'cssTag.href = "data:text/css,"+css;' +
-      'cssTag.rel = "stylesheet";' +
-      'document.head.appendChild(cssTag);';
-
-    grunt.file.write(this.data.dest, content);
-
-    grunt.log.writeln('File "' + this.data.dest + '" created.');
-  });
-
-};

+ 39 - 35
package.json

@@ -1,37 +1,41 @@
 {
-    "name": "amber",
-    "version": "0.11.0",
-    "description": "An implementation of the Smalltalk language that runs on top of the JS runtime.",
-    "homepage": "http://amber-lang.net",
-    "keywords": [ "javascript", "smalltalk", "language", "compiler", "web" ],
-    "author": {
-        "name": "Nicolas Petton",
-        "email": "petton.nicolas@gmail.com",
-        "url": "http://www.nicolas-petton.fr"
-    },
-    "license": {
-        "type": "MIT"
-    },
-    "repository": {
-        "type": "git",
-        "url": "git://github.com/amber-smalltalk/amber.git#0.11.0"
-    },
-    "engines": {
-        "node": "0.8.x"
-    },
-    "bin": {
-        "amber": "./bin/amber",
-        "amberc": "./bin/amberc",
-        "ambers": "./bin/server"
-    },
-    "scripts": {
-        "test": "grunt amberc:amber_test_runner && node ./test/amber_test_runner.js"
-    },
-    "devDependencies": {
-        "pegjs": "~0.7.0",
-        "grunt": "~0.4.0",
-        "grunt-contrib-jshint": "~0.3.0",
-        "grunt-image-embed": "~0.1.3",
-        "grunt-contrib-mincss": "~0.3.2"
-    }
+  "name": "amber",
+  "version": "0.11.0",
+  "description": "An implementation of the Smalltalk language that runs on top of the JS runtime.",
+  "homepage": "http://amber-lang.net",
+  "keywords": [
+    "javascript",
+    "smalltalk",
+    "language",
+    "compiler",
+    "web"
+  ],
+  "author": {
+    "name": "Nicolas Petton",
+    "email": "petton.nicolas@gmail.com",
+    "url": "http://www.nicolas-petton.fr"
+  },
+  "license": {
+    "type": "MIT"
+  },
+  "repository": {
+    "type": "git",
+    "url": "git://github.com/amber-smalltalk/amber.git#0.11.0"
+  },
+  "engines": {
+    "node": "0.8.x"
+  },
+  "bin": {
+    "amber": "./bin/amber",
+    "amberc": "./bin/amberc",
+    "ambers": "./bin/server"
+  },
+  "scripts": {
+    "test": "grunt amberc:amber_test_runner && node ./test/amber_test_runner.js"
+  },
+  "devDependencies": {
+    "pegjs": "~0.7.0",
+    "grunt": "~0.4.0",
+    "grunt-contrib-jshint": "~0.3.0"
+  }
 }