adding url context path to html templates (#814)

This commit is contained in:
Henry Megarry
2017-05-25 12:20:32 -05:00
committed by kevgliss
parent 21d48b32c9
commit 31f4cf0253
2 changed files with 11 additions and 5 deletions

View File

@ -232,10 +232,16 @@ gulp.task('package:strip', function () {
gulp.task('addUrlContextPath',['addUrlContextPath:revreplace'], function(){
var urlContextPathExists = argv.urlContextPath ? true : false;
return gulp.src('lemur/static/dist/scripts/main*.js')
.pipe(gulpif(urlContextPathExists, replace('api/', argv.urlContextPath + '/api/')))
.pipe(gulpif(urlContextPathExists, replace('angular/', argv.urlContextPath + '/angular/')))
.pipe(gulp.dest('lemur/static/dist/scripts'))
['lemur/static/dist/scripts/main*.js',
'lemur/static/dist/angular/**/*.html']
.forEach(function(file){
return gulp.src(file)
.pipe(gulpif(urlContextPathExists, replace('api/', argv.urlContextPath + '/api/')))
.pipe(gulpif(urlContextPathExists, replace('angular/', argv.urlContextPath + '/angular/')))
.pipe(gulp.dest(function(file){
return file.base;
}))
})
});
gulp.task('addUrlContextPath:revision', function(){