From e96e747b2eefa3f32ad26e2d2113f5071d6cbaf6 Mon Sep 17 00:00:00 2001 From: Claude Date: Thu, 8 Oct 2026 12:58:42 +0000 Subject: [PATCH] Add git-annex check of pull requests Uses con/ci-actions' annex-check: fails if a pull request commits to git files that .gitattributes says belong in git-annex (listing them, with a hint on how to rewrite the commits), or annexes content that is not available from datasets.datalad.org, the CON hub, or a remote named in the pull request description. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_013rxPnK1Aqoin1VRrNA5vTa --- .github/workflows/annex-check.yml | 32 +++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 .github/workflows/annex-check.yml diff --git a/.github/workflows/annex-check.yml b/.github/workflows/annex-check.yml new file mode 100644 index 00000000..a1a89e7a --- /dev/null +++ b/.github/workflows/annex-check.yml @@ -0,0 +1,32 @@ +name: git-annex + +# Checks that pull requests annex what .gitattributes says belongs in +# git-annex, and that the annexed content can be obtained from one of the +# remotes below (or a remote named in the pull request description with a +# line "Extra git-annex remote: URL"). See +# https://github.com/con/ci-actions/tree/claude/bold-bohr-lvtger/annex-check + +on: + pull_request: + # edited: to follow changes to "Extra git-annex remote:" lines + types: [opened, synchronize, reopened, edited] + +permissions: + contents: read + +jobs: + annex-check: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v7 + with: + # all commits of the pull request, and the git-annex branch + fetch-depth: 0 + + - uses: con/ci-actions/annex-check@claude/bold-bohr-lvtger + with: + annex-remotes: | + https://datasets.datalad.org/centerforopenneuroscience/talks/.git + https://hub.centerforopenneuroscience.org/con/talks + # as `datalad save` does + dotfiles: true