1
0
mirror of https://github.com/locomotivemtl/locomotive-boilerplate.git synced 2026-01-15 00:55:08 +08:00

redo the structure a bit, add a gruntfile and package without doing anything in them yet.

This commit is contained in:
Stephen
2014-09-29 14:05:34 -04:00
parent a211d1064c
commit 2f2484ffce
13 changed files with 113 additions and 0 deletions

88
project-x/Gruntfile.js Normal file
View File

@@ -0,0 +1,88 @@
module.exports = function(grunt) {
'use strict';
// Load Grunt tasks from NPM packages
require('load-grunt-tasks')(grunt);
// Project configuration.
grunt.initConfig({
pkg: grunt.file.readJSON( 'package.json' ),
watch: {
css: {
files: ['assets/styles/src/**/*.scss'],
tasks: ['sass', 'autoprefixer', 'notify:watch', 'notify_hooks'],
options: {
spawn: false,
livereload: true
}
}
},
sass: {
dist: {
files: {
'assets/styles/corim.css': 'assets/styles/src/corim.scss',
'assets/styles/corim.ie8.css': 'assets/styles/src/corim.ie8.scss'
}
}
},
autoprefixer: {
build: {
options: {
browsers: ['last 2 versions', '> 1%']
},
files: [
{
src : ['assets/styles/*.css'],
dest : 'assets/styles/',
expand : true,
flatten: true
}
]
}
},
notify: {
task_name: {
options: {
// Task-specific options go here.
}
},
watch: {
options: {
title: 'Sass', // optional
message: 'SASS compiled', //required
}
}
},
notify_hooks: {
options: {
enabled: true,
title: "Project-x" // defaults to the name in package.json, or will use project directory's name
}
},
concat: {
jsbasic: {
src: 'assets/scripts/src/*.js',
dest: 'assets/scripts/main.js'
}
},
uglify: {
my_target: {
files: {
'assets/scripts/main.js': ['assets/scripts/main.js']
}
}
}
});
// Configure automatic messaging
// grunt.task.run('notify_hooks');
// Integrate jQuery specific tasks
// grunt.loadTasks('tasks');
grunt.registerTask('default', ['watch']);
grunt.registerTask('build', ['responsive_images']);
};

View File

View File

View File

25
project-x/package.json Normal file
View File

@@ -0,0 +1,25 @@
{
"title": "Projet-x",
"name": "corim",
"version": "1.0.0",
"author": "Locomotive <info@locomotive.ca>",
"contributors": [
"Stephen Bégay <stephen@locomotive.ca>",
"Antoine Boulané <antoine@locomotive.ca>"
],
"description": "Web site for <projet-x> by Locomotive.",
"license": "© 2014 — Locomotive, Projet-x",
"homepage": "projet-x.com",
"private": true,
"devDependencies": {
"grunt": "^0.4.5",
"load-grunt-tasks": "^0.4.0",
"grunt-sass": "^0.14.0",
"grunt-contrib-watch": "^0.6.1",
"grunt-notify": "^0.3.0",
"grunt-autoprefixer": "^0.8.1",
"grunt-contrib-uglify": "^0.5.0",
"grunt-contrib-concat": "^0.4.0",
"grunt-contrib-imagemin": "^0.7.1"
}
}