Skip to content

Commit

Permalink
Remove deprecated scktool
Browse files Browse the repository at this point in the history
  • Loading branch information
oscgonfer committed Feb 29, 2024
1 parent 29c717d commit 2191e6c
Show file tree
Hide file tree
Showing 8 changed files with 36 additions and 17,790 deletions.
20 changes: 11 additions & 9 deletions gulp/build.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,8 @@ module.exports = function(options) {
};

var htmlFilter = $.filter('*.html', {restore: true});
var jsFilter = $.filter(['**/*.js', '!'+options.src+'/**/scktool-*.js'], {restore: true});
var jsFilter = $.filter(['**/*.js'], {restore: true});
// var jsFilter = $.filter(['**/*.js', '!'+options.src+'/**/scktool-*.js'], {restore: true});
var cssFilter = $.filter('**/*.css', {restore: true});
var assets;

Expand Down Expand Up @@ -135,13 +136,14 @@ module.exports = function(options) {
.pipe(gulp.dest(options.dist + '/styles/images'));
});

gulp.task('oldModule-js', function() {
return gulp.src([
options.src + '/app/components/kit/setupModule/scktool-app.js',
options.src + '/app/components/kit/setupModule/scktool-connector.js'
])
.pipe(gulp.dest(options.dist + '/scripts/'));
});
// gulp.task('oldModule-js', function() {
// return gulp.src([
// options.src + '/app/components/kit/setupModule/scktool-app.js',
// options.src + '/app/components/kit/setupModule/scktool-connector.js'
// ])
// .pipe(gulp.dest(options.dist + '/scripts/'));
// });

gulp.task('build', ['html', 'fonts', 'other', 'external-assets', 'oldModule-js', 'version']);
gulp.task('build', ['html', 'fonts', 'other', 'external-assets', 'version']);
// gulp.task('build', ['html', 'fonts', 'other', 'external-assets', 'oldModule-js', 'version']);
};
43 changes: 22 additions & 21 deletions gulp/inject.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ module.exports = function(options) {

var injectScripts = gulp.src([
options.src + '/app/**/*.js',
'!' + options.src + '/app/components/kit/setupModule/scktool-app.js',
'!' + options.src + '/app/components/kit/setupModule/scktool-connector.js',
// '!' + options.src + '/app/components/kit/setupModule/scktool-app.js',
// '!' + options.src + '/app/components/kit/setupModule/scktool-connector.js',
'!' + options.src + '/app/**/*.spec.js',
'!' + options.src + '/app/**/*.mock.js'
])
Expand All @@ -36,28 +36,29 @@ module.exports = function(options) {

});

gulp.task('inject:scktool', ['inject'], function() {
return gulp.src([
options.src + '/app/components/kit/setupModule/scktool-app.js',
options.src + '/app/components/kit/setupModule/scktool-connector.js'
])
.pipe(gulp.dest(options.tmp + '/serve/scripts/'));
});
// TODO: Refactor, check
// gulp.task('inject:scktool', ['inject'], function() {
// return gulp.src([
// options.src + '/app/components/kit/setupModule/scktool-app.js',
// options.src + '/app/components/kit/setupModule/scktool-connector.js'
// ])
// .pipe(gulp.dest(options.tmp + '/serve/scripts/'));
// });

gulp.task('inject:dev', function() {
// gulp.task('inject:dev', function() {

var injectModule = gulp.src([
options.src + '/app/components/kit/setupModule/scktool-app.js',
options.src + '/app/components/kit/setupModule/scktool-connector.js'
]);
// var injectModule = gulp.src([
// options.src + '/app/components/kit/setupModule/scktool-app.js',
// options.src + '/app/components/kit/setupModule/scktool-connector.js'
// ]);

var injectOptions = {
ignorePath: [options.src, options.tmp + '/serve'],
addRootSlash: false
};
// var injectOptions = {
// ignorePath: [options.src, options.tmp + '/serve'],
// addRootSlash: false
// };

return gulp.src(options.src + '/*.html')
.pipe($.inject(injectModule, injectOptions));
// return gulp.src(options.src + '/*.html')
// .pipe($.inject(injectModule, injectOptions));

});
// });
};
4 changes: 3 additions & 1 deletion gulp/watch.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,9 @@ function isOnlyChange(event) {
}

module.exports = function(options) {
gulp.task('watch', ['inject', 'inject:scktool'], function () {
// TODO: Refactor remove
// gulp.task('watch', ['inject', 'inject:scktool'], function () {
gulp.task('watch', ['inject'], function () {

gulp.watch([options.src + '/*.html', 'bower.json'], ['inject']);

Expand Down
Loading

0 comments on commit 2191e6c

Please sign in to comment.