Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 46d855e

Browse files
committed
chore: PR comments
1 parent e1718c9 commit 46d855e

File tree

3 files changed

+19
-7
lines changed

3 files changed

+19
-7
lines changed

scripts/build_windows_installer.sh

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -59,14 +59,15 @@ if [[ ! -f "$1" ]]; then
5959
fi
6060
input_file="$(realpath "$1")"
6161

62-
# Remove the "v" prefix and ensure the version is in the format X.X.X.X for
63-
# makensis.
6462
version="${version#v}"
6563
if [[ "$version" == "" ]]; then
6664
version="$(execrelative ./version.sh)"
6765
fi
68-
version="${version//-*/}"
69-
version+=".$(date -u +%Y%m%d%H%M)"
66+
67+
# Remove the "v" prefix and ensure the version is in the format X.X.X.X for
68+
# makensis.
69+
nsis_version="${version//-*/}"
70+
nsis_version+=".$(date -u +%Y%m%d%H%M)"
7071

7172
# Check dependencies
7273
dependencies makensis
@@ -113,6 +114,7 @@ pushd "$temp_dir"
113114
makensis \
114115
-V4 \
115116
-DCODER_VERSION="$version" \
117+
-DCODER_NSIS_VERSION="$nsis_version" \
116118
-DCODER_YEAR="$(date +%Y)" \
117119
installer.nsi
118120
popd

scripts/win-installer/installer.nsi

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ Unicode true
66

77
!define APP_NAME "Coder"
88
!define COMP_NAME "Coder Technologies, Inc."
9-
!define VERSION "${CODER_VERSION}"
9+
!define VERSION "${CODER_NSIS_VERSION}"
1010
!define COPYRIGHT "Copyright (c) ${CODER_YEAR} Coder Technologies, Inc."
1111
!define DESCRIPTION "Remote development environments on your infrastructure provisioned with Terraform"
1212
!define INSTALLER_NAME "installer.exe"
@@ -37,7 +37,7 @@ SetCompressor /SOLID Lzma
3737
Name "${APP_NAME}"
3838
Caption "${APP_NAME}"
3939
OutFile "${INSTALLER_NAME}"
40-
BrandingText "${APP_NAME}"
40+
BrandingText "${APP_NAME} v${CODER_VERSION}"
4141
InstallDirRegKey "${REG_ROOT}" "${REG_APP_PATH}" "Path"
4242
InstallDir "${INSTALL_DIR}"
4343

@@ -55,6 +55,8 @@ InstallDir "${INSTALL_DIR}"
5555
!define MUI_ABORTWARNING
5656
!define MUI_UNABORTWARNING
5757

58+
!define MUI_WELCOMEPAGE_TEXT "Setup will guide you through the installation of Coder v${CODER_VERSION}.$\r$\n$\r$\nClick Next to continue."
59+
5860
!insertmacro MUI_PAGE_WELCOME
5961

6062
!insertmacro MUI_PAGE_LICENSE "${LICENSE_TXT}"
@@ -65,7 +67,7 @@ InstallDir "${INSTALL_DIR}"
6567

6668
!insertmacro MUI_PAGE_INSTFILES
6769

68-
!define MUI_FINISHPAGE_TEXT "Coder has been installed on your computer.$\r$\n$\r$\nTo use Coder, sign out and back in, then open a command prompt or PowerShell and run `coder`.$\r$\n$\r$\nClick Finish to close Setup."
70+
!define MUI_FINISHPAGE_TEXT "Coder v${CODER_VERSION} has been installed on your computer.$\r$\n$\r$\nIf you added Coder to your PATH, you can use Coder by opening a command prompt or PowerShell and running `coder`. You may have to sign out and sign back in for `coder` to be available.$\r$\n$\r$\nClick Finish to close Setup."
6971

7072
!insertmacro MUI_PAGE_FINISH
7173

scripts/win-installer/path.nsh

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,14 @@
11
# PATH utilities. Taken from:
22
# https://www.smartmontools.org/browser/trunk/smartmontools/os_win32/installer.nsi?rev=5310#L689
33

4+
; os_win32/installer.nsi - smartmontools install NSIS script
5+
;
6+
; Home page of code is: https://www.smartmontools.org
7+
;
8+
; Copyright (C) 2006-22 Christian Franke
9+
;
10+
; SPDX-License-Identifier: GPL-2.0-or-later
11+
412

513
;--------------------------------------------------------------------
614
; Path functions

0 commit comments

Comments
 (0)