Skip to content

Commit 68e06c6

Browse files
Update CompatHelper workflow for Julia setup
1 parent 7c0d20c commit 68e06c6

1 file changed

Lines changed: 31 additions & 6 deletions

File tree

.github/workflows/CompatHelper.yml

Lines changed: 31 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,20 +10,45 @@ permissions:
1010
pull-requests: write
1111

1212
jobs:
13-
compathelper:
13+
CompatHelper:
1414
runs-on: ubuntu-latest
1515
steps:
16-
- uses: actions/checkout@v6
16+
- uses: actions/checkout@v4
1717

18-
- uses: julia-actions/setup-julia@v2
18+
- name: Check if Julia is already available in the PATH
19+
id: julia_in_path
20+
run: which julia
21+
continue-on-error: true
22+
23+
- name: Install Julia, but only if it is not already available in the PATH
24+
if: steps.julia_in_path.outcome != 'success'
25+
uses: julia-actions/setup-julia@v2
1926
with:
20-
version: '1.9'
27+
version: '1'
28+
arch: ${{ runner.arch }}
29+
30+
- name: Add the General registry via Git
31+
run: |
32+
import Pkg
33+
ENV["JULIA_PKG_SERVER"] = ""
34+
Pkg.Registry.add("General")
35+
shell: julia --color=yes {0}
2136

2237
- name: Install CompatHelper
23-
run: julia -e 'using Pkg; Pkg.add("CompatHelper")'
38+
run: |
39+
import Pkg
40+
name = "CompatHelper"
41+
uuid = "aa819f21-2bde-4658-8897-bab36330d9b7"
42+
version = "3"
43+
Pkg.add(; name, uuid, version)
44+
shell: julia --color=yes {0}
2445

2546
- name: Run CompatHelper
47+
run: |
48+
import CompatHelper
49+
CompatHelper.main()
50+
shell: julia --color=yes {0}
2651
env:
2752
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2853
COMPATHELPER_PRIV: ${{ secrets.DOCUMENTER_KEY }}
29-
run: julia -e 'using CompatHelper; CompatHelper.main()'
54+
# or: COMPATHELPER_PRIV: ${{ secrets.COMPATHELPER_PRIV }}

0 commit comments

Comments
 (0)