Skip to content

Commit 0317587

Browse files
committed
moving away from CI as a build step
1 parent a5934ec commit 0317587

File tree

11 files changed

+39
-32
lines changed

11 files changed

+39
-32
lines changed

Diff for: Gulpfile.js

+27-14
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ var prefix = require('gulp-autoprefixer');
1616
var rename = require('gulp-rename');
1717
var runSequence = require('run-sequence');
1818
var sass = require('gulp-sass');
19+
var server = require('gulp-develop-server');
1920
var shell = require('gulp-shell');
2021
var uglify = require('gulp-uglify');
2122

@@ -26,15 +27,13 @@ var messages = {
2627
};
2728

2829
var AUTOPREFIXER_BROWSERS = [
29-
'ie >= 9',
30-
'ie_mob >= 9',
31-
'ff >= 30',
32-
'chrome >= 34',
33-
'safari >= 7',
30+
'ie >= 10',
31+
'ff >= 45',
32+
'chrome >= 54',
33+
'safari >= 9',
3434
'opera >= 23',
35-
'ios >= 7',
36-
'android >= 4.4',
37-
'bb >= 10'
35+
'ios >= 9',
36+
'android >= 4.4'
3837
];
3938
var closureStart =
4039
'/*!\n' +
@@ -70,7 +69,7 @@ function bustCacheAndReload(done) {
7069

7170

7271
bustCache().on('end', function() {
73-
// browserSync.reload();
72+
browserSync.reload();
7473
done();
7574
// apply the template change in the background
7675
// gulp.start('jekyll-build.incremental');
@@ -178,13 +177,26 @@ gulp.task('jekyll-rebuild', ['jekyll-build'], function() {
178177
browserSync.reload();
179178
});
180179

180+
gulp.task('server-listen', function() {
181+
return server.listen({ 'path': './server.js', 'execArgv': ['--harmony'] },
182+
function(error) {
183+
if (!error) {
184+
browserSync({ 'proxy': 'http://localhost:3000', 'port': 3003 });
185+
}
186+
});
187+
});
188+
181189
/**
182190
* Wait for jekyll-build, then launch the Server
183191
*/
184-
gulp.task('server', ['build'], function() {
185-
browserSync({
186-
server: {
187-
baseDir: '_site'
192+
gulp.task('server', function() {
193+
return runSequence('build', 'server-listen');
194+
});
195+
196+
gulp.task('server:server', function() {
197+
server.restart(function(err) {
198+
if (!err) {
199+
browserSync.reload();
188200
}
189201
});
190202
});
@@ -196,7 +208,8 @@ gulp.task('server:stylesv2', ['styles:v2'], bustCacheAndReload);
196208
gulp.task('server:js', ['js'], bustCacheAndReload);
197209

198210
gulp.task('watch', ['server'], function() {
199-
gulp.watch('scss/**.scss', ['server:stylesv1']);
211+
gulp.watch(['server/**/*'], ['server:server']);
212+
gulp.watch('content/scss/**.scss', ['server:stylesv1']);
200213
gulp.watch(['assets/scss/**/*.scss'], ['server:stylesv2']);
201214
gulp.watch(['assets/img/**/*.{jpg,png,gif}'], ['images']);
202215
gulp.watch(['assets/js/**/*.js', 'submit-issue/*/*.js'], ['server:js']);

Diff for: Procfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
web: node app.js
1+
web: node server.js

Diff for: completer.hist

-3
This file was deleted.

Diff for: content/_includes/head_includes.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<link href="/css/site.css?v=39ca13080d3e3e289429a4d447d80717" rel="stylesheet">
1+
<link href="/css/site.css?v=3443c5c831571f5ff4622ceb223bff7c" rel="stylesheet">
22
<!--<script src="//cdn.optimizely.com/js/595530035.js"></script>-->
33
<script type="text/javascript">var _sf_startpt=(new Date()).getTime()</script>
44

Diff for: content/_includes/v2_fluid/head.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<meta charset="utf-8">
22
<meta name="viewport" content="width=device-width, initial-scale=1.0">
33

4-
<link href="/css/styles.min.css?v=f8e5c1b98f73d0cc4c21800fd5854047" rel="stylesheet">
4+
<link href="/css/styles.min.css?v=93371b1bd553705ebe31ae4d8615afa3" rel="stylesheet">
55

66
{% if page.category == 'api' %}
77
<title>{{page.title}}{% if page.header_sub_title %} - {{ page.header_sub_title}}{% endif %} - Ionic Framework</title>

Diff for: content/css/bootstrap/bootstrap.css

-2
Original file line numberDiff line numberDiff line change
@@ -3857,13 +3857,11 @@ body.modal-open {
38573857
z-index: 1040; }
38583858
.modal.fade .modal-dialog {
38593859
-webkit-transform: translate(0, -25%);
3860-
-ms-transform: translate(0, -25%);
38613860
transform: translate(0, -25%);
38623861
transition: -webkit-transform 0.3s ease-out;
38633862
transition: transform 0.3s ease-out; }
38643863
.modal.in .modal-dialog {
38653864
-webkit-transform: translate(0, 0);
3866-
-ms-transform: translate(0, 0);
38673865
transform: translate(0, 0); }
38683866

38693867
.modal-dialog {

Diff for: content/css/bootstrap/bootstrap.min.css

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Diff for: package.json

+6-7
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"description": "Ionic Framework main site - IonicFramework.com",
55
"main": "Gulpfile.js",
66
"engines": {
7-
"node": "6.7.0"
7+
"node": "6.9.2"
88
},
99
"repository": {
1010
"type": "git",
@@ -15,16 +15,19 @@
1515
"url": "https://github.com/driftyco/ionic-site/issues"
1616
},
1717
"homepage": "https://github.com/driftyco/ionic-site",
18-
"devDependencies": {
18+
"dependencies": {
1919
"browser-sync": "^1.3.7",
20+
"compression": "^1.4.6",
2021
"event-stream": "^3.3.1",
22+
"express": "^4.12.3",
2123
"gulp": "^3.8.8",
2224
"gulp-autoprefixer": "1.0.0",
2325
"gulp-cache": "^0.4.1",
2426
"gulp-cache-bust": "perrygovier/gulp-cache-bust",
2527
"gulp-changed": "^1.0.0",
2628
"gulp-concat": "^2.2.0",
2729
"gulp-csso": "^1.0.0",
30+
"gulp-develop-server": "^0.5.2",
2831
"gulp-footer": "^1.0.5",
2932
"gulp-header": "^1.7.1",
3033
"gulp-if": "^1.2.1",
@@ -41,16 +44,12 @@
4144
"gulp-uglify": "^1.4.1",
4245
"gulp-util": "^3.0.6",
4346
"htmlparser2": "^3.8.3",
47+
"ionicons": "^3.0.0-alpha.3",
4448
"js-yaml": "^3.4.2",
4549
"lunr": "^0.5.12",
4650
"mkdirp": "^0.5.1",
4751
"psi": "^1.0.4",
4852
"run-sequence": "^1.2.2",
4953
"tiny-lr": "0.0.5"
50-
},
51-
"dependencies": {
52-
"compression": "^1.4.6",
53-
"express": "^4.12.3",
54-
"ionicons": "^3.0.0-alpha.3"
5554
}
5655
}

Diff for: content/app.js renamed to server.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -30,13 +30,13 @@ app.set('trust proxy', true);
3030
app.use(compress());
3131
app.use(processRequest);
3232

33-
app.use(express.static(process.env.PWD, {
33+
app.use(express.static(process.env.PWD + '/_site/', {
3434
maxage: 315360000000 // ten years
3535
}));
3636

3737
app.use(function(req, res, next) {
3838
res.status(404);
39-
res.sendFile(__dirname + '/404.html');
39+
res.sendFile(__dirname + '/_site/404.html');
4040
});
4141

4242
// bind the app to listen for connections on a specified port
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)