Skip to content

Commit

Permalink
ci: migrate unmaintained actions, upgrade actions (#95)
Browse files Browse the repository at this point in the history
  • Loading branch information
andrii-bodnar authored Aug 7, 2024
1 parent 500d5d0 commit f541fa2
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 66 deletions.
55 changes: 10 additions & 45 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,56 +17,21 @@ jobs:
name: Check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions-rs/toolchain@v1
with:
profile: minimal
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- uses: Swatinem/rust-cache@v2
- uses: actions-rs/cargo@v1
with:
command: check

- name: Run cargo check
run: cargo check

test:
name: Test Suite
runs-on: ubuntu-latest
needs: check
steps:
- uses: actions/checkout@v3
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- uses: Swatinem/rust-cache@v2
- uses: actions-rs/cargo@v1
with:
command: test

# fmt:
# name: Rustfmt
# runs-on: ubuntu-latest
# steps:
# - uses: actions/checkout@v2
# - uses: actions-rs/toolchain@v1
# with:
# profile: minimal
# - uses: Swatinem/rust-cache@v2
# - run: rustup component add rustfmt
# - uses: actions-rs/cargo@v1
# with:
# command: fmt
# args: --all -- --check

# clippy:
# name: Clippy
# runs-on: ubuntu-latest
# steps:
# - uses: actions/checkout@v2
# - uses: actions-rs/toolchain@v1
# with:
# profile: minimal
# - uses: Swatinem/rust-cache@v2
# - run: rustup component add clippy
# - uses: actions-rs/cargo@v1
# with:
# command: clippy
# args: -- -D warnings
- name: Run cargo test
run: cargo test
24 changes: 3 additions & 21 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,34 +9,16 @@ jobs:
name: Release
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- uses: actions-rs/toolchain@v1
with:
profile: minimal
target: wasm32-wasi
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable

- name: Set up Node 14
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
registry-url: 'https://registry.npmjs.org'
node-version: 14.x

- uses: Swatinem/rust-cache@v2
# - name: Get yarn cache directory path
# id: yarn-cache-dir-path
# run: echo "::set-output name=dir::$(yarn config get cacheFolder)"

# - name: Install semantic-release-rust
# run: cargo install --git https://github.com/arlyon/semantic-release-rust.git
# - name: Install dependencies
# run: yarn
# - name: Release
# run: yarn semantic-release
# env:
# GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
# CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }}
# NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

- name: Build and publish 'latest' tag
if: ${{ github.event.action == 'released' }}
Expand Down

0 comments on commit f541fa2

Please sign in to comment.