Skip to content

Commit

Permalink
Create TryThisPR.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
fonsp authored Nov 16, 2021
1 parent 1c20224 commit fed45c2
Showing 1 changed file with 29 additions and 0 deletions.
29 changes: 29 additions & 0 deletions .github/workflows/TryThisPR.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: "Automatic PR comment: Try this PR!"

on:
pull_request:

jobs:
comment:
runs-on: ubuntu-latest
steps:
- uses: actions/github-script@v3
with:
github-token: ${{secrets.GITHUB_TOKEN}}
script: |
github.issues.createComment({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
body: `
## Try this Pull Request!
Open Julia, and type:
\`\`\`
julia> ]
(@v1.6) pkg> activate --temp
(@v1.6) pkg> add ${context.payload.pull_request.head.repo.html_url}#${context.payload.pull_request.head.ref}
(@v1.6) pkg> # press backspace/delete to go back
julia> using ${context.repository.name.replace(/\.jl$/,"")}
\`\`\`
`
})

0 comments on commit fed45c2

Please sign in to comment.