Skip to content

Commit

Permalink
Use commit hash instead of ref name (#4)
Browse files Browse the repository at this point in the history
  • Loading branch information
sebastianrath committed Jan 12, 2024
2 parents a251c62 + 2b3cb06 commit 8d4a3e3
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
3 changes: 1 addition & 2 deletions dist/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -37853,11 +37853,10 @@ function run() {
const GRAPH_FILE_DIR = ".github/workflows/graphs";
const graphFile = path_1.default.join(GRAPH_FILE_DIR, core.getInput("graph_file", { required: true }));
// Log output
const refName = process.env.GITHUB_REF_NAME;
const sha = process.env.GITHUB_SHA;
const repo = process.env.GITHUB_REPOSITORY;
const runId = process.env.GITHUB_RUN_ID;
const output = `馃煝 View Action Graph: https://www.actionforge.dev/github/${repo}/${refName !== null && refName !== void 0 ? refName : sha}/${graphFile}?run_id=${runId}`;
const output = `馃煝 View Action Graph: https://www.actionforge.dev/github/${repo}/${sha}/${graphFile}?run_id=${runId}`;
const delimiter = '-'.repeat(32);
console.log(`${delimiter}`);
console.log(output);
Expand Down
3 changes: 1 addition & 2 deletions src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -115,11 +115,10 @@ async function run(): Promise<void> {
);

// Log output
const refName = process.env.GITHUB_REF_NAME;
const sha = process.env.GITHUB_SHA;
const repo = process.env.GITHUB_REPOSITORY;
const runId = process.env.GITHUB_RUN_ID;
const output = `馃煝 View Action Graph: https://www.actionforge.dev/github/${repo}/${refName ?? sha}/${graphFile}?run_id=${runId}`;
const output = `馃煝 View Action Graph: https://www.actionforge.dev/github/${repo}/${sha}/${graphFile}?run_id=${runId}`;
const delimiter = '-'.repeat(32);
console.log(`${delimiter}`);
console.log(output);
Expand Down

0 comments on commit 8d4a3e3

Please sign in to comment.