Skip to content

Commit

Permalink
Remove eggache scripts.
Browse files Browse the repository at this point in the history
  • Loading branch information
CDog34 committed Jan 21, 2017
1 parent ee4ddc1 commit 3f199bf
Show file tree
Hide file tree
Showing 8 changed files with 202 additions and 55 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@

# IntelliJ project files
.idea
.idea/workspace.xml

*.iml
out
gen### Node template
Expand Down
171 changes: 156 additions & 15 deletions .idea/workspace.xml

Large diffs are not rendered by default.

74 changes: 39 additions & 35 deletions gulpfile.babel.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,36 +11,36 @@ import htmlminify from 'gulp-html-minify';
import 'babel-polyfill';


let base={
src:'./src/',
dest:'build/'
let base = {
src: './src/',
dest: 'build/'
};

let styleBase={
src:base.src+'/style/*.css',
devDest:".tmp/style",
buildDest:base.dest
let styleBase = {
src: base.src + '/style/*.scss',
devDest: ".tmp/style",
buildDest: base.dest
};

let scriptBase={
src:base.src+'/js/js.js',
devDest:".tmp/js",
buildDest:base.dest
let scriptBase = {
src: base.src + '/js/js.js',
devDest: ".tmp/js",
buildDest: base.dest
};

gulp.task('dev-styles',()=>{
gulp.task('dev-styles', () => {
return gulp.src(styleBase.src)
.pipe(plumber())
.pipe(sass())
.pipe(autoprefix({
browsers:['> 1%','last 4 Android versions']
browsers: ['> 1%', 'last 4 Android versions']
}))
.pipe(gulp.dest(styleBase.devDest))
.pipe(connect.reload());

});

gulp.task('dev-scripts',()=>{
gulp.task('dev-scripts', () => {
return gulp.src(scriptBase.src)
.pipe(plumber())
.pipe(babel({
Expand All @@ -50,41 +50,46 @@ gulp.task('dev-scripts',()=>{
.pipe(gulp.dest(scriptBase.devDest))
.pipe(connect.reload());

})
});

gulp.task('build-scss', () => {
return gulp.src([styleBase.src])
.pipe(sass().on('error', sass.logError))
.pipe(gulp.dest(styleBase.devDest));
});

gulp.task('dev-connect',()=>{
gulp.task('dev-connect', () => {
connect.server({
host:"0.0.0.0",
port:8888,
livereload:true,
root:['.tmp/','src/']
host: "0.0.0.0",
port: 8888,
livereload: true,
root: ['.tmp/', 'src/']
})
});
gulp.task('dev-watch',()=>{
gulp.watch(styleBase.src,['dev-styles']);
gulp.watch(scriptBase.src,['dev-scripts']);
gulp.task('dev-watch', () => {
gulp.watch(styleBase.src, ['dev-styles']);
gulp.watch(scriptBase.src, ['dev-scripts']);
});
gulp.task('dev',['dev-connect','dev-styles','dev-scripts','dev-watch']);
gulp.task('dev', ['dev-connect', 'dev-styles', 'dev-scripts', 'dev-watch']);

gulp.task('clean',(cbk)=>{
del([base.dest+'**/*.*'],cbk)
gulp.task('clean', (cbk) => {
del([base.dest, '.tmp'], {force: true},cbk);
});

gulp.task('usemin',()=>{
gulp.task('usemin', ['build-scss'], () => {
return gulp.src('src/index.html')
.pipe(usemin({
style:[sass({outputStyle: 'compressed'}).on('error', sass.logError),autoprefix({
browsers:['> 1%','last 4 Android versions']
style: [autoprefix({
browsers: ['> 1%', 'last 4 Android versions']
})],
es6:[babel(),uglify()]
es6: [babel(), uglify()]
}))
.pipe(htmlminify())
.pipe(gulp.dest('build/'));
});



gulp.task('copy-assets',function () {
gulp.task('copy-assets', function () {
return gulp.src(['src/assets/**'], {base: 'src/assets'})
.pipe(gulp.dest('build/assets/'));
});
Expand All @@ -97,8 +102,7 @@ gulp.task('test-connect', function () {
});



gulp.task('build',
['clean', 'usemin', 'copy-assets']
['clean', 'usemin', 'copy-assets']
);
gulp.task('test',['build','test-connect']);
gulp.task('test', ['build', 'test-connect']);
10 changes: 5 additions & 5 deletions src/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="HandheldFriendly" content="true">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
<!--build:style css.css -->
<link rel="stylesheet" type="text/css" href="style/css.scss.css">
<link rel="stylesheet" type="text/css" href="style/keyframes.scss.css">
<link rel="stylesheet" type="text/css" href="style/media.scss.css">
<link rel="stylesheet" type="text/css" href="style/loader.scss.css">
<!--build:style(.tmp) css.css -->
<link rel="stylesheet" type="text/css" href="style/css.css">
<link rel="stylesheet" type="text/css" href="style/keyframes.css">
<link rel="stylesheet" type="text/css" href="style/media.css">
<link rel="stylesheet" type="text/css" href="style/loader.css">
<!-- endbuild -->
<link rel="stylesheet" href="//filehost.izhai.net/web/font-awesome/4.5.0/css/font-awesome.min.css">

Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit 3f199bf

Please sign in to comment.