Skip to content

Commit

Permalink
Merge branch 'main' into upgrade-to-v2.2
Browse files Browse the repository at this point in the history
  • Loading branch information
jackton1 committed Feb 14, 2021
2 parents cece0f8 + 3bd4c88 commit b50518e
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,18 @@ Get branch information without the `/ref/*` prefix
- name: Get branch names
id: branch-name
uses: tj-actions/branch-names@v2.2

- name: Running on the default branch.
if: ${{ steps.branch-name.outputs.is_default }}
run: |
echo "Running on default: ${{ steps.branch-name.outputs.is_default }}"
# Outputs: "Running on default: true".

- name: Running on a pull request branch.
if: "!${{ steps.branch-name.outputs.is_default }}"
run: |
echo "Running on default: ${{ steps.branch-name.outputs.is_default }}"
# Outputs: "Running on default: false".

- name: Current branch name
if: github.event_name == 'pull_request'
Expand Down

0 comments on commit b50518e

Please sign in to comment.