Skip to content

Commit 07a9de9

Browse files
wenxi-zengclaude
andcommitted
ci: use git credential store instead of .netrc
SPM/git on Linux wasn't reading ~/.netrc for auth. Use git credential store with the token embedded in ~/.git-credentials instead. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent 000939f commit 07a9de9

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

.github/workflows/resolve-dependencies.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,10 @@ jobs:
4141
set -euo pipefail
4242
MIRROR_BASE="${ARTIFACTORY_URL}/artifactory/api/swift/${SWIFT_VIRTUAL_REPO}"
4343
44-
echo "machine twilio.jfrog.io login token password ${ART_TOKEN}" > ~/.netrc
45-
chmod 600 ~/.netrc
44+
# Configure git to use the token for Artifactory URLs
45+
git config --global credential.helper store
46+
echo "https://token:${ART_TOKEN}@twilio.jfrog.io" >> ~/.git-credentials
47+
chmod 600 ~/.git-credentials
4648
4749
swift package config set-mirror \
4850
--original-url https://github.com/segmentio/sovran-swift.git \

0 commit comments

Comments
 (0)