Skip to content

Commit

Permalink
Merge branch 'release/3.2.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
Marco Solazzi committed Aug 25, 2016
2 parents fcf5b91 + 218f374 commit e27dd32
Show file tree
Hide file tree
Showing 5 changed files with 62 additions and 45 deletions.
14 changes: 9 additions & 5 deletions application/views/templates/_default.nunj.html
Original file line number Diff line number Diff line change
Expand Up @@ -15,17 +15,21 @@
<meta name="HandheldFriendly" content="True" />
<meta name="MobileOptimized" content="320" />
<meta name="format-detection" content="telephone=no">
<meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no" />

<!-- build:replace /assets/vendors/modernizr/modernizr.min.js -->
<script src="/assets/vendors/modernizr/modernizr.js"></script>
<!-- build:css /assets/stylesheets/application.min.css -->
<link rel="stylesheet" href="/assets/stylesheets/application.css" />
<!-- endbuild -->

<!--[if lt IE 9]>
<script src="/assets/vendors/html5shiv/dist/html5shiv-printshiv.min.js"></script>
<![endif]-->

<!-- build:css /assets/stylesheets/application.min.css -->
<link rel="stylesheet" href="/assets/stylesheets/application.css" />
<!-- build:replace /assets/vendors/modernizr/modernizr.min.js -->
<script src="/assets/vendors/modernizr/modernizr.js"></script>
<!-- endbuild -->


{% block head %}
{% endblock %}

Expand Down
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "wok",
"version": "3.1.0",
"version": "3.2.0",
"authors": [
"Marco Solazzi <[email protected]>",
"Matteo Guidotto <[email protected]>",
Expand Down
4 changes: 1 addition & 3 deletions build/gulp-config/modernizr.conf.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,8 @@
"atRule",
"domPrefixes",
"hasEvent",
"html5shiv",
"html5printshiv",
"load",
"mq",
"fnBind",
"prefixed",
"prefixes",
"prefixedCSS",
Expand Down
51 changes: 32 additions & 19 deletions build/gulp-tasks/modernizr.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@

module.exports = function (gulp, $, options) {

var defaultConfig = require('../gulp-config/modernizr.conf.json');

var distConfig = {

cache: true,
Expand All @@ -14,23 +16,7 @@ module.exports = function (gulp, $, options) {
dest: options.paths.tmp + '/assets/vendors/modernizr/modernizr.js',

// Based on default settings on http://modernizr.com/download/
options: [
'setClasses',
'addTest',
'html5printshiv',
'testProp',
'fnBind',
'atRule',
'domPrefixes',
'hasEvent',
'html5shiv',
'mq',
'prefixed',
'prefixes',
'prefixedCSS',
'testAllProps',
'testStyles'
],
options: defaultConfig.options,

// By default, source is uglified before saving
uglify: true,
Expand Down Expand Up @@ -67,7 +53,7 @@ module.exports = function (gulp, $, options) {
};


gulp.task('modernizr', function (done) {
gulp.task('modernizr', ['modernizr:html5shiv'], function (done) {
var fs = require('fs'),
filePath = options.assetsPath('dist.vendors', '/modernizr'),
fullConfig,
Expand All @@ -77,7 +63,25 @@ module.exports = function (gulp, $, options) {

if (options.production) {
modernizr = require('customizr');
modernizr(distConfig, function () {
modernizr(distConfig, function (obj) {
var tests = obj.options['feature-detects'],
logStr = 'The production build includes the following tests: ',
colors = $.util.colors;
if (tests.length > 0) {


logStr += colors.bold(tests.map(function (test) {
return test.replace('test/', '');
}).join(', '));

$.util.log(logStr);

$.util.log(
'For optimal performances you might add a `defer` attribute to the script tag. ' +
'Refer to https://github.com/Modernizr/Modernizr/issues/878#issuecomment-41448059 for guidelines'
);
}

done();
});
} else {
Expand All @@ -93,6 +97,15 @@ module.exports = function (gulp, $, options) {

});

gulp.task('modernizr:html5shiv', function () {

var path = require('path'),
html5shivPath = path.join(path.dirname(require.resolve('html5shiv')), '*.min.js');

return gulp.src([html5shivPath])
.pipe(gulp.dest(options.assetsPath('dist.vendors', 'html5shiv/dist')));
});

};


36 changes: 19 additions & 17 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "wok",
"description": "A Static Website Boilerplate",
"version": "3.1.0",
"version": "3.2.0",
"license": "MIT",
"repository": {
"type": "git",
Expand All @@ -25,54 +25,56 @@
"engines": {
"node": "~0.12.7"
},
"dependencies": {},
"dependencies": {
"html5shiv": "3.7.3"
},
"devDependencies": {
"autoprefixer": "6.3.7",
"browser-sync": "2.13.0",
"autoprefixer": "6.4.0",
"browser-sync": "2.14.0",
"customizr": "https://github.com/doctyper/customizr/tarball/develop",
"datauri": "1.0.4",
"del": "2.2.1",
"del": "2.2.2",
"ftps": "0.4.7",
"glob": "7.0.5",
"glob": "7.0.6",
"gulp": "3.9.1",
"gulp-bump": "2.2.0",
"gulp-changed": "1.3.0",
"gulp-bump": "2.4.0",
"gulp-changed": "1.3.2",
"gulp-concat": "2.6.0",
"gulp-filter": "4.0.0",
"gulp-header": "1.8.7",
"gulp-header": "1.8.8",
"gulp-if": "2.0.1",
"gulp-imagemin": "3.0.1",
"gulp-imagemin": "3.0.3",
"gulp-load-plugins": "1.2.4",
"gulp-minify-css": "1.2.4",
"gulp-notify": "2.2.0",
"gulp-plumber": "1.1.0",
"gulp-postcss": "6.1.1",
"gulp-rename": "1.2.2",
"gulp-rev": "7.1.0",
"gulp-rev": "7.1.2",
"gulp-rev-replace": "0.4.3",
"gulp-sass": "2.3.2",
"gulp-size": "2.1.0",
"gulp-sourcemaps": "1.6.0",
"gulp-uglify": "1.5.4",
"gulp-uglify": "2.0.0",
"gulp-useref": "3.1.0",
"gulp-util": "3.0.7",
"hasbin": "1.2.3",
"image-size": "0.5.0",
"inquirer": "1.1.1",
"inquirer": "1.1.2",
"lazypipe": "1.0.1",
"lodash": "4.13.1",
"lodash": "4.15.0",
"lorem-ipsum": "1.0.3",
"marked": "0.3.5",
"marked": "0.3.6",
"mkdirp": "0.5.1",
"modernizr": "3.3.1",
"node-sass": "3.8.0",
"nunjucks": "2.4.2",
"nunjucks-markdown": "2.0.0",
"rsyncwrapper": "1.0.1",
"run-sequence": "1.2.2",
"semver": "5.2.0",
"semver": "5.3.0",
"ssh2": "0.5.0",
"through2": "2.0.1",
"yargs": "4.7.1"
"yargs": "5.0.0"
}
}

0 comments on commit e27dd32

Please sign in to comment.