diff --git a/.github/workflows/CompatHelper.yml b/.github/workflows/CompatHelper.yml index f3d3df2..06166be 100644 --- a/.github/workflows/CompatHelper.yml +++ b/.github/workflows/CompatHelper.yml @@ -3,11 +3,13 @@ name: CompatHelper on: schedule: - cron: '00 00 * * *' - issues: - types: [opened, reopened] + workflow_dispatch: jobs: - build: + CompatHelper: + permissions: + pull-requests: write + contents: write runs-on: ubuntu-latest steps: - name: Pkg.add("CompatHelper") @@ -15,4 +17,5 @@ jobs: - name: CompatHelper.main() env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + COMPATHELPER_PRIV: ${{ secrets.DOCUMENTER_KEY }} run: julia -e 'using CompatHelper; CompatHelper.main()' diff --git a/.github/workflows/Documentations.yml b/.github/workflows/Documentations.yml index eee33f1..2cf55ad 100644 --- a/.github/workflows/Documentations.yml +++ b/.github/workflows/Documentations.yml @@ -5,39 +5,32 @@ on: push: branches: - 'master' - - 'release-' + - 'release-*' tags: '*' release: types: [published] jobs: build: - runs-on: ${{ matrix.os }} - strategy: - matrix: - julia-version: ["1"] - julia-arch: [x64] - os: [ubuntu-latest] + runs-on: ubuntu-latest + permissions: + actions: write # needed to allow julia-actions/cache to proactively delete old caches that it has created + contents: write + statuses: write steps: - - uses: actions/checkout@v1.0.0 - - uses: julia-actions/setup-julia@latest + - uses: actions/checkout@v4 + - uses: julia-actions/setup-julia@v2 with: - version: ${{ matrix.julia-version }} - arch: ${{ matrix.julia-arch }} - - 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 }}- - - name: Install dependencies - run: julia --project=docs/ -e 'using Pkg; Pkg.develop(PackageSpec(path=pwd())); Pkg.instantiate()' - - name: Build and deploy + version: '1' + - uses: julia-actions/cache@v1 + - name: Configure doc environment + shell: julia --project=docs --color=yes {0} + run: | + using Pkg + Pkg.develop(PackageSpec(path=pwd())) + Pkg.instantiate() + - uses: julia-actions/julia-buildpkg@v1 + - uses: julia-actions/julia-docdeploy@v1 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - run: julia --project=docs/ docs/make.jl + DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }} diff --git a/.github/workflows/Invalidations.yml b/.github/workflows/Invalidations.yml index 4d0004e..552de7c 100644 --- a/.github/workflows/Invalidations.yml +++ b/.github/workflows/Invalidations.yml @@ -16,21 +16,45 @@ jobs: if: github.base_ref == github.event.repository.default_branch runs-on: ubuntu-latest steps: - - uses: julia-actions/setup-julia@v1 + - uses: julia-actions/setup-julia@v2 with: version: '1' - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: julia-actions/julia-buildpkg@v1 + - name: Overwrite Package Version # FIXME + run: > + julia -e ' + lines = readlines("Project.toml") + open("Project.toml", "w") do f + for l in lines + if l == "version = \"0.13.0-dev\"" + l = "version = \"0.12.10\"" + end + println(f, l) + end + end' - uses: julia-actions/julia-invalidations@v1 id: invs_pr - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: ref: ${{ github.event.repository.default_branch }} - uses: julia-actions/julia-buildpkg@v1 + - name: Overwrite Package Version # FIXME + run: > + julia -e ' + lines = readlines("Project.toml") + open("Project.toml", "w") do f + for l in lines + if l == "version = \"0.13.0-dev\"" + l = "version = \"0.12.10\"" + end + println(f, l) + end + end' - uses: julia-actions/julia-invalidations@v1 id: invs_default - + - name: Report invalidation counts run: | echo "Invalidations on default branch: ${{ steps.invs_default.outputs.total }} (${{ steps.invs_default.outputs.deps }} via deps)" >> $GITHUB_STEP_SUMMARY diff --git a/.github/workflows/TagBot.yml b/.github/workflows/TagBot.yml index 90dc100..56abd32 100644 --- a/.github/workflows/TagBot.yml +++ b/.github/workflows/TagBot.yml @@ -6,7 +6,7 @@ on: workflow_dispatch: inputs: lookback: - default: 3 + default: '3' permissions: actions: read checks: read diff --git a/.github/workflows/UnitTest.yml b/.github/workflows/UnitTest.yml index 2ce48a0..84ab5ad 100644 --- a/.github/workflows/UnitTest.yml +++ b/.github/workflows/UnitTest.yml @@ -1,47 +1,53 @@ name: Unit test on: - create: - tags: push: branches: - - master + - 'master' + - 'release-*' + tags: ['*'] pull_request: - schedule: - - cron: '20 00 1 * *' - + workflow_dispatch: +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: test: + name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }} - ${{ github.event_name }} runs-on: ${{ matrix.os }} + timeout-minutes: 60 + permissions: # needed to allow julia-actions/cache to proactively delete old caches that it has created + actions: write + contents: read strategy: - matrix: - julia-version: ['1.0', '1', 'nightly'] - os: [ubuntu-latest, windows-latest, macOS-latest] fail-fast: false - + matrix: + julia-version: ['1.0', '1.6', '1', 'nightly'] + os: [ubuntu-latest, windows-latest, macos-13] + julia-arch: [x64] + include: + - os: ubuntu-latest # only test one 32-bit job + julia-version: '1' + julia-arch: x86 + - os: macos-latest + julia-version: '1' + julia-arch: aarch64 + - os: macos-latest + julia-version: 'nightly' + julia-arch: aarch64 steps: - - uses: actions/checkout@v2 - - name: "Set up Julia" - uses: julia-actions/setup-julia@v1 + - uses: actions/checkout@v4 + - uses: julia-actions/setup-julia@v2 with: version: ${{ matrix.julia-version }} - - - 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 }}- - - - name: "Unit Test" - uses: julia-actions/julia-runtest@master - + arch: ${{ matrix.julia-arch }} + - uses: julia-actions/cache@v1 + - uses: julia-actions/julia-buildpkg@v1 + - uses: julia-actions/julia-runtest@v1 - uses: julia-actions/julia-processcoverage@v1 - - uses: codecov/codecov-action@v1 + - uses: codecov/codecov-action@v4 with: - file: lcov.info + files: lcov.info + token: ${{ secrets.CODECOV_TOKEN }}