General PgExecutor to enqueue tasks in transactions #44
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: | |
push: | |
branches: | |
- main | |
- ci | |
pull_request: | |
env: | |
SQLX_OFFLINE: true | |
jobs: | |
rustfmt: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Set up Rust | |
uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: nightly | |
components: rustfmt | |
- name: Cargo fmt | |
run: cargo fmt -- --check | |
clippy: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Set up Rust | |
uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: stable | |
components: clippy | |
- name: Clippy | |
run: cargo clippy --bins --examples --tests -- -D warnings | |
test: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Set up Rust | |
uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: stable | |
- name: Cargo test | |
run: cargo test --bins --examples --tests | |
readme: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: stable | |
- name: Install `cargo-sync-readme` | |
uses: actions-rs/install@v0.1 | |
with: | |
crate: cargo-sync-readme | |
version: latest | |
- name: Is readme in sync? | |
run: cargo sync-readme -c | |
typos: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Check typos in `rust` folder | |
uses: crate-ci/typos@master | |
with: | |
files: . | |
cargo_sort: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Set up Rust | |
uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: stable | |
- name: Install cargo-sort | |
run: cargo install cargo-sort | |
- name: Are Cargo configs sorted? | |
run: cargo sort -c |