Skip to content

Commit

Permalink
ci: drop ubuntu-18.04, add 22.04, latest (#776)
Browse files Browse the repository at this point in the history
  • Loading branch information
imomaliev committed Sep 4, 2022
1 parent 765cf11 commit 2eea5d7
Show file tree
Hide file tree
Showing 11 changed files with 49 additions and 29 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/codeql.yml
Expand Up @@ -8,7 +8,7 @@ on:

jobs:
CodeQL-Build:
runs-on: ubuntu-18.04
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/dependency-review.yml
Expand Up @@ -10,7 +10,7 @@ permissions:

jobs:
dependency-review:
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- uses: actions/dependency-review-action@v2
2 changes: 1 addition & 1 deletion .github/workflows/dev-image.yml
Expand Up @@ -25,7 +25,7 @@ on:

jobs:
dev-image-test:
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- name: Login to Packages
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/label-commenter.yml
Expand Up @@ -17,7 +17,7 @@ permissions:

jobs:
comment:
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/labeler.yml
Expand Up @@ -6,7 +6,7 @@ on:

jobs:
triage:
runs-on: ubuntu-18.04
runs-on: ubuntu-22.04
steps:
- uses: actions/labeler@v4
with:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pages-status-check.yml
Expand Up @@ -4,7 +4,7 @@ on: page_build

jobs:
pages-status-check:
runs-on: ubuntu-18.04
runs-on: ubuntu-22.04
steps:
- name: check status
run: |
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/purge-readme-image-cache.yml
Expand Up @@ -7,7 +7,7 @@ on:

jobs:
purge:
runs-on: ubuntu-18.04
runs-on: ubuntu-22.04
steps:

- run: >
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Expand Up @@ -7,7 +7,7 @@ on:

jobs:
release:
runs-on: ubuntu-18.04
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
# https://github.com/peaceiris/workflows/blob/main/create-release-npm/action.yml
Expand Down
29 changes: 24 additions & 5 deletions .github/workflows/test.yml
Expand Up @@ -19,8 +19,9 @@ jobs:
strategy:
matrix:
os:
- 'ubuntu-22.04'
- 'ubuntu-20.04'
- 'ubuntu-18.04'
- 'ubuntu-latest'
- 'macos-latest'
- 'windows-latest'
permissions:
Expand Down Expand Up @@ -51,7 +52,7 @@ jobs:
- run: npm ci --ignore-scripts

- name: npm audit
if: startsWith(matrix.os, 'ubuntu-18.04')
if: startsWith(matrix.os, 'ubuntu-22.04')
run: |
npm audit > ./audit.log || true
if ! [ "$(cat ./audit.log | wc -l)" = 1 ]; then
Expand All @@ -60,11 +61,11 @@ jobs:
rm ./audit.log
- name: Run prettier
if: startsWith(matrix.os, 'ubuntu-18.04')
if: startsWith(matrix.os, 'ubuntu-22.04')
run: npm run format:check

- name: Run eslint
if: startsWith(matrix.os, 'ubuntu-18.04')
if: startsWith(matrix.os, 'ubuntu-22.04')
run: npm run lint

- run: npm test
Expand Down Expand Up @@ -99,7 +100,7 @@ jobs:

- name: Deploy
if: |
startsWith(matrix.os, 'ubuntu-18.04') &&
startsWith(matrix.os, 'ubuntu-latest') &&
github.ref == 'refs/heads/main' && github.event.repository.fork == false
uses: ./
with:
Expand Down Expand Up @@ -171,3 +172,21 @@ jobs:
user_name: 'github-actions[bot]'
user_email: 'github-actions[bot]@users.noreply.github.com'
# commit_message: ${{ github.event.head_commit.message }}

- name: Deploy
if: |
startsWith(matrix.os, 'ubuntu-22.04') &&
github.ref == 'refs/heads/main' && github.event.repository.fork == false
uses: ./
with:
# deploy_key: ${{ secrets.ACTIONS_DEPLOY_KEY }}
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_branch: gh-pages-ubuntu-22.04
publish_dir: ./test_projects/mdbook/book
# external_repository: ''
allow_empty_commit: true
# keep_files: true
# force_orphan: true
user_name: 'github-actions[bot]'
user_email: 'github-actions[bot]@users.noreply.github.com'
# commit_message: ${{ github.event.head_commit.message }}
2 changes: 1 addition & 1 deletion .github/workflows/update-major-tag.yml
Expand Up @@ -6,7 +6,7 @@ on:

jobs:
update:
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
timeout-minutes: 1
steps:
- uses: actions/checkout@v3
Expand Down
31 changes: 16 additions & 15 deletions README.md
Expand Up @@ -65,8 +65,9 @@ All Actions runners: Linux (Ubuntu), macOS, and Windows are supported.

| runs-on | `github_token` | `deploy_key` | `personal_token` |
|---|:---:|:---:|:---:|
| ubuntu-22.04 | 鉁咃笍 | 鉁咃笍 | 鉁咃笍 |
| ubuntu-20.04 | 鉁咃笍 | 鉁咃笍 | 鉁咃笍 |
| ubuntu-18.04 | 鉁咃笍 | 鉁咃笍 | 鉁咃笍 |
| ubuntu-latest | 鉁咃笍 | 鉁咃笍 | 鉁咃笍 |
| macos-latest | 鉁咃笍 | 鉁咃笍 | 鉁咃笍 |
| windows-latest | 鉁咃笍 | (2) | 鉁咃笍 |

Expand Down Expand Up @@ -149,7 +150,7 @@ on:

jobs:
deploy:
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
permissions:
contents: write
concurrency:
Expand All @@ -170,8 +171,8 @@ jobs:

- name: Deploy
uses: peaceiris/actions-gh-pages@v3
# If you're changing the branch from main,
# also change the `main` in `refs/heads/main`
# If you're changing the branch from main,
# also change the `main` in `refs/heads/main`
# below accordingly.
if: ${{ github.ref == 'refs/heads/main' }}
with:
Expand Down Expand Up @@ -489,7 +490,7 @@ on:

jobs:
deploy:
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
permissions:
contents: write
concurrency:
Expand Down Expand Up @@ -641,7 +642,7 @@ on:

jobs:
deploy:
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
permissions:
contents: write
concurrency:
Expand Down Expand Up @@ -683,7 +684,7 @@ on:

jobs:
deploy:
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
permissions:
contents: write
concurrency:
Expand Down Expand Up @@ -733,7 +734,7 @@ on:

jobs:
deploy:
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
permissions:
contents: write
concurrency:
Expand Down Expand Up @@ -785,7 +786,7 @@ on:

jobs:
deploy:
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
permissions:
contents: write
concurrency:
Expand Down Expand Up @@ -842,7 +843,7 @@ on:

jobs:
deploy:
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
permissions:
contents: write
concurrency:
Expand Down Expand Up @@ -897,7 +898,7 @@ on:

jobs:
deploy:
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
permissions:
contents: write
concurrency:
Expand Down Expand Up @@ -957,7 +958,7 @@ on:

jobs:
deploy:
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
permissions:
contents: write
concurrency:
Expand Down Expand Up @@ -1019,7 +1020,7 @@ on:

jobs:
deploy:
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
permissions:
contents: write
concurrency:
Expand Down Expand Up @@ -1064,7 +1065,7 @@ on:

jobs:
deploy:
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
permissions:
contents: write
concurrency:
Expand Down Expand Up @@ -1110,7 +1111,7 @@ on:

jobs:
deploy:
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
permissions:
contents: write
concurrency:
Expand Down

0 comments on commit 2eea5d7

Please sign in to comment.