Skip to content

Commit 7c88a01

Browse files
authored
Merge pull request #563 from haslinghuis/add_portable_windows
Add portable build to Windows
2 parents ba7470b + 94ddabe commit 7c88a01

File tree

2 files changed

+10
-3
lines changed

2 files changed

+10
-3
lines changed

assets/windows/installer.iss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
#define ExecutableFileName "betaflight-blackbox-explorer.exe"
1616
#define GroupName "Betaflight"
1717
#define InstallerFileName "betaflight-blackbox-explorer-installer_" + version + "_" + archName
18+
#define InstallerFileName "betaflight-blackbox-explorer_" + version + "_" + archName + "-installer"
1819
#define SourcePath "..\..\" + sourceFolder + "\betaflight-blackbox-explorer\" + archName
1920
#define TargetFolderName "Betaflight-Blackbox-Explorer"
2021
#define UpdatesUrl "https://github.com/betaflight/blackbox-log-viewer/releases/"

gulpfile.js

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -183,8 +183,8 @@ function getRunDebugAppCommand(arch) {
183183
return command;
184184
}
185185

186-
function getReleaseFilename(platform, ext) {
187-
return `${pkg.name}_${pkg.version}_${platform}.${ext}`;
186+
function getReleaseFilename(platform, ext, portable = false) {
187+
return `${pkg.name}_${pkg.version}_${platform}${portable ? "-portable" : ""}.${ext}`;
188188
}
189189

190190
function clean_dist() {
@@ -407,7 +407,7 @@ function release_win(arch, appDirectory, done) {
407407
// Create distribution package (zip) for windows and linux platforms
408408
function release_zip(arch, appDirectory) {
409409
const src = path.join(appDirectory, pkg.name, arch, '**');
410-
const output = getReleaseFilename(arch, 'zip');
410+
const output = getReleaseFilename(arch, 'zip', true);
411411
const base = path.join(appDirectory, pkg.name, arch);
412412

413413
return compressFiles(src, base, output, 'Betaflight Blackbox Explorer');
@@ -618,12 +618,18 @@ function listReleaseTasks(appDirectory) {
618618
}
619619

620620
if (platforms.indexOf('win32') !== -1) {
621+
releaseTasks.push(function release_win32_zip() {
622+
return release_zip('win32', appDirectory);
623+
});
621624
releaseTasks.push(function release_win32(done) {
622625
return release_win('win32', appDirectory, done);
623626
});
624627
}
625628

626629
if (platforms.indexOf('win64') !== -1) {
630+
releaseTasks.push(function release_win64_zip() {
631+
return release_zip('win64', appDirectory);
632+
});
627633
releaseTasks.push(function release_win64(done) {
628634
return release_win('win64', appDirectory, done);
629635
});

0 commit comments

Comments
 (0)