Skip to content

Commit

Permalink
ci: create a global git config to fix gclient sync on windows
Browse files Browse the repository at this point in the history
"gclient sync" fails on windows because of a missing
"C:\Users\runneradmin\.gitconfig" config file.

Run "git config --global user.name ..." and
"git config --global user.email ..." to create one.
  • Loading branch information
ardera committed Dec 10, 2024
1 parent d7956ad commit 1b4874e
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,11 @@ jobs:
- windows-latest
steps:
- uses: actions/checkout@v4


- run: |
git config --global user.name "github-actions[bot]"
git config --global user.email "41898282+github-actions[bot]@users.noreply.github.com"
- uses: actions/cache/restore@v4
id: cache-lookup
with:
Expand Down Expand Up @@ -315,19 +319,21 @@ jobs:
if: runner.os != 'Windows'
run: |
echo "${{ github.workspace }}/depot_tools" >> $GITHUB_PATH
- name: add depot_tools to path (windows)
if: runner.os == 'Windows'
shell: pwsh
run: |
echo "${{ github.workspace }}\depot_tools" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
git config --global user.name "github-actions[bot]"
git config --global user.email "41898282+github-actions[bot]@users.noreply.github.com"
- name: Run gclient --version
env:
DEPOT_TOOLS_UPDATE: 1
run: |
gclient --version
- name: Download cached engine sources
uses: actions/cache/restore@v4
id: cache
Expand Down

0 comments on commit 1b4874e

Please sign in to comment.