Use a Windows machine with at least 8GB RAM and 100GB disk.
In AWS, a c5a.xlarge instance running Windows Server 2022 will do.
- Install 7-Zip.
- Install Visual Studio Community 2022.
- Include ".NET desktop development" workload.
- Include "Desktop development with C++" workload.
- Include individual component: Windows Universal CRT SDK
- Include individual component: Windows Universal C Runtime
- Include individual component: MSVC v143 - VS 2022 C++ ARM64/ARM64EC build tools (Latest)
- Install tidy-html5 to your
PATH. - Install SeaMonkey. Open it, Edit > Preferences > Appearance. Set "When SeaMonkey starts up, open..." to Composer.
- Install WiX Toolset 3.14.
- Install Chocolatey.
- Install NuGet and put it in your
PATH.
- In PowerShell on Windows, run
ps1/Update-Deps.ps1to download non-NuGet deps and generate the doc files. - Open
src\SqlNotebook.slnin Visual Studio and build.
- Use SeaMonkey Composer to edit the files in
doc/. - In WSL, run
ps1/Update-DocFormatting.ps1to reformat the HTML. - In Windows, run
ps1/Update-Docs.ps1to rebuild the website and integrated help.
- https://pikchr.org/home/pikchrshow
- Save the Pikchr source to a .pikchr file in
doc/art. - Click the copy SVG button on the website, paste into a .svg file.
- Get dimensions from the first line of the SVG file.
- Use SeaMonkey Composer to delete the image in the corresponding HTML page, then re-add it.
- Set the image dimensions.
- Set its
class="railroad"attribute.
- Run
ps1/Update-Docs.ps1to rebuild the website and integrated help.
- Get the version number from the SQLite download page, it's a long string of digits with no dots.
- Run
ps1/Get-SqliteDepLines.ps1, it will give you some PowerShell lines. - Update
ps1/Update-Deps.ps1with those lines. - Close Visual Studio.
- Run
scripts/clean.sh - Run
scripts/init.sh - Run
scripts/build.shand fix errors. - Read the release notes. The grammar may have changed, which needs to be reflected in
SqliteGrammar.cs.
- Check for new updates to NuGet packages.
- Write release notes in
project/finished. - Bump
AssemblyFileVersionandAssemblyCopyrightinsrc\SqlNotebook\Properties\AssemblyInfo.cs. - Bump
ProductVersioninsrc\SqlNotebook.wxs. - Add a news entry in
web\index.html. - Close Visual Studio.
- Commit changes using commit message "Version X.X.X", and push.
- Wait for GitHub Actions to complete Phase 1 build.
- Download the Phase 1 artifacts from GitHub Actions:
SqlNotebook-x64-release-filesandSqlNotebook-arm64-release-files. - Extract each artifact to get the build outputs in
src/SqlNotebook/bin/publish/.
-
Prerequisites for local signing:
- Install Windows SDK to get signtool. The only necessary features are "Windows SDK Signing Tools for Desktop Apps" and "MSI Tools". Download from: https://developer.microsoft.com/en-us/windows/downloads/windows-sdk/
- Search for signtool in
C:\Program Files (x86). Note the full path tosigntool.exe. - Find the HSM entry in 1Password. Note the SHA1 hash. Keep the entry open so you can copy the password out.
- Download the Phase 1 artifacts from GitHub Actions:
SqlNotebook-x64-release-filesandSqlNotebook-arm64-release-files. - Download and extract the repository zip.
-
For each platform (x64, arm64):
- Create empty folder:
src/SqlNotebook/bin/publish/. Extract the corresponding Phase 1 artifact there. - Run Phase 2 with automated code signing:
You will be prompted to enter your HSM password when signtool runs for both the executable and MSI.
$signtool = '<full path to signtool.exe>' $sha1 = '<code signing certificate SHA1 hash>' ps1/Finish-Release.ps1 -Platform <platform> -SigntoolPath "$signtool" -SigntoolSha1 "$sha1" -Version "<version>"
- The script will automatically:
- Sign
SqlNotebook.exe - Generate the portable ZIP
- Generate the MSI installer
- Sign the MSI installer
- Create properly named output files in
release-output/:SqlNotebook-<platform>-<version>.zipSqlNotebook-<platform>-<version>.msi
- Sign
- Create empty folder:
-
Test the zip and MSI files from the
release-output/directory. -
Create release on GitHub, upload the four files from
release-output/:SqlNotebook-64bit-<version>.zipSqlNotebook-64bit-<version>.msiSqlNotebook-arm64-<version>.zipSqlNotebook-arm64-<version>.msi
-
Release settings:
- Let GitHub create a new tag, name it
vX.X.X. - Set release title to
vX.X.X. - Copy the release verbiage from the previous release, and edit in the new release notes.
- Edit the previous release and remove the first two lines, the download links. We don't want to confuse users who visit the releases page.
- Let GitHub create a new tag, name it
-
Update
web\appversion.txtwith new version and MSI URL. -
Git clone
website-sqlnotebook.comin the same directory assqlnotebook. Insidesqlnotebook, runps1\Update-GitHubPages.ps1and force push thewebsite-sqlnotebook.comrepo. -
Update
src\chocolatey\sqlnotebook.nuspecwith copyright and version. -
Update
src\chocolatey\tools\chocolateyInstall.ps1with MSI URL and SHA-256 checksums (download and useGet-FileHash). -
Get your Chocolatey API key.
-
In Admin PowerShell from
src\chocolatey:choco pack choco install sqlnotebook -s . (test that it worked) $api = '<chocolatey api key>' choco apikey -k "$api" -source https://chocolatey.org/ choco push .\sqlnotebook.X.X.X.nupkg -s https://chocolatey.org/ -
Commit changes using commit message "Update website and Chocolatey to version X.X.X", and push.