-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #70 from lbl-srg/issue69_fixGHActions
Fix GH action
- Loading branch information
Showing
1 changed file
with
13 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,12 @@ | ||
name: CMake | ||
|
||
on: [push] | ||
on: | ||
pull_request: | ||
branches: | ||
- 'master' | ||
push: | ||
branches: | ||
- 'master' | ||
|
||
env: | ||
BUILD_TYPE: Release | ||
|
@@ -66,12 +72,16 @@ jobs: | |
run: ctest -C $BUILD_TYPE --verbose | ||
|
||
- name: Push binaries | ||
if: contains(matrix.os, 'latest') && contains(matrix.python-version, '3.9') && github.event.pull_request.merged == true | ||
if: | | ||
contains(matrix.os, 'latest') && | ||
contains(matrix.python-version, '3.9') && | ||
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 false | ||
git pull | ||
git add ${{ github.workspace }}/pyfunnel/lib | ||
git diff-index --quiet HEAD || git commit -m "Add ${{ matrix.os }} binaries" | ||
git pull | ||
git push |