-
Notifications
You must be signed in to change notification settings - Fork 29
53 lines (44 loc) · 1.44 KB
/
update-versions.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
name: Auto-update versions
on:
schedule:
- cron: 0 0 1/7 * *
workflow_dispatch:
permissions:
contents: write
pull-requests: write
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Clone repo
uses: actions/checkout@v4
- name: Check if Julia is already available in the PATH
id: julia_in_path
run: which julia
continue-on-error: true
- name: Install Julia, but only if it is not already available in the PATH
uses: julia-actions/setup-julia@v2
with:
version: "1"
arch: ${{ runner.arch }}
if: steps.julia_in_path.outcome != 'success'
- name: Use Julia cache
uses: julia-actions/cache@v2
- name: Install JSON3 and run script
run: |
julia -e 'import Pkg; Pkg.add("JSON3")'
julia .github/update-versions.jl
- name: Create Pull Request
id: cpr
uses: peter-evans/create-pull-request@v7
with:
token: ${{ secrets.GITHUB_TOKEN }}
commit-message: ":robot: Auto-update Julia versions"
title: "[AUTO] Update Julia versions"
branch: auto-update-versions
delete-branch: true
labels: update, automated pr, no changelog
- name: Check outputs
run: |
echo "Pull Request Number - ${{ steps.cpr.outputs.pull-request-number }}"
echo "Pull Request URL - ${{ steps.cpr.outputs.pull-request-url }}"