Skip to content

Commit c8f760f

Browse files
committed
chore(build): rename ionic directory to src and update all references in the build process.
1 parent 8470ae0 commit c8f760f

File tree

595 files changed

+73
-87
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

595 files changed

+73
-87
lines changed

.scss-lint.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,11 @@
33
# See config at https://github.com/brigade/scss-lint/blob/master/config/default.yml
44

55
exclude:
6-
- 'ionic/components/slides/**'
7-
- 'ionic/components/show-hide-when/**'
8-
- 'ionic/components.*.scss'
9-
- 'ionic/util/*.scss'
10-
- 'ionic/platform/cordova.*.scss'
6+
- 'src/components/slides/**'
7+
- 'src/components/show-hide-when/**'
8+
- 'src/components.*.scss'
9+
- 'src/util/*.scss'
10+
- 'src/platform/cordova.*.scss'
1111

1212

1313
linters:

demos/app.ios.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
@import "../ionic/ionic.ios";
1+
@import "../src/ionic.ios";

demos/app.md.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
@import "../ionic/ionic.md";
1+
@import "../src/ionic.md";

demos/output.ios.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,4 +33,4 @@ $colors: (
3333
bright: #FFC125
3434
);
3535

36-
@import "../ionic/ionic.ios";
36+
@import "../src/ionic.ios";

demos/output.md.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,4 +33,4 @@ $colors: (
3333
bright: #FFC125
3434
);
3535

36-
@import "../ionic/ionic.md";
36+
@import "../src/ionic.md";

gulpfile.js

Lines changed: 35 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -86,9 +86,9 @@ gulp.task('watch', ['build'], function() {
8686

8787
function watchTask(task){
8888
watch([
89-
'ionic/**/*.ts',
90-
'!ionic/components/*/test/**/*',
91-
'!ionic/util/test/*'
89+
'src/**/*.ts',
90+
'!src/components/*/test/**/*',
91+
'!src/util/test/*'
9292
],
9393
function(file) {
9494
if (file.event === "unlink") {
@@ -99,7 +99,7 @@ function watchTask(task){
9999
}
100100
);
101101

102-
watch('ionic/**/*.scss', function() {
102+
watch('src/**/*.scss', function() {
103103
gulp.start('sass');
104104
});
105105

@@ -201,7 +201,7 @@ gulp.task('bundle.system', function(){
201201
var tsResult = tsCompile(getTscOptions('es6'), 'system')
202202
.pipe(babel(babelOptions));
203203

204-
var swiper = gulp.src('ionic/components/slides/swiper-widget.system.js');
204+
var swiper = gulp.src('src/components/slides/swiper-widget.system.js');
205205

206206
return merge([tsResult, swiper])
207207
.pipe(remember('system'))
@@ -246,13 +246,13 @@ gulp.task('transpile', function(){
246246
function tsCompile(options, cacheName){
247247
return gulp.src([
248248
'typings/main.d.ts',
249-
'ionic/**/*.ts',
250-
'!ionic/**/*.d.ts',
251-
'!ionic/components/*/test/**/*',
252-
'!ionic/util/test/*',
253-
'!ionic/config/test/*',
254-
'!ionic/platform/test/*',
255-
'!ionic/**/*.spec.ts'
249+
'src/**/*.ts',
250+
'!src/**/*.d.ts',
251+
'!src/components/*/test/**/*',
252+
'!src/util/test/*',
253+
'!src/config/test/*',
254+
'!src/platform/test/*',
255+
'!src/**/*.spec.ts'
256256
])
257257
.pipe(cache(cacheName, { optimizeMemory: true }))
258258
.pipe(tsc(options, undefined, tscReporter));
@@ -267,10 +267,10 @@ gulp.task('sass', function() {
267267
var minifyCss = require('gulp-minify-css');
268268

269269
gulp.src([
270-
'ionic/ionic.ios.scss',
271-
'ionic/ionic.md.scss',
272-
'ionic/ionic.wp.scss',
273-
'ionic/ionic.scss'
270+
'src/ionic.ios.scss',
271+
'src/ionic.md.scss',
272+
'src/ionic.wp.scss',
273+
'src/ionic.scss'
274274
])
275275
.pipe(sass({
276276
includePaths: [__dirname + '/node_modules/ionicons/dist/scss/'],
@@ -312,7 +312,7 @@ gulp.task('sass.themes', function() {
312312
*/
313313
gulp.task('fonts', function() {
314314
gulp.src([
315-
'ionic/fonts/*.+(ttf|woff|woff2)',
315+
'src/fonts/*.+(ttf|woff|woff2)',
316316
'node_modules/ionicons/dist/fonts/*.+(ttf|woff|woff2)'
317317
])
318318
.pipe(gulp.dest('dist/fonts'));
@@ -323,9 +323,9 @@ gulp.task('fonts', function() {
323323
*/
324324
gulp.task('copy.scss', function() {
325325
return gulp.src([
326-
'ionic/**/*.scss',
327-
'!ionic/components/*/test/**/*',
328-
'!ionic/util/test/*'
326+
'src/**/*.scss',
327+
'!src/components/*/test/**/*',
328+
'!src/util/test/*'
329329
])
330330
.pipe(gulp.dest('dist'));
331331
});
@@ -337,9 +337,9 @@ gulp.task('lint.scss', function() {
337337
var scsslint = require('gulp-scss-lint');
338338

339339
return gulp.src([
340-
'ionic/**/*.scss',
341-
'!ionic/components/*/test/**/*',
342-
'!ionic/util/test/*'
340+
'src/**/*.scss',
341+
'!src/components/*/test/**/*',
342+
'!src/util/test/*'
343343
])
344344
.pipe(scsslint())
345345
.pipe(scsslint.failReporter());
@@ -363,8 +363,8 @@ gulp.task('copy.libs', function() {
363363

364364
// for swiper-widget
365365
var libs = gulp.src([
366-
'ionic/**/*.js',
367-
'ionic/**/*.d.ts'
366+
'src/**/*.js',
367+
'src/**/*.d.ts'
368368
])
369369
.pipe(gulp.dest('dist'));
370370

@@ -383,7 +383,7 @@ gulp.task('copy.libs', function() {
383383
gulp.task('watch.e2e', ['e2e'], function() {
384384
watchTask('bundle.system');
385385

386-
watch('ionic/components/*/test/**/*', function(file) {
386+
watch('src/components/*/test/**/*', function(file) {
387387
gulp.start('e2e.build');
388388
});
389389
});
@@ -419,8 +419,8 @@ gulp.task('e2e.build', function() {
419419

420420
// Get each test folder with gulp.src
421421
var tsResult = gulp.src([
422-
'ionic/components/*/test/*/**/*.ts',
423-
'!ionic/components/*/test/*/**/*.spec.ts'
422+
'src/components/*/test/*/**/*.ts',
423+
'!src/components/*/test/*/**/*.spec.ts'
424424
])
425425
.pipe(cache('e2e.ts'))
426426
.pipe(tsc(getTscOptions(), undefined, tscReporter))
@@ -431,8 +431,8 @@ gulp.task('e2e.build', function() {
431431
.pipe(gulpif(/e2e.js$/, createPlatformTests()))
432432

433433
var testFiles = gulp.src([
434-
'ionic/components/*/test/*/**/*',
435-
'!ionic/components/*/test/*/**/*.ts'
434+
'src/components/*/test/*/**/*',
435+
'!src/components/*/test/*/**/*.ts'
436436
])
437437
.pipe(cache('e2e.files'))
438438

@@ -461,7 +461,7 @@ gulp.task('e2e.build', function() {
461461
function createPlatformTests(file) {
462462
return through2.obj(function(file, enc, next) {
463463
var self = this;
464-
var relativePath = path.dirname(file.path.replace(/^.*?ionic(\/|\\)components(\/|\\)/, ''));
464+
var relativePath = path.dirname(file.path.replace(/^.*?src(\/|\\)components(\/|\\)/, ''));
465465
relativePath = relativePath.replace('/test/', '/');
466466
var contents = file.contents.toString();
467467
platforms.forEach(function(platform) {
@@ -486,7 +486,7 @@ gulp.task('e2e.build', function() {
486486
* Builds Ionic unit tests to dist/tests.
487487
*/
488488
gulp.task('tests', function() {
489-
return gulp.src('ionic/**/test/**/*.spec.ts')
489+
return gulp.src('src/**/test/**/*.spec.ts')
490490
.pipe(cache('tests'))
491491
.pipe(tsc(getTscOptions(), undefined, tscReporter))
492492
.pipe(rename(function(file) {
@@ -497,7 +497,7 @@ gulp.task('tests', function() {
497497
});
498498

499499
gulp.task('watch.tests', ['tests'], function(){
500-
watch('ionic/**/test/**/*.spec.ts', function(){
500+
watch('src/**/test/**/*.spec.ts', function(){
501501
gulp.start('tests');
502502
});
503503
});
@@ -983,8 +983,8 @@ gulp.task('validate', function(done) {
983983
gulp.task('tslint', function() {
984984
var tslint = require('gulp-tslint');
985985
return gulp.src([
986-
'ionic/**/*.ts',
987-
'!ionic/**/test/**/*',
986+
'src/**/*.ts',
987+
'!src/**/test/**/*',
988988
]).pipe(tslint())
989989
.pipe(tslint.report('verbose'));
990990
});

scripts/build/config.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,13 @@
22
module.exports = {
33
dist: 'dist',
44
src: {
5-
spec: ['ionic/**/test/*.spec.js'],
6-
js: ['ionic/**/*.js'],
5+
spec: ['src/**/test/*.spec.js'],
6+
js: ['src/**/*.js'],
77

88
// Get all the non-js files and main.js
9-
e2e: ['ionic/components/*/test/*/**/*'],
10-
html: 'ionic/**/*.html',
11-
scss: 'ionic/**/*.scss',
9+
e2e: ['src/components/*/test/*/**/*'],
10+
html: 'src/**/*.html',
11+
scss: 'src/**/*.scss',
1212
},
1313

1414
scripts: [

scripts/demos/index.template.html

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -18,19 +18,5 @@
1818
</ion-app>
1919

2020
<script src="bundle.js"></script>
21-
<!-- <script src="../../js/ionic.bundle.js"></script>
22-
23-
<script>
24-
System.config({
25-
"paths": {
26-
"*": "*.js",
27-
"ionic/*": "ionic/*",
28-
"angular2/*": "angular2/*",
29-
"rx": "rx"
30-
}
31-
})
32-
System.import("index");
33-
</script> -->
34-
3521
</body>
3622
</html>

scripts/docs/dgeni-config.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -94,13 +94,13 @@ module.exports = function(currentVersion) {
9494
docTypes: ['class', 'var', 'function', 'let'],
9595
getOutputPath: function(doc) {
9696
// strip ionic from path root
97-
var docPath = doc.fileInfo.relativePath.replace(/^ionic\//, '');
97+
var docPath = doc.fileInfo.relativePath.replace(/^src\//, '');
9898
// remove filename since we have multiple docTypes per file
9999
docPath = docPath.substring(0, docPath.lastIndexOf('/') + 1);
100100
docPath += doc.name + '/index.md';
101101
var path = config.v2DocsDir + '/' + (versionData.current.folder || '') +
102102
'/api/' + docPath;
103-
path = path.replace('/home/ubuntu/ionic/ionic', '')
103+
path = path.replace('/home/ubuntu/ionic/src', '')
104104
return path;
105105
}
106106
}];
@@ -115,7 +115,7 @@ module.exports = function(currentVersion) {
115115

116116
readTypeScriptModules.basePath = path.resolve(path.resolve(__dirname, '../..'));
117117
readTypeScriptModules.sourceFiles = [
118-
'ionic/index.ts'
118+
'src/index.ts'
119119
];
120120
})
121121

scripts/docs/gulp-tasks.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ module.exports = function(gulp, flags) {
5555
});
5656
}
5757

58-
return gulp.src('ionic/**/*.scss')
58+
return gulp.src('src/**/*.scss')
5959
.pipe(es.map(function(file, callback) {
6060
var contents = file.contents.toString();
6161
var variableLine, variableName, defaultValue, multiline;

0 commit comments

Comments
 (0)