Skip to content

Commit

Permalink
Change username and fix setting on Windows
Browse files Browse the repository at this point in the history
  • Loading branch information
AntoineGautier committed Sep 15, 2023
1 parent 73285dd commit c4aff4e
Showing 1 changed file with 10 additions and 6 deletions.
16 changes: 10 additions & 6 deletions .github/workflows/cmake.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ on:

env:
BUILD_TYPE: Release
GH_USERNAME: ${{ github.actor }}
GH_USERNAME: github-actions[bot]

jobs:
build:
Expand Down Expand Up @@ -78,8 +78,6 @@ jobs:
github.event_name == 'push' &&
github.ref == 'refs/heads/master'
run: |
git config --global user.name $GH_USERNAME
git config --global user.email [email protected]
git config --global pull.rebase true
git add ${{ github.workspace }}/pyfunnel/lib
Expand All @@ -89,13 +87,19 @@ jobs:
contains(matrix.python-version, '3.9') &&
github.event_name == 'push' &&
github.ref == 'refs/heads/master'
run: git diff-index --quiet HEAD || { git commit -m "Add ${{ matrix.os }} binaries" && git pull && git push; }
run: |
git config --global user.name "${GH_USERNAME}"
git config --global user.email "${GH_USERNAME}@users.noreply.github.com"
git diff-index --quiet HEAD || { git commit -m "Add ${{ matrix.os }} binaries" && git pull && git push; }
# We use cmd /c because powershell <7 does not support chain operators.
- name: Push Windows binaries
if: |
matrix.os == 'windows-latest' &&
contains(matrix.python-version, '3.9') &&
github.event_name == 'push' &&
github.ref == 'refs/heads/master'
# We use cmd /c because powershell <7 does not support chain operators.
run: cmd /c 'git diff-index --quiet HEAD || ( git commit -m "Add ${{ matrix.os }} binaries" && git pull && git push )'
run: |
git config --global user.name "${{ env.GH_USERNAME }}"
git config --global user.email "${{ env.GH_USERNAME }}@users.noreply.github.com"
cmd /c 'git diff-index --quiet HEAD || ( git commit -m "Add ${{ matrix.os }} binaries" && git pull && git push )'

0 comments on commit c4aff4e

Please sign in to comment.