So many updates :/
This commit is contained in:
parent
b98abff03f
commit
6d9a0714d5
3
.gitignore
vendored
3
.gitignore
vendored
@ -1,2 +1,5 @@
|
|||||||
node_modules
|
node_modules
|
||||||
.sass-cache
|
.sass-cache
|
||||||
|
*.sublime-workspace
|
||||||
|
.DS_Store
|
||||||
|
._*
|
||||||
|
@ -2,14 +2,11 @@
|
|||||||
<!DOCTYPE cross-domain-policy SYSTEM "http://www.adobe.com/xml/dtds/cross-domain-policy.dtd">
|
<!DOCTYPE cross-domain-policy SYSTEM "http://www.adobe.com/xml/dtds/cross-domain-policy.dtd">
|
||||||
<cross-domain-policy>
|
<cross-domain-policy>
|
||||||
|
|
||||||
|
|
||||||
<!-- Read this: www.adobe.com/devnet/articles/crossdomain_policy_file_spec.html -->
|
<!-- Read this: www.adobe.com/devnet/articles/crossdomain_policy_file_spec.html -->
|
||||||
|
|
||||||
<!-- Most restrictive policy: -->
|
<!-- Most restrictive policy: -->
|
||||||
<site-control permitted-cross-domain-policies="none"/>
|
<site-control permitted-cross-domain-policies="none"/>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!-- Least restrictive policy: -->
|
<!-- Least restrictive policy: -->
|
||||||
<!--
|
<!--
|
||||||
<site-control permitted-cross-domain-policies="all"/>
|
<site-control permitted-cross-domain-policies="all"/>
|
||||||
|
88
gulpfile.js
88
gulpfile.js
@ -1,25 +1,25 @@
|
|||||||
// Require all those npm-modules
|
// Require all those npm-modules
|
||||||
|
|
||||||
var gulp = require('gulp'),
|
var gulp = require('gulp'),
|
||||||
sass = require('gulp-sass'),
|
sass = require('gulp-sass'),
|
||||||
autoprefixer = require('gulp-autoprefixer'),
|
autoprefixer = require('gulp-autoprefixer'),
|
||||||
cssmin = require('gulp-cssmin'),
|
cssmin = require('gulp-cssmin'),
|
||||||
jshint = require('gulp-jshint'),
|
jshint = require('gulp-jshint'),
|
||||||
uglify = require('gulp-uglify'),
|
uglify = require('gulp-uglify'),
|
||||||
imagemin = require('gulp-imagemin'),
|
imagemin = require('gulp-imagemin'),
|
||||||
pngcrush = require('imagemin-pngcrush'),
|
pngcrush = require('imagemin-pngcrush'),
|
||||||
rename = require('gulp-rename'),
|
rename = require('gulp-rename'),
|
||||||
clean = require('gulp-rimraf'),
|
clean = require('gulp-rimraf'),
|
||||||
concat = require('gulp-concat'),
|
concat = require('gulp-concat'),
|
||||||
notify = require('gulp-notify'),
|
notify = require('gulp-notify'),
|
||||||
cache = require('gulp-cache'),
|
cache = require('gulp-cache'),
|
||||||
livereload = require('gulp-livereload');
|
livereload = require('gulp-livereload');
|
||||||
|
|
||||||
// render scss
|
// render scss
|
||||||
gulp.task('styles', function() {
|
gulp.task('styles', function() {
|
||||||
gulp.src('./src/scss/main.scss')
|
gulp.src('./src/scss/main.scss')
|
||||||
.pipe(sass({ style: 'expanded' }))
|
.pipe(sass({ style: 'expanded' }))
|
||||||
.pipe(autoprefixer('last 2 version', 'safari 5', 'ie 9', 'opera 12.1', 'ios 6', 'android 4'))
|
.pipe(autoprefixer('last 2 version', 'IE 9', 'safari 5', 'Firefox ESR', 'opera 12.1', 'ios 6', 'android 4', 'BlackBerry 10',))
|
||||||
.pipe(gulp.dest('./css'))
|
.pipe(gulp.dest('./css'))
|
||||||
.pipe(rename({suffix: '.min'}))
|
.pipe(rename({suffix: '.min'}))
|
||||||
.pipe(cssmin())
|
.pipe(cssmin())
|
||||||
@ -52,6 +52,7 @@ gulp.task('scripts', function() {
|
|||||||
.pipe(notify({ message: 'Scripts task complete' }));
|
.pipe(notify({ message: 'Scripts task complete' }));
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// watch it while working
|
||||||
gulp.task('watch', function() {
|
gulp.task('watch', function() {
|
||||||
// Watch .scss files
|
// Watch .scss files
|
||||||
gulp.watch('src/scss/**/*.scss', ['styles']);
|
gulp.watch('src/scss/**/*.scss', ['styles']);
|
||||||
@ -63,62 +64,7 @@ gulp.task('watch', function() {
|
|||||||
gulp.watch('src/img/**/*', ['images']);
|
gulp.watch('src/img/**/*', ['images']);
|
||||||
});
|
});
|
||||||
|
|
||||||
// default:
|
// default: all of them! \o/
|
||||||
gulp.task('default', ['clean'], function() {
|
gulp.task('default', ['clean'], function() {
|
||||||
gulp.start('styles', 'scripts', 'images');
|
gulp.start('styles', 'scripts', 'images');
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
|
||||||
//
|
|
||||||
// OLD STUFF
|
|
||||||
// ----------------------
|
|
||||||
// sass + watch
|
|
||||||
gulp.task('sass', function() {
|
|
||||||
gulp.src('./scss/*.scss')
|
|
||||||
.pipe(watch())
|
|
||||||
.pipe(sass())
|
|
||||||
.pipe(prefix("last 2 versions", "ie 9"))
|
|
||||||
.pipe(cssmin())
|
|
||||||
.pipe(rename({suffix: ".min"}))
|
|
||||||
.pipe(gulp.dest('./css'))
|
|
||||||
});
|
|
||||||
|
|
||||||
// image
|
|
||||||
gulp.task('img', function() {
|
|
||||||
gulp.src('src/img/*')
|
|
||||||
.pipe(imagemin({
|
|
||||||
progressive: true,
|
|
||||||
svgoPlugins: [{removeViewBox: false}],
|
|
||||||
use: [pngcrush()]
|
|
||||||
}))
|
|
||||||
.pipe(gulp.dest('./img/'))
|
|
||||||
});
|
|
||||||
|
|
||||||
// finalize
|
|
||||||
gulp.task('final', function() {
|
|
||||||
gulp.src('./scss/*.scss')
|
|
||||||
.pipe(sass())
|
|
||||||
.pipe(prefix("last 2 versions", "ie 9"))
|
|
||||||
.pipe(gulp.dest('./css'))
|
|
||||||
.pipe(rename({suffix: ".min"}))
|
|
||||||
.pipe(cssmin())
|
|
||||||
.pipe(gulp.dest('./css'))
|
|
||||||
gulp.src('src/img/*')
|
|
||||||
.pipe(imagemin({
|
|
||||||
progressive: true,
|
|
||||||
svgoPlugins: [{removeViewBox: false}],
|
|
||||||
use: [pngcrush()]
|
|
||||||
}))
|
|
||||||
.pipe(gulp.dest('./img/'))
|
|
||||||
});
|
|
||||||
|
|
||||||
// JS hint task
|
|
||||||
gulp.task('jshint', function() {
|
|
||||||
gulp.src('./scripts/*.js')
|
|
||||||
.pipe(jshint())
|
|
||||||
.pipe(jshint.reporter('default'));
|
|
||||||
});
|
|
||||||
|
|
||||||
*/
|
|
||||||
|
Loading…
Reference in New Issue
Block a user