Skip to content

Scope submodule URL rewrites to checkout command in Update Plugins workflow - #5

Draft
farfromrefug with Copilot wants to merge 2 commits into
masterfrom
copilot/fix-update-ui-mapbox-job
Draft

farfromrefug with Copilot wants to merge 2 commits into
masterfrom
copilot/fix-update-ui-mapbox-job

Conversation

Copilot AI commented Sep 16, 2026

Copy link
Copy Markdown
Contributor

The Update Plugins matrix job for ui-mapbox was failing after committing changes because git push lost usable GitHub auth context (could not read Username for 'https://github.com'). The failure stemmed from persistent URL rewrite config applied during submodule setup.

  • Root cause

    • Submodule fetch step wrote SSH→HTTPS rewrites into local git config (git config --local --add ... insteadOf ...).
    • Those persistent rewrites leaked beyond submodule update and affected later push behavior.
  • Change made

    • Replaced persistent local config writes with command-scoped git config on submodule update.
    • Kept both SSH URL forms mapped (git@github.com: and ssh://git@github.com/) while limiting scope to submodule fetch only.
  • Why this resolves the job

    • Submodules still resolve over HTTPS when needed.
    • Repository-level push configuration is no longer mutated before git push.
if [ -f .gitmodules ]; then
  git submodule sync --recursive
  git \
    -c url."https://github.com/".insteadOf=git@github.com: \
    -c url."https://github.com/".insteadOf=ssh://git@github.com/ \
    -c protocol.version=2 \
    submodule update --init --force --depth=1 --recursive
fi

Co-authored-by: farfromrefug <655344+farfromrefug@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix failing GitHub Actions job update (ui-mapbox) Scope submodule URL rewrites to checkout command in Update Plugins workflow Sep 16, 2026
Copilot AI requested a review from farfromrefug September 16, 2026 14:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants