Skip to content

Commit 43ce7ef

Browse files
committed
Add isDynamicWorkflow function
1 parent 4d0c164 commit 43ce7ef

File tree

6 files changed

+26
-6
lines changed

6 files changed

+26
-6
lines changed

lib/analyze-action.js

Lines changed: 4 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/init-action-post.js

Lines changed: 4 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/init-action.js

Lines changed: 4 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/upload-lib.js

Lines changed: 4 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/upload-sarif-action.js

Lines changed: 4 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/actions-util.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -247,9 +247,14 @@ export function isSelfHostedRunner() {
247247
return process.env.RUNNER_ENVIRONMENT === "self-hosted";
248248
}
249249

250+
/** Determines whether the workflow trigger is `dynamic`. */
251+
export function isDynamicWorkflow(): boolean {
252+
return getWorkflowEventName() === "dynamic";
253+
}
254+
250255
/** Determines whether we are running in default setup. */
251256
export function isDefaultSetup(): boolean {
252-
return getWorkflowEventName() === "dynamic";
257+
return isDynamicWorkflow();
253258
}
254259

255260
export function prettyPrintInvocation(cmd: string, args: string[]): string {

0 commit comments

Comments
 (0)