Skip to content

Commit 4da349c

Browse files
authored
Merge pull request #110 from abhro/update-workflows
Update workflows
2 parents 2fb55e8 + 5c93708 commit 4da349c

File tree

3 files changed

+50
-33
lines changed

3 files changed

+50
-33
lines changed

.github/dependabot.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
# https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates
2+
version: 2
3+
updates:
4+
- package-ecosystem: "github-actions"
5+
directory: "/" # Location of package manifests
6+
schedule:
7+
interval: "monthly"

.github/workflows/CI.yml

Lines changed: 11 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -17,52 +17,34 @@ jobs:
1717
strategy:
1818
fail-fast: false
1919
matrix:
20-
version:
21-
- "1.6"
22-
- "nightly"
23-
os:
24-
- ubuntu-latest
25-
arch:
26-
- x64
27-
- x86
20+
version: ['1.6', 'nightly']
21+
os: [ubuntu-latest]
22+
arch: [x64, x86]
2823
steps:
29-
- uses: actions/checkout@v2
30-
- uses: julia-actions/setup-julia@v1
24+
- uses: actions/checkout@v4
25+
- uses: julia-actions/setup-julia@v2
3126
with:
3227
version: ${{ matrix.version }}
3328
arch: ${{ matrix.arch }}
34-
- uses: actions/cache@v1
35-
env:
36-
cache-name: cache-artifacts
37-
with:
38-
path: ~/.julia/artifacts
39-
key: ${{ runner.os }}-test-${{ env.cache-name }}-${{ hashFiles('**/Project.toml') }}
40-
restore-keys: |
41-
${{ runner.os }}-test-${{ env.cache-name }}-
42-
${{ runner.os }}-test-
43-
${{ runner.os }}-
29+
- uses: julia-actions/cache@v2
4430
- uses: julia-actions/julia-buildpkg@v1
4531
- uses: julia-actions/julia-runtest@v1
4632
- uses: julia-actions/julia-processcoverage@v1
47-
- uses: codecov/codecov-action@v2
33+
- uses: codecov/codecov-action@v5
4834
with:
4935
files: lcov.info
36+
token: ${{ secrets.CODECOV_TOKEN }}
5037
docs:
5138
name: Documentation
5239
runs-on: ubuntu-latest
5340
steps:
54-
- uses: actions/checkout@v2
55-
- uses: julia-actions/setup-julia@v1
41+
- uses: actions/checkout@v4
42+
- uses: julia-actions/setup-julia@v2
5643
with:
5744
version: "1"
45+
- uses: julia-actions/cache@v2
5846
- uses: julia-actions/julia-buildpkg@v1
5947
- uses: julia-actions/julia-docdeploy@v1
6048
env:
6149
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
6250
DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }}
63-
- run: |
64-
julia --project=docs -e '
65-
using Documenter: DocMeta, doctest
66-
using GreenFunc
67-
DocMeta.setdocmeta!(GreenFunc, :DocTestSetup, :(using GreenFunc); recursive=true)
68-
doctest(GreenFunc)'

.github/workflows/CompatHelper.yml

Lines changed: 32 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,44 @@
11
name: CompatHelper
2+
23
on:
34
schedule:
45
- cron: 0 0 * * *
56
workflow_dispatch:
7+
8+
permissions:
9+
contents: write
10+
pull-requests: write
11+
612
jobs:
713
CompatHelper:
814
runs-on: ubuntu-latest
915
steps:
10-
- name: Pkg.add("CompatHelper")
11-
run: julia -e 'using Pkg; Pkg.add("CompatHelper")'
12-
- name: CompatHelper.main()
16+
- name: Check if Julia is already available in the PATH
17+
id: julia_in_path
18+
run: which julia
19+
continue-on-error: true
20+
- name: Install Julia, but only if it is not already available in the PATH
21+
if: steps.julia_in_path.outcome != 'success'
22+
uses: julia-actions/setup-julia@v2
23+
with:
24+
version: '1'
25+
arch: ${{ runner.arch }}
26+
- name: Add the General registry via Git
27+
shell: julia --color=yes {0}
28+
run: import Pkg; Pkg.Registry.add("General")
29+
env:
30+
JULIA_PKG_SERVER: ""
31+
- name: Install CompatHelper
32+
shell: julia --color=yes {0}
33+
run: |
34+
import Pkg
35+
name = "CompatHelper"
36+
uuid = "aa819f21-2bde-4658-8897-bab36330d9b7"
37+
version = "3"
38+
Pkg.add(; name, uuid, version)
39+
- name: Run CompatHelper
40+
shell: julia --color=yes {0}
41+
run: import CompatHelper; CompatHelper.main()
1342
env:
1443
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
1544
COMPATHELPER_PRIV: ${{ secrets.DOCUMENTER_KEY }}
16-
run: julia -e 'using CompatHelper; CompatHelper.main()'

0 commit comments

Comments
 (0)