Skip to content

Commit

Permalink
Check if action is run on a PR (#36)
Browse files Browse the repository at this point in the history
  • Loading branch information
PicoCentauri authored Dec 18, 2024
1 parent d672df6 commit 66145e6
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 1 deletion.
4 changes: 4 additions & 0 deletions dist/index.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/index.js.map

Large diffs are not rendered by default.

5 changes: 5 additions & 0 deletions src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,11 @@ import { DefaultArtifactClient } from '@actions/artifact'

export async function run(): Promise<void> {
try {
if (!context.payload.pull_request) {
core.info('Not a pull request. Skipping action.')
return
}

const inputs = {
name: core.getInput('name', { required: true }),
description: core.getInput('description', { required: false }),
Expand Down

0 comments on commit 66145e6

Please sign in to comment.