Skip to content

Commit

Permalink
GitHub actions: update to current versions (#847)
Browse files Browse the repository at this point in the history
* GitHub actions: update to current versions

The GHA `ci.yml` and others show the warning

_Node.js 12 actions are deprecated. Please update the following actions to use Node.js 16: actions/checkout@v2, actions/setup-python@v2, r-lib/actions/setup-r@v1, actions/upload-artifact@v2. For more information see: https://github.blog/changelog/2022-09-22-github-actions-all-actions-will-begin-running-on-node16-instead-of-node12/._

Additionally:
- update the various actions
- updates ubuntu-20.04 to ubuntu-22.04 (see also OSGeo/grass#2730)
- sync Python to v3.10
- updates to super-linter:v4
- super-linter: enable markdown linting
- use the real super-linter action instead of a container
- super-linter.yml: do not mix VALIDATE=true and VALIDATE=false

Co-authored-by: Nicklas Larsson <n_larsson@yahoo.com>
Co-authored-by: Edouard Choinière <27212526+echoix@users.noreply.github.com>
  • Loading branch information
3 people committed Jan 24, 2023
1 parent bc8f50d commit eb67fa0
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 25 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/black.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,17 +15,17 @@ jobs:
strategy:
matrix:
include:
- os: ubuntu-20.04
- os: ubuntu-22.04
python-version: "3.10"
black-version: "22.3.0"

runs-on: ${{ matrix.os }}

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3

- name: Set up Python
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}

Expand Down
14 changes: 7 additions & 7 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
build:
name: ${{ matrix.grass-version }} (Python ${{ matrix.python-version }})

runs-on: ubuntu-20.04
runs-on: ubuntu-22.04

strategy:
matrix:
Expand All @@ -21,22 +21,22 @@ jobs:
# only.
include:
- grass-version: main
python-version: "3.8"
python-version: "3.10"
- grass-version: releasebranch_8_2
python-version: "3.8"
python-version: "3.10"
fail-fast: false

steps:

- name: Checkout core
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
repository: OSGeo/grass
ref: ${{ matrix.grass-version }}
path: grass

- name: Checkout addons
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
path: grass-addons

Expand All @@ -48,7 +48,7 @@ jobs:
sudo apt-get install -y --no-install-recommends --no-install-suggests
- name: Set up Python ${{ matrix.python-version }} as default Python
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}

Expand Down Expand Up @@ -94,7 +94,7 @@ jobs:
pip install -r grass-addons/.github/workflows/extra_requirements.txt
- name: Set up R
uses: r-lib/actions/setup-r@v1
uses: r-lib/actions/setup-r@v2
with:
r-version: "4.2.1"

Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/flake8.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@ on:

jobs:
flake8:
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3

- name: Set up Python
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: 3.8
python-version: "3.10"

- name: Install
run: |
Expand Down
23 changes: 12 additions & 11 deletions .github/workflows/super-linter.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,22 +11,23 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Lint code base
uses: docker://github/super-linter:v2.2.2
uses: github/super-linter@v4
env:
# Listed but disabled linters would be nice to have.
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# Listed but commented out linters would be nice to have.
# (see https://github.com/github/super-linter#environment-variables)
#
# Python (supported using Pylint) and C/C++ (not supported) are
# handled separately due to the complexity of the settings.
# (The rest is simply disabled automatically as of v2.)
VALIDATE_BASH: false
VALIDATE_CSS: false
VALIDATE_DOCKER: false
# VALIDATE_BASH: true
# VALIDATE_CSS: true
# VALIDATE_DOCKER: true
VALIDATE_JAVASCRIPT_ES: true
VALIDATE_JAVASCRIPT_STANDARD: false
# VALIDATE_JAVASCRIPT_STANDARD: true
VALIDATE_JSON: true
VALIDATE_MD: true
VALIDATE_PERL: false
VALIDATE_MARKDOWN: true
VALIDATE_POWERSHELL: true
VALIDATE_XML: false
# VALIDATE_XML: true
VALIDATE_YAML: true

0 comments on commit eb67fa0

Please sign in to comment.