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
1 change: 0 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ override ROOT := $(realpath $(dir $(lastword $(MAKEFILE_LIST))))
override DIST := $(ROOT)/dist
override GUEST_DIST := $(DIST)/guest
override APP := $(DIST)/app.noindex/Try Omarchy.app
override DMG := $(DIST)/TryOmarchy.dmg
override BUILD_CACHE := $(ROOT)/scripts/build-cache.py
override BUILD_STATE := $(ROOT)/.build/state
RELEASE_SIGN_IDENTITY ?= Developer ID Application: Eduardo Martinez (RZC79MPD34)
Expand Down
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -902,11 +902,11 @@ All generated output has one predictable home:
```text
dist/
├── app.noindex/
│ └── Try Omarchy.app # development identity
│ └── Try Omarchy.app # development identity
├── release.noindex/
│ └── Try Omarchy.app # production identity
├── TryOmarchy.dmg # after make package or make release
└── guest/ # verified guest build artifacts
│ └── Try Omarchy.app # production identity
├── TryOmarchy-vX.Y.Z.dmg # after make package or make release
└── guest/ # verified guest build artifacts
```

Both DMG targets create distributable artifacts:
Expand Down
3 changes: 2 additions & 1 deletion docs/app-updates.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,8 @@ Updates window also counts as its notification.

The checker uses GitHub's public `/repos/omacom/try-omarchy/releases/latest`
endpoint without credentials. It accepts published, non-prerelease `vX.Y.Z`
tags with an uploaded `TryOmarchy.dmg`. Versions compare numerically. The
tags with an uploaded `TryOmarchy-vX.Y.Z.dmg` whose version matches the tag,
or the legacy `TryOmarchy.dmg`. Versions compare numerically. The
download action opens the project's release page so the user can read notes
and OS requirements. GitHub release metadata does not declare a structured
minimum macOS version; this stage does not claim compatibility or select an
Expand Down
9 changes: 7 additions & 2 deletions docs/releasing.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,12 @@ not make the checkout dirty.

After verifying the DMG, push the tag with `git push origin vX.Y.Z`, then create
the GitHub release manually using that existing tag and attach
`dist/TryOmarchy.dmg`. Packaging does not create tags or publish GitHub releases.
`dist/TryOmarchy-vX.Y.Z.dmg`. The filename uses the version stamped into the
app from the release tag (for example, `v0.4.0` produces
`TryOmarchy-v0.4.0.dmg`). Packaging does not create tags or publish GitHub releases.

Older app release checkers recognize only `TryOmarchy.dmg`. To keep a release
discoverable by those clients, also upload a copy under that legacy asset name.

When the release updates Omarchy itself, first run:

Expand All @@ -35,7 +40,7 @@ before continuing with the normal build and verification sequence.
Outputs are written to:

- `dist/release.noindex/Try Omarchy.app` (production)
- `dist/TryOmarchy.dmg`
- `dist/TryOmarchy-vX.Y.Z.dmg`
- `dist/guest/`

`make package` and `make release` both create distributable builds: they sign
Expand Down
4 changes: 2 additions & 2 deletions macos/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ Use the root Makefile for normal development:
make runtime # macos/.build/qemu-gpu-runtime
make app # dist/app.noindex/Try Omarchy.app
make run
make package # signed and notarized dist/TryOmarchy.dmg
make release # signed and notarized dist/TryOmarchy.dmg
make package # signed and notarized dist/TryOmarchy-vX.Y.Z.dmg
make release # signed and notarized dist/TryOmarchy-vX.Y.Z.dmg
make test
```

Expand Down
5 changes: 4 additions & 1 deletion macos/Sources/OmarchyVMHelper/AppRelease.swift
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,10 @@ struct AppRelease: Equatable {
let payload = try JSONDecoder().decode(Payload.self, from: data)
guard !payload.draft, !payload.prerelease, payload.tagName.hasPrefix("v"),
let version = AppReleaseVersion(String(payload.tagName.dropFirst())),
payload.assets.contains(where: { $0.name == "TryOmarchy.dmg" && $0.state == "uploaded" }) else {
payload.assets.contains(where: {
($0.name == "TryOmarchy-v\(version).dmg" || $0.name == "TryOmarchy.dmg")
&& $0.state == "uploaded"
}) else {
throw AppReleaseError.invalidRelease
}
// Construct the project URL instead of opening an arbitrary URL from JSON.
Expand Down
11 changes: 11 additions & 0 deletions macos/Tests/OmarchyVMHelperTests/AppReleaseTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -64,12 +64,23 @@ struct AppReleaseTests {
try payload(draft: true), try payload(prerelease: true),
try payload(tag: "v0.5.0-beta"), try payload(tag: "0.5.0"),
try payload(assetName: "source.zip"), try payload(assetState: "starter"),
try payload(assetName: "TryOmarchy-v0.4.0.dmg"),
try payload(assetName: "TryOmarchy-v0.5.0.dmg", assetState: "starter"),
] {
#expect(throws: AppReleaseError.self) { try AppRelease.decode(data) }
}
#expect(throws: DecodingError.self) { try AppRelease.decode(Data("{}".utf8)) }
}

@Test("release downloads accept matching versioned names and legacy names", arguments: [
"TryOmarchy-v0.5.0.dmg", "TryOmarchy.dmg",
])
func releaseDownloadNames(assetName: String) throws {
let latest = try AppRelease.decode(payload(assetName: assetName))
#expect(latest.version == AppReleaseVersion("0.5.0"))
#expect(latest.url.absoluteString == "https://github.com/omacom/try-omarchy/releases/tag/v0.5.0")
}

@Test("current and newer installed builds are not offered a downgrade")
func updateDecision() throws {
let latest = try release()
Expand Down
3 changes: 2 additions & 1 deletion macos/build-app.sh
Original file line number Diff line number Diff line change
Expand Up @@ -349,7 +349,8 @@ codesign --verify --deep --strict --verbose=2 "$app"

echo "[native] Built $app"
if (( build_dmg )); then
dmg="$repo_dir/dist/TryOmarchy.dmg"
app_version=$(/usr/bin/plutil -extract CFBundleShortVersionString raw "$contents/Info.plist")
dmg="$repo_dir/dist/TryOmarchy-v${app_version}.dmg"
rm -f "$dmg"
package_options=()
if [[ $sign_identity != - ]]; then
Expand Down
Loading