Skip to content

Commit

Permalink
simplify structure
Browse files Browse the repository at this point in the history
  • Loading branch information
Shoeboxam committed Aug 9, 2022
1 parent 402c63a commit b72e021
Showing 1 changed file with 1 addition and 9 deletions.
10 changes: 1 addition & 9 deletions src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -148,14 +148,6 @@ Pull request: ${repo_url}/pull/${context.issue.number}
Commit: ${repo_url}/commit/${commit_sha}
`

console.log("Creating ref: ", artifacts_branch);
await artifacts_octokit.rest.git.createRef({
owner: artifacts_owner,
repo: artifacts_repo,
ref: `refs/heads/${artifacts_branch}`,
sha: target_sha,
})

await artifacts_octokit.rest.repos.createOrUpdateFileContents({
owner: artifacts_owner,
repo: artifacts_repo,
Expand All @@ -182,7 +174,7 @@ Commit: ${repo_url}/commit/${commit_sha}
const basename = path.split('/').reverse()[0]
const content = fs.readFileSync(path);

const target_name = `pr${context.issue.number}-${basename}`
const target_name = `PR/${context.issue.number}/${basename}`
const target_link = await uploadFile(target_name, content);

body += `| [\`${target_name}\`](${target_link}) | ${commit_sha} |`
Expand Down

0 comments on commit b72e021

Please sign in to comment.