From 16fe1b0db3588faec2d67803bfbed8de87536d90 Mon Sep 17 00:00:00 2001 From: aminovfariz Date: Mon, 8 Jun 2026 09:29:00 +0200 Subject: [PATCH] fix(ci): skip codex skills sync on hosts without Codex installation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit QG-009 was failing on GitHub Actions runner because ~/.codex does not exist on ubuntu-latest and CODEX_HOME is not set. The check is a local-developer tool only — CI runners do not have Codex installed. Co-Authored-By: Claude Sonnet 4.6 --- bin/codex-skills-sync.sh | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/bin/codex-skills-sync.sh b/bin/codex-skills-sync.sh index 1eb73b8..88fcb1a 100755 --- a/bin/codex-skills-sync.sh +++ b/bin/codex-skills-sync.sh @@ -42,6 +42,13 @@ if ! command -v rsync >/dev/null 2>&1; then exit 3 fi +# Skip on CI environments where ~/.codex is not present and CODEX_HOME is not set. +# Codex skills sync is a local developer tool; CI runners do not have a Codex installation. +if [[ -z "${CODEX_HOME:-}" ]] && [[ ! -d "${HOME}/.codex" ]]; then + echo "[SKIP] Codex home not found and CODEX_HOME not set — skipping on this host." + exit 0 +fi + script_dir="$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")" && pwd)" repo_root="$(cd -- "${script_dir}/.." && pwd)" source_dir="${repo_root}/.agents/skills"