From c2305c52d1502594cc0dad87f9247cd62df15968 Mon Sep 17 00:00:00 2001 From: David Heinemeier Hansson Date: Wed, 12 Aug 2026 03:49:55 -0700 Subject: [PATCH] Drop the legacy build-host names OMARCHY_BUILD_HOST and .build-host were carried as fallbacks through the rename. Nothing in this checkout ever set either one, so they were a second name for a setting that has only one real name. Resolution is now --host, OMARCHY_REPO_HOST, .repo-host. Co-Authored-By: Claude Opus 5 (1M context) --- .gitignore | 1 - README.md | 8 +++----- helpers/host-helpers.sh | 30 ++++++++++-------------------- 3 files changed, 13 insertions(+), 26 deletions(-) diff --git a/.gitignore b/.gitignore index 2894346..fce5f3c 100644 --- a/.gitignore +++ b/.gitignore @@ -33,5 +33,4 @@ pkgbuilds/symfony-cli/symfony* !pkgbuilds/symfony-cli/symfony-cli.install pkgbuilds/yay/yay/ .srcdest/ -.build-host .repo-host diff --git a/README.md b/README.md index 013fba5..e3d0ded 100644 --- a/README.md +++ b/README.md @@ -212,9 +212,8 @@ need no secrets. The host comes from `--host`, `$OMARCHY_REPO_HOST`, then `.repo-host`. One machine both serves pkgs.omarchy.org and runs the scheduled builds, so the -setting is named for the repository rather than for building, which now happens -wherever you like. `OMARCHY_BUILD_HOST` and `.build-host` are the previous names -and still work. +setting is named for the repository rather than for building, which happens +wherever you like. Note that `.repo-host` also arms the automatic build trigger in `bin/omarchy-pkgs release`; pass `--host` or set `OMARCHY_REPO_HOST` to keep the @@ -322,8 +321,7 @@ stable — promotion is always this explicit step. After pushing, the command triggers the build host over ssh when `OMARCHY_REPO_HOST` is set (env var, or a hostname in the git-ignored -`.repo-host` file; `OMARCHY_BUILD_HOST` and `.build-host` still work). Without -it, the 6-hourly auto-release timer picks up the +`.repo-host` file). Without it, the 6-hourly auto-release timer picks up the change on its own. ## Directory Structure diff --git a/helpers/host-helpers.sh b/helpers/host-helpers.sh index cca94bb..96ce547 100644 --- a/helpers/host-helpers.sh +++ b/helpers/host-helpers.sh @@ -1,11 +1,9 @@ # Resolving the Omarchy repository host # -# One machine both hosts pkgs.omarchy.org and runs the scheduled builds. The +# One machine both serves pkgs.omarchy.org and runs the scheduled builds. The # commands that reach it are doing repository work — uploading artifacts, # signing, publishing — so the setting is named for the repository rather than -# for building, which now happens on whatever machine the operator prefers. -# -# OMARCHY_BUILD_HOST and .build-host are the previous names and still work. +# for building, which happens on whatever machine the operator prefers. # Usage: resolve_repo_host [explicit-host] # Prints the host, or nothing when none is configured. @@ -22,23 +20,15 @@ resolve_repo_host() { return 0 fi - if [[ -n "${OMARCHY_BUILD_HOST:-}" ]]; then - echo "$OMARCHY_BUILD_HOST" - return 0 - fi - - local file - for file in "$BUILD_ROOT/.repo-host" "$BUILD_ROOT/.build-host"; do - if [[ -f "$file" ]]; then - # Ignore blank lines and comments so the file can be annotated. - local value - value=$(grep -vE '^\s*(#|$)' "$file" | head -1 | tr -d '[:space:]') - if [[ -n "$value" ]]; then - echo "$value" - return 0 - fi + if [[ -f "$BUILD_ROOT/.repo-host" ]]; then + # Ignore blank lines and comments so the file can be annotated. + local value + value=$(grep -vE '^\s*(#|$)' "$BUILD_ROOT/.repo-host" | head -1 | tr -d '[:space:]') + if [[ -n "$value" ]]; then + echo "$value" + return 0 fi - done + fi return 1 }