add grunt and recompile css

This commit is contained in:
David Miller 2016-02-02 14:41:00 -05:00
parent 26209a3631
commit e031056165
7 changed files with 854 additions and 4 deletions

1
.gitignore vendored Normal file
View File

@ -0,0 +1 @@
node_modules

74
Gruntfile.js Normal file
View File

@ -0,0 +1,74 @@
module.exports = function(grunt) {
// Project configuration.
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
uglify: {
main: {
src: 'js/<%= pkg.name %>.js',
dest: 'js/<%= pkg.name %>.min.js'
}
},
less: {
expanded: {
options: {
paths: ["css"]
},
files: {
"css/<%= pkg.name %>.css": "less/<%= pkg.name %>.less"
}
},
minified: {
options: {
paths: ["css"],
cleancss: true
},
files: {
"css/<%= pkg.name %>.min.css": "less/<%= pkg.name %>.less"
}
}
},
banner: '/*!\n' +
' * <%= pkg.title %> v<%= pkg.version %> (<%= pkg.homepage %>)\n' +
' * Copyright 2013-<%= grunt.template.today("yyyy") %> <%= pkg.author %>\n' +
' * Licensed under <%= pkg.license.type %> (<%= pkg.license.url %>)\n' +
' */\n',
usebanner: {
dist: {
options: {
position: 'top',
banner: '<%= banner %>'
},
files: {
src: ['css/<%= pkg.name %>.css', 'css/<%= pkg.name %>.min.css', 'js/<%= pkg.name %>.min.js']
}
}
},
watch: {
scripts: {
files: ['js/<%= pkg.name %>.js'],
tasks: ['uglify'],
options: {
spawn: false,
},
},
less: {
files: ['less/*.less'],
tasks: ['less'],
options: {
spawn: false,
}
},
},
});
// Load the plugins.
grunt.loadNpmTasks('grunt-contrib-uglify');
grunt.loadNpmTasks('grunt-contrib-less');
grunt.loadNpmTasks('grunt-banner');
grunt.loadNpmTasks('grunt-contrib-watch');
// Default task(s).
grunt.registerTask('default', ['uglify', 'less', 'usebanner']);
};

File diff suppressed because one or more lines are too long

7
css/agency.min.css vendored Normal file

File diff suppressed because one or more lines are too long

View File

@ -1,7 +1,7 @@
/*! /*!
* Start Bootstrap - Agency Bootstrap Theme (http://startbootstrap.com) * Agency v1.0.x (http://startbootstrap.com/template-overviews/agency)
* Code licensed under the Apache License v2.0. * Copyright 2013-2016 Start Bootstrap
* For details, see http://www.apache.org/licenses/LICENSE-2.0. * Licensed under MIT (https://github.com/BlackrockDigital/startbootstrap/blob/gh-pages/LICENSE)
*/ */
// jQuery for page scrolling feature - requires jQuery Easing plugin // jQuery for page scrolling feature - requires jQuery Easing plugin

7
js/agency.min.js vendored Normal file
View File

@ -0,0 +1,7 @@
/*!
* Agency v1.0.x (http://startbootstrap.com/template-overviews/agency)
* Copyright 2013-2016 Start Bootstrap
* Licensed under MIT (https://github.com/BlackrockDigital/startbootstrap/blob/gh-pages/LICENSE)
*/
$(function(){$("a.page-scroll").bind("click",function(a){var b=$(this);$("html, body").stop().animate({scrollTop:$(b.attr("href")).offset().top},1500,"easeInOutExpo"),a.preventDefault()})}),$("body").scrollspy({target:".navbar-fixed-top"}),$(".navbar-collapse ul li a:not(.dropdown-toggle)").click(function(){$(".navbar-toggle:visible").click()});

23
package.json Normal file
View File

@ -0,0 +1,23 @@
{
"name": "agency",
"title": "Agency",
"version": "1.0.x",
"homepage": "http://startbootstrap.com/template-overviews/agency",
"author": "Start Bootstrap",
"license": {
"type": "MIT",
"url": "https://github.com/BlackrockDigital/startbootstrap/blob/gh-pages/LICENSE"
},
"devDependencies": {
"grunt": "^0.4.5",
"grunt-banner": "~0.2.3",
"grunt-contrib-less": "~0.11.4",
"grunt-contrib-sass": "^0.9.2",
"grunt-contrib-uglify": "~0.5.1",
"grunt-contrib-watch": "~0.6.1"
},
"repository": {
"type": "git",
"url": "https://github.com/BlackrockDigital/startbootstrap-agency.git"
}
}