From ce2adfec104199dfbc17f6c4b2bd3aa53d2d02a0 Mon Sep 17 00:00:00 2001 From: Michael Ernst Date: Wed, 20 May 2026 11:03:37 -0700 Subject: [PATCH 1/3] Add diagnostics --- .github/workflows/test.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 2a4917b..554cce5 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -15,6 +15,11 @@ jobs: uses: actions/setup-python@v6 with: python-version: '3.14.5' + - name: ci-info + run: | + mkdir -p /tmp + git -C /tmp clone --depth=1 -q https://github.com/plume-lib/plume-scripts.git + /tmp/plume-scripts/ci-info --debug - name: Run tests run: | git config --global user.email "example@example.com" From 02ac4f891368df412aa5243d643e146923a6e24d Mon Sep 17 00:00:00 2001 From: Michael Ernst Date: Wed, 20 May 2026 11:12:19 -0700 Subject: [PATCH 2/3] Enable debugging --- git-clone-related | 3 +++ 1 file changed, 3 insertions(+) diff --git a/git-clone-related b/git-clone-related index 564e318..253eda6 100755 --- a/git-clone-related +++ b/git-clone-related @@ -47,6 +47,9 @@ if [ "$1" = "--debug" ]; then set -x fi +# TEMPORARY +DEBUG=1 + # FALLBACK_BRANCH may be unset. if [ "$1" = "--upstream-branch" ]; then shift From 1c063c246a898cefd1514e47bd5a3c5ca93a5cf1 Mon Sep 17 00:00:00 2001 From: Michael Ernst Date: Mon, 25 May 2026 11:55:12 -0700 Subject: [PATCH 3/3] Use `git-changes` instead of `ci-info` --- .github/workflows/test.yml | 4 +-- git-clone-related | 28 +++++++++---------- .../test-git-clone-related.sh | 2 +- 3 files changed, 17 insertions(+), 17 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 554cce5..743c432 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -15,11 +15,11 @@ jobs: uses: actions/setup-python@v6 with: python-version: '3.14.5' - - name: ci-info + - name: git-changes run: | mkdir -p /tmp git -C /tmp clone --depth=1 -q https://github.com/plume-lib/plume-scripts.git - /tmp/plume-scripts/ci-info --debug + /tmp/plume-scripts/git-changes --debug - name: Run tests run: | git config --global user.email "example@example.com" diff --git a/git-clone-related b/git-clone-related index 253eda6..f059b22 100755 --- a/git-clone-related +++ b/git-clone-related @@ -125,46 +125,46 @@ else # TODO: Put this behind the debugging flag. echo "plume-scripts HEAD = $(git -C "${PLUME_SCRIPTS}" rev-parse HEAD)" - CI_INFO="${PLUME_SCRIPTS}/ci-info" + CI_INFO="${PLUME_SCRIPTS}/ci-org-and-branch" echo "CI_INFO=${CI_INFO}" if [ ! -f "$CI_INFO" ]; then - echo "ci-info script does not exist: ${CI_INFO}" + echo "ci-org-and-branch script does not exist: ${CI_INFO}" echo "PLUME_SCRIPTS=${PLUME_SCRIPTS}" ls -a "${PLUME_SCRIPTS}" - echo "ci-info script does not exist: ${CI_INFO}" + echo "ci-org-and-branch script does not exist: ${CI_INFO}" exit 1 fi if [ -n "$DEBUG" ]; then - echo "${SCRIPT_NAME}: About to run: ci-info --debug" + echo "${SCRIPT_NAME}: About to run: ci-org-and-branch --debug" "${CI_INFO}" --debug "${UPSTREAM_ORG}" - echo "${SCRIPT_NAME}: Done: ci-info --debug" + echo "${SCRIPT_NAME}: Done: ci-org-and-branch --debug" fi if [ -n "$DEBUG" ]; then - echo "${SCRIPT_NAME}: About to run: ci-info" + echo "${SCRIPT_NAME}: About to run: ci-org-and-branch" fi ci_info_output="$("${CI_INFO}" "${UPSTREAM_ORG}")" if [ -n "$DEBUG" ]; then - echo "${SCRIPT_NAME}: Done: ci-info" - echo "---- start of ci-info output ----" + echo "${SCRIPT_NAME}: Done: ci-org-and-branch" + echo "---- start of ci-org-and-branch output ----" # If `set -v` is on, the output will appear doubled, with the first copy preceded by "+ echo ". echo "${ci_info_output}" - echo "---- end of ci-info output ----" - echo "${SCRIPT_NAME}: About to eval ci-info output in ${PWD}" + echo "---- end of ci-org-and-branch output ----" + echo "${SCRIPT_NAME}: About to eval ci-org-and-branch output in ${PWD}" fi if ! eval "${ci_info_output}"; then - echo "${SCRIPT_NAME}: Unable to eval ci-info output, which was:" + echo "${SCRIPT_NAME}: Unable to eval ci-org-and-branch output, which was:" echo "${ci_info_output}" - echo "${SCRIPT_NAME}: About to run: ci-info --debug" + echo "${SCRIPT_NAME}: About to run: ci-org-and-branch --debug" "${CI_INFO}" --debug "${UPSTREAM_ORG}" - echo "${SCRIPT_NAME}: Done: ci-info --debug" + echo "${SCRIPT_NAME}: Done: ci-org-and-branch --debug" false fi if [ -n "$DEBUG" ]; then - echo "${SCRIPT_NAME}: Done: eval ci-info output in ${PWD}" + echo "${SCRIPT_NAME}: Done: eval ci-org-and-branch output in ${PWD}" fi UPSTREAM_REPO_URL="https://github.com/${UPSTREAM_ORG}/${REPO_NAME}.git" diff --git a/tests/git-clone-related-test/test-git-clone-related.sh b/tests/git-clone-related-test/test-git-clone-related.sh index 2772122..ba89bc7 100755 --- a/tests/git-clone-related-test/test-git-clone-related.sh +++ b/tests/git-clone-related-test/test-git-clone-related.sh @@ -34,7 +34,7 @@ rm -rf "$startdir" "$resultdir" git clone --branch "$START_BRANCH" "$START_REPO" "$startdir" -q --single-branch --depth 1 # This test might itself be running under CI, so unset the variables that -# `ci-info` examines. +# `git-changes` examines. unset SYSTEM_PULLREQUEST_TARGETBRANCH unset BUILD_SOURCEBRANCH unset TRAVIS