From 2521f93c2e642f4c4cacf073eeb4b1198467cf82 Mon Sep 17 00:00:00 2001 From: Neo <321592+Neo-Desktop@users.noreply.github.com> Date: Tue, 24 Nov 2026 06:10:51 -0800 Subject: [PATCH] CI: D-Modem is public; remove DMODEM_TOKEN (#70) The checkouts use the built-in token. The docs and workflow comments no longer call the submodule private. Claude-Session: https://claude.ai/code/session_01B82eRT9xSDzhZPJHVyrj6o Co-authored-by: Claude --- .github/workflows/android.yml | 9 +-------- .github/workflows/apple.yml | 4 +--- .github/workflows/d-modem-bump.yml | 7 +++---- .github/workflows/nightly.yml | 2 +- docs/building.md | 3 +-- 5 files changed, 7 insertions(+), 18 deletions(-) diff --git a/.github/workflows/android.yml b/.github/workflows/android.yml index 84c1aa5..6ed78a1 100644 --- a/.github/workflows/android.yml +++ b/.github/workflows/android.yml @@ -14,9 +14,7 @@ # Packages: apt's downloads are cached (.github/actions/apt), keyed on # the runner image and the package list. # -# D-Modem is a private submodule: the DMODEM_TOKEN secret is a token -# that can read it (a fine-grained personal access token with Contents: -# read on D-Modem/D-Modem). +# D-Modem is a public submodule: the checkout needs no token. # # Signing: ANDROID_KEYSTORE_BASE64 (a PKCS12 keystore, base64), # ANDROID_KEYSTORE_PASSWORD, ANDROID_KEY_ALIAS and ANDROID_KEY_PASSWORD @@ -57,7 +55,6 @@ jobs: - uses: actions/checkout@v6 with: submodules: recursive - token: ${{ secrets.DMODEM_TOKEN || github.token }} - name: Every function documented run: python3 tools/doc_check.py @@ -73,7 +70,6 @@ jobs: - uses: actions/checkout@v6 with: submodules: recursive - token: ${{ secrets.DMODEM_TOKEN || github.token }} - uses: actions/setup-java@v5 with: @@ -148,7 +144,6 @@ jobs: - uses: actions/checkout@v6 with: submodules: recursive - token: ${{ secrets.DMODEM_TOKEN || github.token }} - uses: actions/setup-java@v5 with: @@ -209,7 +204,6 @@ jobs: - uses: actions/checkout@v6 with: submodules: recursive - token: ${{ secrets.DMODEM_TOKEN || github.token }} - name: Packages uses: ./.github/actions/apt @@ -280,7 +274,6 @@ jobs: - uses: actions/checkout@v6 with: submodules: recursive - token: ${{ secrets.DMODEM_TOKEN || github.token }} - uses: actions/setup-java@v5 with: diff --git a/.github/workflows/apple.yml b/.github/workflows/apple.yml index a69c3c3..faa8451 100644 --- a/.github/workflows/apple.yml +++ b/.github/workflows/apple.yml @@ -5,8 +5,7 @@ # DModemKit's tests, and the iOS app (ios/DModem) built for the simulator; # on main, also for a device, not signed (DModem-unsigned.ipa). # -# D-Modem is a private submodule: the DMODEM_TOKEN secret (as -# android.yml's). +# D-Modem is a public submodule: the checkout needs no token. name: Apple # (a branch's commits run once, as its pull request: pushed, only main's; @@ -33,7 +32,6 @@ jobs: - uses: actions/checkout@v6 with: submodules: recursive - token: ${{ secrets.DMODEM_TOKEN || github.token }} # (Homebrew's downloads cached: .github/actions/brew) - name: Ninja, XcodeGen diff --git a/.github/workflows/d-modem-bump.yml b/.github/workflows/d-modem-bump.yml index 6486d8a..bb02989 100644 --- a/.github/workflows/d-modem-bump.yml +++ b/.github/workflows/d-modem-bump.yml @@ -5,10 +5,9 @@ # Run workflow), or from D-Modem (a repository_dispatch of type # "d-modem-main", for when its main changes). # -# It needs the DMODEM_BUMP_TOKEN secret: a fine-grained personal access -# token with Contents: read on D-Modem/D-Modem (the private submodule) -# and Contents: read and write and Pull requests: read and write on -# D-Modem/app. Not the workflow's own GITHUB_TOKEN: a pull request that +# It needs the DMODEM_BUMP_TOKEN secret (an organization secret): a +# fine-grained personal access token with Contents: read and write and +# Pull requests: read and write on D-Modem/app. Not the workflow's own GITHUB_TOKEN: a pull request that # token opens starts no other workflow, so Android's checks would never # run on it. Without the secret the run says so and stops. # diff --git a/.github/workflows/nightly.yml b/.github/workflows/nightly.yml index b480d99..28a9e4c 100644 --- a/.github/workflows/nightly.yml +++ b/.github/workflows/nightly.yml @@ -43,7 +43,7 @@ jobs: GH_TOKEN: ${{ github.token }} GH_REPO: ${{ github.repository }} steps: - # (the scripts only: not the private submodule) + # (the scripts only: not the submodules) - uses: actions/checkout@v6 - name: The newest build of main diff --git a/docs/building.md b/docs/building.md index 2b6b793..329f6fb 100644 --- a/docs/building.md +++ b/docs/building.md @@ -64,8 +64,7 @@ annotations (Kotlin, Swift, shell), or a docstring (Python). C and C++ follow the rule of D-Modem. `tools/doc_check.py` lists each function without a comment (and fails). -CI (`.github/workflows/android.yml`) runs all three, and that check. It needs -a `DMODEM_TOKEN` secret that can read the private D-Modem submodule. +CI (`.github/workflows/android.yml`) runs all three, and that check. `.github/workflows/d-modem-bump.yml` keeps the submodule on the main of D-Modem. It starts when the main branch of D-Modem changes, each day, or