Skip to content

Commit

Permalink
fix: default branch on clang-lang formatter
Browse files Browse the repository at this point in the history
  • Loading branch information
omarcopires committed Dec 5, 2023
1 parent 9cc8ed0 commit eac923f
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/clang-format.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,28 +13,28 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Cancel Previous Runs
if: github.ref != 'refs/heads/main'
if: github.ref != 'refs/heads/master'
uses: fkirc/skip-duplicate-actions@master
with:
concurrent_skipping: "same_content"
cancel_others: true

- name: Set up Git
if: ${{ github.ref != 'refs/heads/main' }}
if: ${{ github.ref != 'refs/heads/master' }}
run: |
git config --global user.email "github-actions[bot]@users.noreply.github.com"
git config --global user.name "GitHub Actions"
- name: Actions checkout
if: ${{ github.ref != 'refs/heads/main' }}
if: ${{ github.ref != 'refs/heads/master' }}
uses: actions/checkout@v3
with:
repository: ${{ github.event.pull_request.head.repo.full_name }}
ref: ${{ github.event.pull_request.head.ref }}
token: ${{ secrets.GITHUB_TOKEN }}

- name: Run clang format lint
if: ${{ github.ref != 'refs/heads/main' }}
if: ${{ github.ref != 'refs/heads/master' }}
uses: DoozyX/[email protected]
with:
source: "source"
Expand All @@ -43,7 +43,7 @@ jobs:
inplace: true

- name: Run add and commit
if: ${{ github.ref != 'refs/heads/main' }}
if: ${{ github.ref != 'refs/heads/master' }}
uses: EndBug/add-and-commit@v9
with:
author_name: GitHub Actions
Expand Down

0 comments on commit eac923f

Please sign in to comment.