From d07547062ea3af53aa9b214b60ae0e51b28095f0 Mon Sep 17 00:00:00 2001 From: Jaifroid Date: Wed, 12 May 2021 21:18:21 +0100 Subject: [PATCH] Final fixes to script Former-commit-id: e72559d117fe050ddc093810006bb81614d36350 [formerly 3b1f85fff26605f423b6b87f22e0f35ba409cc10] [formerly d9828d8c8f5b60cdde4481c516c7955377e1c4c2] [formerly 6c805bc4d478505adce70bec810b747fc9ea4b49 [formerly 1726ae39e316959a9a3d9ab1e029273536cd1764 [formerly 65f03461fe197a5fca81edf82ee246e372e3160e]]] Former-commit-id: 64d132b975d157f388433b0f054f1fff0852a612 [formerly 037d0d31fd2d3de084ab620e839c41feca3c23c1 [formerly d164fe29dd60b6b64ce65dc470f540f95751551d]] Former-commit-id: ca5dfcc2f80676e53c867845badb2de71ef63403 [formerly 3b319f02c75d83209b4c441dabb04a491c96e126] Former-commit-id: 0b8059f005c7ec8ffa19b366c453a9924074dacb --- scripts/Create-DraftRelease.ps1 | 10 ++++++++-- scripts/Kiwix_JS_WikiMed_E_Release_Body.md | 2 +- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/scripts/Create-DraftRelease.ps1 b/scripts/Create-DraftRelease.ps1 index f04b2076..cab13d46 100644 --- a/scripts/Create-DraftRelease.ps1 +++ b/scripts/Create-DraftRelease.ps1 @@ -1,7 +1,8 @@ param ( [string]$tag_name = "", [switch]$dryrun = $false, - [switch]$usetestrelease = $false + [switch]$usetestrelease = $false, + [switch]$draftonly = $false ) # Provide parameters @@ -53,7 +54,7 @@ if ($base_tag -match '[EN]$') { $title_flavour = 'NWJS' $branch = 'nwjs-en-top' } - $release_title = $release_title -replace '([^\s]+)\sUWP$', ("$title_flavour Edition (Window/Linux) " + '$1') + $release_title = $release_title -replace '([^\s]+)\sUWP$', ("$title_flavour Edition (Windows/Linux) " + '$1') if ($flavour -eq '_N') { $release_title = $release_title -replace 'Edition\s(for\s)', '$1XP/Vista/' } } "Text tag: $text_tag" @@ -103,6 +104,11 @@ if ($dryrun -or $release.assets_url -imatch '^https:') { } else { Set-Content "$PSScriptRoot/../package.json" $json_object } + if ($draftonly) { + "`nDraft only switch was set, so we will not upload assets. Please do so manually." + "Done." + return + } "Searching for assets..." if ($flavour -eq '_E') { $base_dir = "$PSScriptRoot/../bld/electron/" diff --git a/scripts/Kiwix_JS_WikiMed_E_Release_Body.md b/scripts/Kiwix_JS_WikiMed_E_Release_Body.md index a2b0d4c5..4275fd25 100644 --- a/scripts/Kiwix_JS_WikiMed_E_Release_Body.md +++ b/scripts/Kiwix_JS_WikiMed_E_Release_Body.md @@ -21,7 +21,7 @@ If you intend to use this app with other archives than WikiMed, then download th * For the Windows Portable build, unzip the contents of the [Kiwix JS WikiMed <>.zip archive](https://github.com/kiwix/kiwix-js-windows/releases/download/v<>-WikiMed/Kiwix.JS.WikiMed.<>.zip) to any folder, or to a flash drive / thumb drive, and double click on `Start Kiwix JS WikiMed` or `Start Kiwix JS WikiMed via batch file.bat`, or open the `kiwix-js-windows-win32-ia32` folder and double click on `kiwix-js-windows.exe`; * For the Windows Setup (installable) build, simply download and launch. It will install itself, together with a shortcut in your shortcut menu, and run. When you want to update the app, uninstall it from "Add or Remove Programs". * For the Linux builds (which are both portable), download and save the correct AppImage file anywhere (e.g. your Desktop), and double-click it. If it doesn't work, open Terminal and run `chmod a+x Kiwix.JS.WikiMed*.AppImage` and then `./Kiwix.JS.WikiMed*.AppImage`; -* Windows: **Because the portable archive may not be commonly downloaded, you may face Windows SmartScreen issues** on first launch. Follow instructions to "Run anyway" if you trust this site. If you prefer, use the installable version [Kiwix JS WikiMed-<>-E-i386.AppImage](https://github.com/kiwix/kiwix-js-windows/releases/download/v<>-WikiMed/Kiwix.JS.WikiMed-<>-E-i386.AppImage) which is digitally signed. +* Windows: **Because the portable archive may not be commonly downloaded, you may face Windows SmartScreen issues** on first launch. Follow instructions to "Run anyway" if you trust this site. If you prefer, use the installable version [Kiwix JS WikiMed Setup <>-E.exe](https://github.com/kiwix/kiwix-js-windows/releases/download/v<>-WikiMed/Kiwix.JS.WikiMed.Setup.<>-E.exe) which is digitally signed. ### Release Notes