Skip to content

Commit

Permalink
Default pull request event sha to branch head
Browse files Browse the repository at this point in the history
  • Loading branch information
peter-evans committed Jun 19, 2020
1 parent 0b99e67 commit 61460c3
Show file tree
Hide file tree
Showing 5 changed files with 4,033 additions and 382 deletions.
8 changes: 0 additions & 8 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,13 +31,6 @@ jobs:
with:
name: action.yml
path: action.yml
- id: vars
run: |
if [[ "${{ github.event_name }}" == "pull_request" ]]; then \
echo "::set-output name=sha::${{ github.event.pull_request.head.sha }}"; \
else \
echo "::set-output name=sha::${{ github.sha }}"; \
fi

test:
if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name == github.repository
Expand All @@ -62,7 +55,6 @@ jobs:
- name: Test create commit comment
uses: ./
with:
sha: ${{ needs.build.outputs.sha }}
body: |
This is a multi-line test comment
- With GitHub **Markdown**
Expand Down
Loading

2 comments on commit 61460c3

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a multi-line test comment

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a multi-line test comment

Please sign in to comment.