Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 20 additions & 6 deletions .github/workflows/companion-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -67,32 +67,46 @@ jobs:
# notarized macOS artifacts come from macos-release.yml, which supplies
# the real certificate secrets, and desktop-macos.yml, which verifies
# the result with `codesign --verify --deep --strict`.
# --verbose is deliberate. tauri-bundler runs candle.exe/light.exe via
# output_ok(), which pipes their stdout+stderr and re-emits each line at
# log::debug! level, then discards it on failure in favour of a bare
# "failed to run <exe>". Without --verbose a WiX linker failure surfaces
# with no LGHT diagnostic at all, which is unactionable from CI logs.
- name: Build Tauri app
working-directory: nclaw/desktop/src-tauri
run: cargo tauri build
run: cargo tauri build --verbose

# Bundles land in the CARGO WORKSPACE target dir. desktop/src-tauri is a
# member of the root Cargo.toml workspace, so cargo writes to
# <repo>/target/, NOT <repo>/desktop/src-tauri/target/. The old paths
# matched nothing: upload-artifact only warns ("No files were found")
# and still exits 0, so the linux and macos legs reported success while
# uploading zero artifacts.
- name: Upload Linux artifacts
if: matrix.platform == 'ubuntu-latest'
uses: actions/upload-artifact@v7
with:
name: companion-${{ matrix.target }}
if-no-files-found: error
path: |
nclaw/desktop/src-tauri/target/release/bundle/appimage/*.AppImage
nclaw/desktop/src-tauri/target/release/bundle/deb/*.deb
nclaw/target/release/bundle/appimage/*.AppImage
nclaw/target/release/bundle/deb/*.deb

- name: Upload Windows artifacts
if: matrix.platform == 'windows-latest'
uses: actions/upload-artifact@v7
with:
name: companion-${{ matrix.target }}
if-no-files-found: error
path: |
nclaw/desktop/src-tauri/target/release/bundle/msi/*.msi
nclaw/desktop/src-tauri/target/release/bundle/nsis/*.exe
nclaw/target/release/bundle/msi/*.msi
nclaw/target/release/bundle/nsis/*.exe

- name: Upload macOS artifacts
if: matrix.platform == 'macos-latest'
uses: actions/upload-artifact@v7
with:
name: companion-${{ matrix.target }}
if-no-files-found: error
path: |
nclaw/desktop/src-tauri/target/release/bundle/dmg/*.dmg
nclaw/target/release/bundle/dmg/*.dmg
9 changes: 9 additions & 0 deletions desktop/src-tauri/tauri.conf.json
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,15 @@
"macOS": {
"minimumSystemVersion": "10.15",
"entitlements": "entitlements.plist"
},
"windows": {
"wix": {
"language": {
"en-US": {
"localePath": "wix/en-US.wxl"
}
}
}
}
}
}
37 changes: 37 additions & 0 deletions desktop/src-tauri/wix/en-US.wxl
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Forces the MSI *database* code page to UTF-8 (65001).

The product name is "ɳClaw", whose first character is U+0273 LATIN SMALL
LETTER N WITH RETROFLEX HOOK, the eta the brand uses for display names.
WiX defaults an MSI's database code page to the culture's ANSI code page,
and tauri's languages.json maps en-US to 1252. U+0273 has no representation
in 1252, so light.exe rejected every string carrying the product name:

main.wxs(23) : error LGHT0311 : A string was provided with characters
that are not available in the specified database code page '1252'.

LGHT0311 names WixLocalization/@Codepage as one of the supported places to
change that code page, which is the entire purpose of this file.

The summary information stream is deliberately NOT switched to 65001. It
has its own, stricter rule:

main.wxs(23) : error LGHT0349 : The code page '65001' is invalid for
summary information. You must specify an ANSI code page.

So the TauriCodepage localization string is left alone and tauri appends
its 1252 default, which Package/@SummaryCodepage consumes. That is safe
because tauri's Package element carries no product name: its only text
attribute is Keywords="Installer". Nothing non-ASCII reaches the summary
stream, so the database and the summary stream legitimately differ.

tauri-bundler reads this file verbatim and then appends any default String
element whose Id it cannot already find, so only the one value that must
differ from the defaults is set here.
-->
<WixLocalization
Culture="en-us"
Codepage="65001"
xmlns="http://schemas.microsoft.com/wix/2006/localization">
</WixLocalization>
Loading