Skip to content

Commit

Permalink
Updates dependencies, removes CoffeeScript.
Browse files Browse the repository at this point in the history
  • Loading branch information
Mikael Selander committed Oct 22, 2015
1 parent 9adff4c commit e5ef747
Show file tree
Hide file tree
Showing 9 changed files with 262 additions and 325 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
node_modules/
node_modules/
.idea
149 changes: 0 additions & 149 deletions Gruntfile.coffee

This file was deleted.

161 changes: 161 additions & 0 deletions Gruntfile.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,161 @@
'use strict';

module.exports = function(grunt) {
grunt.initConfig({
clean: {
test: {
src: ['./test/actual/']
},
task: {
src: ['./tasks/template.js']
}
},
template: {
single: {
files: {
'test/actual/main.html': 'test/source/main.template'
},
options: {
data: {
message: 'Single',
"class": 'foo'
}
}
},
css: {
files: {
'test/actual/foo.min.css': 'test/source/foo.css'
},
options: {
minify: {
pretty: {
lang: 'css',
mode: 'minify'
}
}
}
},
min: {
files: {
'test/actual/min.html': 'test/source/min.template'
},
options: {
data: {
message: 'Minified',
"class": 'foo'
},
minify: {
mode: 'html'
}
}
},
concat: {
files: {
'test/actual/concat.html': ['test/source/concat1.template', 'test/source/concat2.template']
},
options: {
data: {
message: 'Concat',
"class": 'foo'
}
}
},
wrap: {
files: {
'test/actual/wrapped.html': 'test/source/main.template'
},
options: {
data: {
message: 'Wrap',
"class": 'foo'
},
wrap: {
banner: '<wrapped>\n',
footer: '\n</wrapped>'
}
}
},
advWrap: {
files: {
'test/actual/wrappedAdv.html': 'test/source/main.template'
},
options: {
data: {
message: 'Wrap',
"class": 'foo'
},
wrap: {
banner: '<wrapped id="#{0}">\n',
footer: '\n</wrapped>',
inject: [
{
prop: 'dest',
rem: 'test/'
}
]
}
}
},
concatWrap: {
files: {
'test/actual/wrappedConcat.html': ['test/source/concat1.template', 'test/source/concat2.template']
},
options: {
data: {
message: 'WrapConcat',
"class": 'foo'
},
wrap: {
banner: '<wrapped id="#{0}">\n',
footer: '\n</wrapped>',
inject: [
{
prop: 'dest',
rem: 'test/'
}
]
}
}
},
advWrapReplace: {
files: {
'test/actual/wrappedReplace.html': 'test/source/main.template'
},
options: {
data: {
message: 'WrapReplace',
"class": 'foo'
},
wrap: {
banner: '<wrapped id="#{0}">\n',
footer: '\n</wrapped>',
inject: [
{
prop: 'src',
rem: 'test/',
repl: {
".template": ".html"
}
}
]
}
}
}
}
});

grunt.loadTasks('tasks');
grunt.loadNpmTasks('grunt-contrib-clean');
grunt.loadNpmTasks('grunt-contrib-coffee');

grunt.registerTask('mocha', 'run mocha', function() {
var done = grunt.task.current.async();

require('child_process').exec('mocha --compilers coffee:coffee-script/register -R spec', function(err, stdout) {
grunt.log.write(stdout);
done(err);
});
});

grunt.registerTask('default', ['template', 'mocha', 'clean']);
};
17 changes: 8 additions & 9 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "grunt-template-helper",
"description": "Grunt template processor and wrapper.",
"version": "0.1.7",
"version": "0.2.0",
"homepage": "https://github.com/ciddan/grunt-template-helper",
"author": {
"name": "Mikael Selander",
Expand All @@ -23,18 +23,17 @@
"test": "grunt test"
},
"dependencies": {
"grunt-lib-contrib": "0.4.x",
"prettydiff": "0.0.228"
"prettydiff": "1.14.7"
},
"devDependencies": {
"grunt": "~0.4.2",
"grunt-coffeelint": "~0.0.8",
"grunt-contrib-clean": "~0.5.0",
"grunt-contrib-coffee": "~0.9.0",
"chai": "~1.9.0",
"coffee-script": "~1.7.1"
"grunt-coffeelint": "~0.0.13",
"grunt-contrib-clean": "~0.6.0",
"grunt-contrib-coffee": "~0.13.0",
"chai": "~3.4.0",
"coffee-script": "~1.10.0"
},
"_id": "grunt-template-helper@0.1.7",
"_id": "grunt-template-helper@0.2.0",
"_from": "grunt-template-helper0.1.0",
"keywords": [
"gruntplugin",
Expand Down
Loading

0 comments on commit e5ef747

Please sign in to comment.