Skip to content

Commit

Permalink
[CI] Install Dependabot and update some workflows (#2266)
Browse files Browse the repository at this point in the history
  • Loading branch information
giordano authored Jan 17, 2025
1 parent 3210e76 commit b76ea4e
Show file tree
Hide file tree
Showing 4 changed files with 37 additions and 51 deletions.
7 changes: 7 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates
version: 2
updates:
- package-ecosystem: "github-actions"
directory: "/" # Location of package manifests
schedule:
interval: "weekly"
49 changes: 11 additions & 38 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
- '1.11'
- 'nightly'
os:
- ubuntu-20.04
- ubuntu-24.04
- macOS-latest
- windows-latest
arch:
Expand All @@ -38,17 +38,17 @@ jobs:
arch: x64
libEnzyme: local
include:
- os: ubuntu-20.04
- os: ubuntu-24.04
arch: x86
libEnzyme: packaged
version: '1.10'
assertions: false
- os: ubuntu-20.04
- os: ubuntu-24.04
arch: x64
libEnzyme: packaged
version: '1.10'
assertions: true
- os: ubuntu-20.04
- os: ubuntu-24.04
arch: x64
libEnzyme: packaged
version: '1.11'
Expand All @@ -72,16 +72,7 @@ jobs:
sed -i.bak 's/exit 2/exit 0/g' julia/deps/tools/jlchecksum
make -C julia -j $(nproc) FORCE_ASSERTIONS=1 LLVM_ASSERTIONS=1 JULIA_PRECOMPILE=0
echo $PWD/julia/usr/bin >> $GITHUB_PATH
- uses: actions/cache@v2
env:
cache-name: cache-artifacts
with:
path: ~/.julia/artifacts
key: ${{ runner.os }}-test-${{ env.cache-name }}-${{ hashFiles('**/Project.toml') }}
restore-keys: |
${{ runner.os }}-test-${{ env.cache-name }}-
${{ runner.os }}-test-
${{ runner.os }}-
- uses: julia-actions/cache@v2
- name: add EnzymeCore
shell: julia --color=yes --project=. {0}
run: |
Expand Down Expand Up @@ -120,10 +111,10 @@ jobs:
JULIA_PKG_SERVER_REGISTRY_PREFERENCE: eager
- uses: julia-actions/julia-processcoverage@v1
if: matrix.version != 'nightly' || steps.run_tests.outcome == 'success'
- uses: codecov/codecov-action@v4
- uses: codecov/codecov-action@v5
if: matrix.version != 'nightly' || steps.run_tests.outcome == 'success'
with:
file: lcov.info
files: lcov.info
token: ${{ secrets.CODECOV_TOKEN }}
fail_ci_if_error: false # or true if you want CI to fail when Codecov fails
enzymetestutils:
Expand All @@ -150,16 +141,7 @@ jobs:
with:
version: ${{ matrix.version }}
arch: ${{ matrix.arch }}
- uses: actions/cache@v2
env:
cache-name: cache-artifacts
with:
path: ~/.julia/artifacts
key: ${{ runner.os }}-test-${{ env.cache-name }}-${{ hashFiles('**/Project.toml') }}
restore-keys: |
${{ runner.os }}-test-${{ env.cache-name }}-
${{ runner.os }}-test-
${{ runner.os }}-
- uses: julia-actions/cache@v2
- name: setup EnzymeTestUtils
shell: julia --color=yes {0}
id: setup_testutils
Expand All @@ -182,7 +164,7 @@ jobs:
if: matrix.version != 'nightly' || steps.run_tests.outcome == 'success'
with:
directories: lib/EnzymeTestUtils/src
- uses: codecov/codecov-action@v4
- uses: codecov/codecov-action@v5
if: matrix.version != 'nightly' || steps.run_tests.outcome == 'success'
with:
files: lcov.info
Expand Down Expand Up @@ -212,16 +194,7 @@ jobs:
with:
version: ${{ matrix.version }}
arch: ${{ matrix.arch }}
- uses: actions/cache@v2
env:
cache-name: cache-artifacts
with:
path: ~/.julia/artifacts
key: ${{ runner.os }}-test-${{ env.cache-name }}-${{ hashFiles('**/Project.toml') }}
restore-keys: |
${{ runner.os }}-test-${{ env.cache-name }}-
${{ runner.os }}-test-
${{ runner.os }}-
- uses: julia-actions/cache@v2
- name: setup EnzymeCore
shell: julia --color=yes {0}
id: setup_testutils
Expand All @@ -244,7 +217,7 @@ jobs:
if: matrix.version != 'nightly' || steps.run_tests.outcome == 'success'
with:
directories: lib/EnzymeCore/src
- uses: codecov/codecov-action@v4
- uses: codecov/codecov-action@v5
if: matrix.version != 'nightly' || steps.run_tests.outcome == 'success'
with:
files: lcov.info
Expand Down
20 changes: 13 additions & 7 deletions .github/workflows/benchmark_pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,22 @@ on:
permissions:
pull-requests: write

concurrency:
# Skip intermediate builds: always.
# Cancel intermediate builds: only if it is a pull request build.
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }}

jobs:
generate_plots:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- uses: julia-actions/setup-julia@v1
- uses: actions/checkout@v4
- uses: julia-actions/setup-julia@v2
with:
version: "1"
- uses: julia-actions/cache@v1
- uses: julia-actions/cache@v2
- name: Extract Package Name from Project.toml
id: extract-package-name
run: |
Expand All @@ -26,8 +32,8 @@ jobs:
JULIA_NUM_THREADS: 2
run: |
# Lightweight build step, as sometimes the runner runs out of memory:
julia -e 'ENV["JULIA_PKG_PRECOMPILE_AUTO"]=0; import Pkg; Pkg.add("AirspeedVelocity")'
julia -e 'ENV["JULIA_PKG_PRECOMPILE_AUTO"]=0; import Pkg; Pkg.build("AirspeedVelocity")'
julia --color=yes -e 'ENV["JULIA_PKG_PRECOMPILE_AUTO"]=0; import Pkg; Pkg.add("AirspeedVelocity")'
julia --color=yes -e 'ENV["JULIA_PKG_PRECOMPILE_AUTO"]=0; import Pkg; Pkg.build("AirspeedVelocity")'
- name: Add ~/.julia/bin to PATH
run: |
echo "$HOME/.julia/bin" >> $GITHUB_PATH
Expand Down Expand Up @@ -60,15 +66,15 @@ jobs:
echo 'Go to "Actions"->"Benchmark a pull request"->[the most recent run]->"Artifacts" (at the bottom).' >> body.md
- name: Find Comment
uses: peter-evans/find-comment@v2
uses: peter-evans/find-comment@v3
id: fcbenchmark
with:
issue-number: ${{ github.event.pull_request.number }}
comment-author: 'github-actions[bot]'
body-includes: Benchmark Results

- name: Comment on PR
uses: peter-evans/create-or-update-comment@v3
uses: peter-evans/create-or-update-comment@v4
with:
comment-id: ${{ steps.fcbenchmark.outputs.comment-id }}
issue-number: ${{ github.event.pull_request.number }}
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/scripts_deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,23 +9,23 @@ on:

jobs:
docs:
runs-on: ubuntu-20.04
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4

- uses: julia-actions/setup-julia@v1
- uses: julia-actions/setup-julia@v2
with:
version: '1'
- uses: julia-actions/cache@v1
- uses: julia-actions/cache@v2
- run: |
julia --project=docs -e '
julia --color=yes --project=docs -e '
using Pkg
Pkg.develop([PackageSpec(path="lib/EnzymeCore"), PackageSpec(path=pwd()), PackageSpec(path="lib/EnzymeTestUtils")])
Pkg.instantiate()'
env:
JULIA_PKG_SERVER_REGISTRY_PREFERENCE: eager
- run: |
julia --project=docs -e '
julia --color=yes --project=docs -e '
using Documenter: DocMeta, doctest
using Enzyme
DocMeta.setdocmeta!(Enzyme, :DocTestSetup, :(using Enzyme); recursive=true)
Expand Down

0 comments on commit b76ea4e

Please sign in to comment.