Skip to content

Commit

Permalink
feat: 1/2 branding
Browse files Browse the repository at this point in the history
  • Loading branch information
GeopJr authored Dec 18, 2024
1 parent e6164f6 commit dc35eac
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 6 deletions.
8 changes: 6 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@ __windows_set_icon:
ifeq (,$(wildcard ./rcedit-x64.exe))
wget https://github.com/electron/rcedit/releases/download/v1.1.1/rcedit-x64.exe
endif
rsvg-convert ./data/icons/color-nightly.svg -o ./builddir/color-nightly.png -h 256 -w 256
magick -density "256x256" -background transparent ./builddir/color-nightly.png -define icon:auto-resize -colors 256 ./builddir/dev.geopjr.Tuba.ico
rsvg-convert ./data/icons/color$(if $(release),,-nightly).svg -o ./builddir/color$(if $(release),,-nightly).png -h 256 -w 256
magick -density "256x256" -background transparent ./builddir/color$(if $(release),,-nightly).png -define icon:auto-resize -colors 256 ./builddir/dev.geopjr.Tuba.ico
./rcedit-x64.exe $(PREFIX)/bin/dev.geopjr.Tuba.exe --set-icon ./builddir/dev.geopjr.Tuba.ico

__windows_copy_deps:
Expand Down Expand Up @@ -87,4 +87,8 @@ windows_nsis:
cp ./builddir/dev.geopjr.Tuba.ico nsis/
cp ./builddir/dev.geopjr.Tuba.nsi nsis/
mv tuba_windows_portable/ nsis/
magick ./builddir/color$(if $(release),,-nightly).png \( -clone 0 -fill #ff0000 -colorize 75 \) -compose multiply -composite nsis/dev.geopjr.Tuba-uninstall.png
magick -density "256x256" -background transparent nsis/dev.geopjr.Tuba-uninstall.png -define icon:auto-resize -colors 256 nsis/dev.geopjr.Tuba-uninstall.ico
rsvg-convert ./data/icons/color$(if $(release),,-nightly).svg -o nsis/dev.geopjr.Tuba-header.png -h 57 -w 57
magick nsis/dev.geopjr.Tuba-header.png -background white -alpha remove -alpha off -type truecolor -define bmp:format=bmp3 nsis/dev.geopjr.Tuba-header.bmp
cd nsis && makensis dev.geopjr.Tuba.nsi
18 changes: 14 additions & 4 deletions build-aux/dev.geopjr.Tuba.nsi.in
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,13 @@
; UI

!define MUI_ICON "${EXEC_NAME}.ico"
!define MUI_HEADERIMAGE
!define MUI_UNICON "${EXEC_NAME}-uninstall.ico"
!define MUI_ABORTWARNING
!define MUI_WELCOMEPAGE_TITLE "${SLUG} Setup"
;!define MUI_WELCOMEFINISHPAGE_BITMAP "${EXEC_NAME}-side.bmp"
!define MUI_HEADERIMAGE_BITMAP "${EXEC_NAME}-header.bmp"
!define MUI_HEADERIMAGE "${EXEC_NAME}.bmp"
!define MUI_HEADERIMAGE_BITMAP_NOSTRETCH

;----------
; Pages
Expand All @@ -41,6 +45,10 @@
!insertmacro MUI_PAGE_COMPONENTS
!insertmacro MUI_PAGE_DIRECTORY
!insertmacro MUI_PAGE_INSTFILES
!define MUI_FINISHPAGE_RUN "$INSTDIR\bin\${APPFILE}"
!define MUI_FINISHPAGE_RUN_NOTCHECKED
!define MUI_FINISHPAGE_LINK "Visit ${NAME}'s Website"
!define MUI_FINISHPAGE_LINK_LOCATION "https://tuba.geopjr.dev/"
!insertmacro MUI_PAGE_FINISH

; Uninstaller pages
Expand All @@ -63,15 +71,17 @@
File /a /r "tuba_windows_portable\lib\"
SetOutPath "$INSTDIR\share"
File /a /r "tuba_windows_portable\share\"
SetOutPath "$INSTDIR\"
File "${EXEC_NAME}.ico"
WriteRegStr HKCU "Software\${NAME}" "" $INSTDIR

WriteRegStr HKLM "${UNINSTALL_KEY}" "DisplayName" "${NAME}"
WriteRegStr HKLM "${UNINSTALL_KEY}" "UninstallString" "$INSTDIR\uninstall.exe"
WriteRegStr HKLM "${UNINSTALL_KEY}" "InstallLocation" "$INSTDIR"
WriteRegStr HKLM "${UNINSTALL_KEY}" "Publisher" "GeopJr"
WriteRegStr HKLM "${UNINSTALL_KEY}" "DisplayIcon" "${EXEC_NAME}.ico"
WriteRegStr HKLM "${UNINSTALL_KEY}" "URLInfoAbout" "@WEBSITE@"
WriteRegStr HKLM "${UNINSTALL_KEY}" "DisplayVersion" "${PRODUCT_VERSION}"
WriteRegStr HKLM "${UNINSTALL_KEY}" "DisplayIcon" "$INSTDIR\${EXEC_NAME}.ico"
WriteRegStr HKLM "${UNINSTALL_KEY}" "URLInfoAbout" "https://tuba.geopjr.dev/"
WriteRegStr HKLM "${UNINSTALL_KEY}" "DisplayVersion" "${VERSION}"
WriteRegDWORD HKLM "${UNINSTALL_KEY}" "NoModify" 1
WriteRegDWORD HKLM "${UNINSTALL_KEY}" "NoRepair" 1

Expand Down

0 comments on commit dc35eac

Please sign in to comment.