Skip to content

Commit

Permalink
ci(fix): Remove deprecated actions
Browse files Browse the repository at this point in the history
  • Loading branch information
kjvalencik committed Jun 28, 2024
1 parent 5d16c4d commit 67d3a1f
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 20 deletions.
26 changes: 11 additions & 15 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,19 +25,19 @@ jobs:
- name: Set Matrix
id: set_matrix
env:
FULL_NODE_VERSIONS: '["18.x", "20.x", "21.x"]'
FULL_NODE_VERSIONS: '["18.x", "20.x", "22.x"]'
FULL_RUST_TOOLCHAINS: '["stable", "nightly"]'
PARTIAL_NODE_VERSIONS: '["20.x"]'
PARTIAL_NODE_VERSIONS: '["22.x"]'
PARTIAL_RUST_TOOLCHAINS: '["stable"]'
HAS_FULL_MATRIX_LABEL: ${{ contains(github.event.pull_request.labels.*.name, 'full matrix') }}
IS_PUSHED: ${{ github.event_name == 'push' }}
run: |
if [[ "$HAS_FULL_MATRIX_LABEL" == "true" ]] || [[ "$IS_PUSHED" == "true" ]]; then
echo "::set-output name=node_version::$FULL_NODE_VERSIONS"
echo "::set-output name=rust_toolchain::$FULL_RUST_TOOLCHAINS"
echo "node_version=$FULL_NODE_VERSIONS" >> $GITHUB_OUTPUT
echo "rust_toolchain=$FULL_RUST_TOOLCHAINS" >> $GITHUB_OUTPUT
else
echo "::set-output name=node_version::$PARTIAL_NODE_VERSIONS"
echo "::set-output name=rust_toolchain::$PARTIAL_RUST_TOOLCHAINS"
echo "node_version=$PARTIAL_NODE_VERSIONS" >> $GITHUB_OUTPUT
echo "rust_toolchain=$PARTIAL_RUST_TOOLCHAINS" >> $GITHUB_OUTPUT
fi
build:
Expand All @@ -54,9 +54,9 @@ jobs:
uses: actions/checkout@v4

- name: Use Rust ${{ matrix.rust-toolchain }}
uses: actions-rs/toolchain@v1
with:
toolchain: ${{ matrix.rust-toolchain }}
run: >
rustup toolchain install --profile complete ${{ matrix.rust-toolchain }} &&
rustup default ${{ matrix.rust-toolchain }}
- name: Rust Cache
uses: Swatinem/rust-cache@v2
Expand All @@ -67,21 +67,17 @@ jobs:
node-version: ${{ matrix.node-version }}
cache: npm

- name: Electron Cache Variables
id: electron_cache_vars
run: |
echo "::set-output name=key::${{ runner.os }}-electron-${{ hashFiles('./package-lock.json') }}"
- name: Cache Electron (Linux)
if: matrix.os == 'ubuntu-latest'
uses: actions/cache@v4
with:
key: ${{ steps.electron_cache_vars.outputs.key }}
key: ${{ runner.os }}-electron-${{ hashFiles('./package-lock.json') }}
path: ~/.cache/electron
- name: Cache Electron (Windows)
if: matrix.os == 'windows-latest'
uses: actions/cache@v4
with:
key: ${{ steps.electron_cache_vars.outputs.key }}
key: ${{ runner.os }}-electron-${{ hashFiles('./package-lock.json') }}
path: "%LOCALAPPDATA%\\electron\\Cache"
- name: Cache Electron (macOS)
if: matrix.os == 'macos-latest'
Expand Down
11 changes: 6 additions & 5 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,15 +20,16 @@ jobs:

strategy:
matrix:
node-version: [20.x]
node-version: [22.x]
rust-toolchain: [nightly]

steps:
- uses: actions/checkout@v4
- name: Checkout Code
uses: actions/checkout@v4
- name: Use Rust ${{ matrix.rust-toolchain }}
uses: actions-rs/toolchain@v1
with:
toolchain: ${{ matrix.rust-toolchain }}
run: >
rustup toolchain install --profile complete ${{ matrix.rust-toolchain }} &&
rustup default ${{ matrix.rust-toolchain }}
- name: Rust Cache
uses: Swatinem/rust-cache@v2
- name: Use Node.js ${{ matrix.node-version }}
Expand Down

0 comments on commit 67d3a1f

Please sign in to comment.