diff --git a/.github/workflows/CodeCov.yml b/.github/workflows/CodeCov.yml index 68948ea7..2ae2d4c1 100644 --- a/.github/workflows/CodeCov.yml +++ b/.github/workflows/CodeCov.yml @@ -10,12 +10,12 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2.2.0 + - uses: actions/checkout@v4 - name: Set up Julia - uses: julia-actions/setup-julia@latest + uses: julia-actions/setup-julia@v1 with: - version: 1.9 + version: '1.10' - name: Test with coverage env: @@ -33,7 +33,7 @@ jobs: if: success() - name: Submit coverage - uses: codecov/codecov-action@v1.0.7 + uses: codecov/codecov-action@v2 with: token: ${{secrets.CODECOV_TOKEN}} if: success() diff --git a/.github/workflows/DocCleanup.yml b/.github/workflows/DocCleanup.yml index 15680241..43b39afe 100644 --- a/.github/workflows/DocCleanup.yml +++ b/.github/workflows/DocCleanup.yml @@ -9,7 +9,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout gh-pages branch - uses: actions/checkout@v2 + uses: actions/checkout@v4 with: ref: gh-pages diff --git a/.github/workflows/Documentation.yml b/.github/workflows/Documentation.yml index 9cede4e5..b14eea54 100644 --- a/.github/workflows/Documentation.yml +++ b/.github/workflows/Documentation.yml @@ -7,18 +7,22 @@ on: tags: '*' pull_request: +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + jobs: docbuild: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 - - uses: julia-actions/setup-julia@latest + - uses: actions/checkout@v4 + - uses: julia-actions/setup-julia@v1 with: - version: 1.9 + version: '1.10' - name: Install dependencies - run: julia --project=docs -e 'using Pkg; Pkg.instantiate(;verbose=true)' + run: julia --project=docs/ -e 'using Pkg; Pkg.develop(PackageSpec(path=pwd())); Pkg.instantiate()' - name: Build and deploy env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }} - run: julia --project=docs docs/make.jl + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # For authentication with GitHub Actions token + DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }} # For authentication with SSH deploy key + run: julia --project=docs/ docs/make.jl diff --git a/.github/workflows/UnitTests.yml b/.github/workflows/UnitTests.yml deleted file mode 100644 index 9cf7b2c6..00000000 --- a/.github/workflows/UnitTests.yml +++ /dev/null @@ -1,38 +0,0 @@ -name: Unit Tests - -on: - pull_request: - -jobs: - test-os: - timeout-minutes: 120 - strategy: - matrix: - julia-version: [1.9] - os: [ubuntu-latest, windows-latest, macos-latest] - - runs-on: ${{ matrix.os }} - - steps: - - name: Checkout - uses: actions/checkout@v2.2.0 - - - uses: julia-actions/setup-julia@latest - with: - version: ${{ matrix.julia-version }} - - # https://discourse.julialang.org/t/recommendation-cache-julia-artifacts-in-ci-services/35484 - - name: Cache artifacts - uses: actions/cache@v1 - 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/julia-buildpkg@master - - uses: julia-actions/julia-runtest@master diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 00000000..a6eec0e7 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,47 @@ +name: ci +on: + push: + tags: '*' + pull_request: + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +jobs: + test: + name: ci ${{ matrix.version }} - ${{ matrix.os }} + runs-on: ${{ matrix.os }} + strategy: + fail-fast: false + matrix: + version: + - '1.10' + os: + - ubuntu-latest + - macOS-latest + arch: + - x64 + steps: + - uses: actions/checkout@v4 + - uses: julia-actions/setup-julia@v1 + with: + version: ${{ matrix.version }} + arch: ${{ matrix.arch }} + - uses: actions/cache@v1 + 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/julia-buildpkg@v1 + - uses: julia-actions/julia-runtest@v1 + - uses: julia-actions/julia-processcoverage@v1 + - uses: codecov/codecov-action@v1 + with: + file: lcov.info + token: ${{secrets.CODECOV_TOKEN}} diff --git a/.github/workflows/julia_formatter.yml b/.github/workflows/julia_formatter.yml index d8cca9dc..8ddb2975 100644 --- a/.github/workflows/julia_formatter.yml +++ b/.github/workflows/julia_formatter.yml @@ -15,7 +15,7 @@ jobs: with: access_token: ${{ github.token }} - - uses: actions/checkout@v2.2.0 + - uses: actions/checkout@v4 - uses: dorny/paths-filter@v2.9.1 id: filter @@ -24,10 +24,10 @@ jobs: julia_file_change: - added|modified: '**.jl' - - uses: julia-actions/setup-julia@latest + - uses: julia-actions/setup-julia@v1 if: steps.filter.outputs.julia_file_change == 'true' with: - version: '1.9' + version: '1.10' - name: Apply JuliaFormatter if: steps.filter.outputs.julia_file_change == 'true' diff --git a/README.md b/README.md index 86b25730..c42ef377 100644 --- a/README.md +++ b/README.md @@ -13,8 +13,8 @@ [docs-dev-img]: https://img.shields.io/badge/docs-dev-blue.svg [docs-dev-url]: https://CliMA.github.io/ClimaTimeSteppers.jl/dev/ -[gha-ci-img]: https://github.com/CliMA/ClimaTimeSteppers.jl/actions/workflows/UnitTests.yml/badge.svg -[gha-ci-url]: https://github.com/CliMA/ClimaTimeSteppers.jl/actions/workflows/UnitTests.yml +[gha-ci-img]: https://github.com/CliMA/ClimaTimeSteppers.jl/actions/workflows/ci.yml/badge.svg +[gha-ci-url]: https://github.com/CliMA/ClimaTimeSteppers.jl/actions/workflows/ci.yml [codecov-img]: https://codecov.io/gh/CliMA/ClimaTimeSteppers.jl/branch/main/graph/badge.svg [codecov-url]: https://codecov.io/gh/CliMA/ClimaTimeSteppers.jl