Skip to content

Commit

Permalink
initial commit of rebuild for bootstrap 4 redesign
Browse files Browse the repository at this point in the history
  • Loading branch information
davidtmiller committed Dec 1, 2017
1 parent 92c6add commit e7c3a00
Show file tree
Hide file tree
Showing 35 changed files with 8,825 additions and 417 deletions.
437 changes: 234 additions & 203 deletions css/stylish-portfolio.css

Large diffs are not rendered by default.

5 changes: 5 additions & 0 deletions css/stylish-portfolio.min.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

72 changes: 68 additions & 4 deletions gulpfile.js
@@ -1,7 +1,65 @@
var gulp = require('gulp');
var sass = require('gulp-sass');
var browserSync = require('browser-sync').create();
var header = require('gulp-header');
var cleanCSS = require('gulp-clean-css');
var rename = require("gulp-rename");
var uglify = require('gulp-uglify');
var pkg = require('./package.json');

// Set the banner content
var banner = ['/*!\n',
' * Start Bootstrap - <%= pkg.title %> v<%= pkg.version %> (<%= pkg.homepage %>)\n',
' * Copyright 2013-' + (new Date()).getFullYear(), ' <%= pkg.author %>\n',
' * Licensed under <%= pkg.license %> (https://github.com/BlackrockDigital/<%= pkg.name %>/blob/master/LICENSE)\n',
' */\n',
''
].join('');

// Compiles SCSS files from /scss into /css
gulp.task('sass', function() {
return gulp.src('scss/stylish-portfolio.scss')
.pipe(sass())
.pipe(header(banner, {
pkg: pkg
}))
.pipe(gulp.dest('css'))
.pipe(browserSync.reload({
stream: true
}))
});

// Minify compiled CSS
gulp.task('minify-css', ['sass'], function() {
return gulp.src('css/stylish-portfolio.css')
.pipe(cleanCSS({
compatibility: 'ie8'
}))
.pipe(rename({
suffix: '.min'
}))
.pipe(gulp.dest('css'))
.pipe(browserSync.reload({
stream: true
}))
});

// Minify custom JS
gulp.task('minify-js', function() {
return gulp.src('js/stylish-portfolio.js')
.pipe(uglify())
.pipe(header(banner, {
pkg: pkg
}))
.pipe(rename({
suffix: '.min'
}))
.pipe(gulp.dest('js'))
.pipe(browserSync.reload({
stream: true
}))
});

// Copy vendor files from /node_modules into /vendor
// NOTE: requires `npm install` before running!
gulp.task('copy', function() {
Expand All @@ -28,10 +86,13 @@ gulp.task('copy', function() {
'!node_modules/font-awesome/*.json'
])
.pipe(gulp.dest('vendor/font-awesome'))

gulp.src(['node_modules/simple-line-icons/*/*'])
.pipe(gulp.dest('vendor/simple-line-icons'))
})

// Default task
gulp.task('default', ['copy']);
gulp.task('default', ['sass', 'minify-css', 'minify-js', 'copy']);

// Configure the browserSync task
gulp.task('browserSync', function() {
Expand All @@ -43,8 +104,11 @@ gulp.task('browserSync', function() {
})

// Dev task with browserSync
gulp.task('dev', ['browserSync'], function() {
// Reloads the browser whenever HTML or CSS files change
gulp.watch('css/*.css', browserSync.reload);
gulp.task('dev', ['browserSync', 'sass', 'minify-css', 'minify-js'], function() {
gulp.watch('scss/*.scss', ['sass']);
gulp.watch('css/*.css', ['minify-css']);
gulp.watch('js/*.js', ['minify-js']);
// Reloads the browser whenever HTML or JS files change
gulp.watch('*.html', browserSync.reload);
gulp.watch('js/**/*.js', browserSync.reload);
});
Binary file added img/bg-callout.jpg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added img/bg-masthead.jpg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed img/bg.jpg
Binary file not shown.
Binary file removed img/callout.jpg
Binary file not shown.
Binary file modified img/portfolio-1.jpg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified img/portfolio-2.jpg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified img/portfolio-3.jpg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified img/portfolio-4.jpg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit e7c3a00

Please sign in to comment.