mirror of
https://github.com/bitwarden/browser.git
synced 2025-01-02 18:17:46 +01:00
buildstring function
This commit is contained in:
parent
333c4f74e4
commit
1360d930a9
14
gulpfile.js
14
gulpfile.js
@ -27,13 +27,16 @@ const fontsFilter = [
|
|||||||
'build/popup/fonts/fontawesome*.woff'
|
'build/popup/fonts/fontawesome*.woff'
|
||||||
];
|
];
|
||||||
|
|
||||||
function distFileName(browserName, ext) {
|
function buildString() {
|
||||||
var build = '';
|
var build = '';
|
||||||
if (process.env.APPVEYOR_BUILD_NUMBER && process.env.APPVEYOR_BUILD_NUMBER !== '') {
|
if (process.env.APPVEYOR_BUILD_NUMBER && process.env.APPVEYOR_BUILD_NUMBER !== '') {
|
||||||
build = `-${process.env.APPVEYOR_BUILD_NUMBER}`;
|
build = `-${process.env.APPVEYOR_BUILD_NUMBER}`;
|
||||||
}
|
}
|
||||||
|
return build;
|
||||||
|
}
|
||||||
|
|
||||||
return `dist-${browserName}${build}.${ext}`;
|
function distFileName(browserName, ext) {
|
||||||
|
return `dist-${browserName}${buildString()}.${ext}`;
|
||||||
}
|
}
|
||||||
|
|
||||||
function dist(browserName, manifest) {
|
function dist(browserName, manifest) {
|
||||||
@ -138,14 +141,9 @@ gulp.task('webfonts', () => {
|
|||||||
gulp.task('ci', ['ci:coverage']);
|
gulp.task('ci', ['ci:coverage']);
|
||||||
|
|
||||||
gulp.task('ci:coverage', (cb) => {
|
gulp.task('ci:coverage', (cb) => {
|
||||||
var build = '';
|
|
||||||
if (process.env.APPVEYOR_BUILD_NUMBER && process.env.APPVEYOR_BUILD_NUMBER !== '') {
|
|
||||||
build = `-${process.env.APPVEYOR_BUILD_NUMBER}`;
|
|
||||||
}
|
|
||||||
|
|
||||||
return gulp.src(paths.coverage + '**/*')
|
return gulp.src(paths.coverage + '**/*')
|
||||||
.pipe(filter(['**', '!coverage/coverage*.zip']))
|
.pipe(filter(['**', '!coverage/coverage*.zip']))
|
||||||
.pipe(zip(`coverage${build}.zip`))
|
.pipe(zip(`coverage${buildString()}.zip`))
|
||||||
.pipe(gulp.dest(paths.coverage));
|
.pipe(gulp.dest(paths.coverage));
|
||||||
});
|
});
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user