modify appxmanifest version on dist
This commit is contained in:
parent
1b344ade0d
commit
e09e15f72f
21
gulpfile.js
21
gulpfile.js
|
@ -14,7 +14,9 @@
|
|||
jeditor = require("gulp-json-editor"),
|
||||
gulpUtil = require('gulp-util'),
|
||||
child = require('child_process'),
|
||||
zip = require('gulp-zip');
|
||||
zip = require('gulp-zip'),
|
||||
manifest = require('./src/manifest.json'),
|
||||
xmlpoke = require('gulp-xmlpoke');
|
||||
|
||||
var paths = {};
|
||||
paths.dist = './dist/';
|
||||
|
@ -296,6 +298,23 @@ gulp.task('dist-edge', ['dist'], function (cb) {
|
|||
.pipe(gulp.dest(paths.dist + 'Extension'))
|
||||
.on('end', resolve);
|
||||
});
|
||||
}).then(function () {
|
||||
// modify appxmanifest
|
||||
return new Promise(function (resolve, reject) {
|
||||
gulp.src(paths.dist + '/AppxManifest.xml')
|
||||
.pipe(xmlpoke({
|
||||
replacements: [{
|
||||
xpath: '/p:Package/p:Identity/@Version',
|
||||
value: manifest.version + '.0',
|
||||
namespaces: {
|
||||
'p': 'http://schemas.microsoft.com/appx/manifest/foundation/windows10'
|
||||
}
|
||||
}]
|
||||
}))
|
||||
.on('error', reject)
|
||||
.pipe(gulp.dest(paths.dist))
|
||||
.on('end', resolve);
|
||||
});
|
||||
}).then(function () {
|
||||
// makeappx.exe must be in your system's path already
|
||||
child.spawn('makeappx.exe', ['pack', '/h', 'SHA256', '/d', paths.dist, '/p', paths.dist + 'bitwarden.appx']);
|
||||
|
|
|
@ -41,6 +41,7 @@
|
|||
"web-ext": "2.0.0",
|
||||
"child_process": "1.0.2",
|
||||
"gulp-util": "3.0.8",
|
||||
"gulp-zip": "4.0.0"
|
||||
"gulp-zip": "4.0.0",
|
||||
"gulp-xmlpoke": "0.2.1"
|
||||
}
|
||||
}
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
<Identity
|
||||
Name="8bitSolutionsLLC.bitwarden-FreePasswordManager"
|
||||
Publisher="CN=14D52771-DE3C-4886-B8BF-825BA7690418"
|
||||
Version="1.15.4.0"/>
|
||||
Version="0.0.0.0"/>
|
||||
|
||||
<Properties>
|
||||
<DisplayName>bitwarden - Free Password Manager</DisplayName>
|
||||
|
|
Loading…
Reference in New Issue