Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
55 changes: 3 additions & 52 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,55 +10,6 @@ permissions:
contents: read

jobs:
lint:
name: Lint
runs-on: ubuntu-latest

env:
RUSTFLAGS: '-Dwarnings'

steps:
- name: Checkout
uses: actions/checkout@v6

- name: Set up Rust toolchain
uses: actions-rust-lang/setup-rust-toolchain@v1
with:
components: clippy, rustfmt

- name: Install Cargo Binary Install
uses: cargo-bins/cargo-binstall@main

- name: Install crates
run: cargo binstall -y --force cargo-deny cargo-machete cargo-sort

- name: Lint
run: cargo clippy --all-features --locked

- name: Check dependencies
run: cargo deny check

- name: Check unused dependencies
run: cargo machete

- name: Check manifest formatting
run: cargo sort --workspace --check

- name: Check formatting
run: cargo fmt --all --check

test:
name: Test
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v6

- name: Set up Rust toolchain
uses: actions-rust-lang/setup-rust-toolchain@v1
with:
components: clippy, rustfmt

- name: Test
run: cargo test --all-features --locked --release
rust:
name: Rust
uses: RustForWeb/.github/.github/workflows/rust.yml@c18f3b7315df398b6af8d03f823e31daeda63114
14 changes: 14 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
name: Publish

on:
release:
types: [published]

permissions:
contents: read
id-token: write

jobs:
publish:
name: Publish
uses: RustForWeb/.github/.github/workflows/publish.yml@c18f3b7315df398b6af8d03f823e31daeda63114
63 changes: 3 additions & 60 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,63 +18,6 @@ permissions:
jobs:
release:
name: Release
runs-on: ubuntu-latest

steps:
- name: Generate GitHub App token
id: app-token
uses: getsentry/action-github-app-token@v3
with:
app_id: ${{ secrets.APP_ID }}
private_key: ${{ secrets.APP_PRIVATE_KEY }}

- name: Checkout
uses: actions/checkout@v6

- name: Set up Rust toolchain
uses: actions-rust-lang/setup-rust-toolchain@v1
with:
target: wasm32-unknown-unknown

- name: Install Cargo Binary Install
uses: cargo-bins/cargo-binstall@main

- name: Install crates
run: cargo binstall --force -y cargo-workspaces toml-cli

- name: Bump version
run: cargo workspaces version --all --no-git-commit --yes ${{ inputs.bump }}

- name: Extract version
id: extract-version
run: echo "VERSION=v$(toml get Cargo.toml package.version --raw)" >> "$GITHUB_OUTPUT"

- name: Add changes
run: git add .

- name: Commit
uses: dsanders11/github-app-commit-action@v2
with:
message: ${{ steps.extract-version.outputs.VERSION }}
token: ${{ steps.app-token.outputs.token }}

- name: Reset and pull
run: git reset --hard && git pull

- name: Tag
uses: bruno-fs/repo-tagger@1.0.0
with:
tag: ${{ steps.extract-version.outputs.VERSION }}
env:
GITHUB_TOKEN: ${{ steps.app-token.outputs.token }}

- name: Release
uses: softprops/action-gh-release@v3
with:
generate_release_notes: true
make_latest: true
tag_name: ${{ steps.extract-version.outputs.VERSION }}
token: ${{ steps.app-token.outputs.token }}

- name: Publish
run: cargo workspaces publish --publish-as-is --token "${{ secrets.CRATES_IO_TOKEN }}"
uses: RustForWeb/.github/.github/workflows/release.yml@c18f3b7315df398b6af8d03f823e31daeda63114
with:
bump: ${{ inputs.bump }}
1 change: 0 additions & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ urlencoding = "2.1.3"
[dev-dependencies]
matches = "0.1.10"
mockito = "1.0.0"
rsa = "0.9.10"
tokio = { version = "1.44.2", default-features = false, features = [
"macros",
"rt-multi-thread",
Expand Down
Loading