set up some grunt stuff to automate builds

This commit is contained in:
Dave Snider 2013-10-22 21:35:07 -07:00
parent 6f33418bdc
commit cf6af1482d
2 changed files with 63 additions and 0 deletions

47
Gruntfile.js Normal file
View File

@ -0,0 +1,47 @@
module.exports = function(grunt) {
// load all grunt tasks
require('matchdep').filterDev('grunt-*').forEach(grunt.loadNpmTasks);
grunt.initConfig({
compass: {
dev: {
options: {
config: 'sphinx_rtd_theme/sass/config.rb',
basePath: 'sphinx_rtd_theme/sass',
force: true
}
}
},
// I use this to build the sphinx_rtd_theme available at https://github.com/snide/sphinx_rtd_theme
copy: {
sphinx_rtd_theme : {
files: [
{
expand: true,
cwd: 'docs/source/_themes/wyrm_theme',
src: ['**', '!**/theme.sass', '!**/*.css', '!**/config.rb'],
dest: '../sphinx_rtd_theme/sphinx_rtd_theme'
}
]
}
},
exec: {
update: {
cmd: 'bower update'
}
}
});
grunt.loadNpmTasks('grunt-contrib-copy');
grunt.loadNpmTasks('grunt-exec');
grunt.loadNpmTasks('grunt-contrib-compass');
grunt.registerTask('default', ['exec', 'compass']);
}

16
package.json Normal file
View File

@ -0,0 +1,16 @@
{
"name": "sphinx_rtd_theme",
"version": "0.0.11",
"private": true,
"devDependencies": {
"grunt": "~0.4.1",
"grunt-contrib-compass": "~0.2.0",
"grunt-contrib-watch": "~0.4.3",
"grunt-contrib-uglify": "~0.2.0",
"grunt-exec": "~0.4.2",
"grunt-contrib-connect": "0.5.0",
"grunt-contrib-copy": "0.4.1",
"matchdep": "~0.1.2"
}
}