From 2e0b8294c414f8930c29ab7cc8da507d1550686c Mon Sep 17 00:00:00 2001 From: Yuki Kishimoto Date: Fri, 19 Jan 2024 10:40:08 +0100 Subject: [PATCH] Add `.github` folder --- .github/FUNDING.yml | 3 ++ .github/dependabot.yml | 11 ++++++ .github/workflows/ci.yml | 79 ++++++++++++++++++++++++++++++++++++++++ 3 files changed, 93 insertions(+) create mode 100644 .github/FUNDING.yml create mode 100644 .github/dependabot.yml create mode 100644 .github/workflows/ci.yml diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml new file mode 100644 index 0000000..c6f0b93 --- /dev/null +++ b/.github/FUNDING.yml @@ -0,0 +1,3 @@ +custom: [ + 'https://getalby.com/p/yuki', +] \ No newline at end of file diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 0000000..d29a12c --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,11 @@ +# To get started with Dependabot version updates, you'll need to specify which +# package ecosystems to update and where the package manifests are located. +# Please see the documentation for all configuration options: +# https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates + +version: 2 +updates: + - package-ecosystem: "cargo" + directory: "/" # Location of package manifests + schedule: + interval: "monthly" diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..3719c4f --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,79 @@ +name: CI + +on: + push: + branches: [ master ] + pull_request: + branches: [ master ] + +env: + CARGO_TERM_COLOR: always + +jobs: + fmt: + name: Format + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v3 + - name: Justfile + run: cargo install just + - name: Check + run: just check-fmt + + check-crates: + name: Check crates + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v3 + - name: Cache + uses: actions/cache@v3 + with: + path: | + ~/.cargo/registry + ~/.cargo/git + target + key: ${{ runner.os }}-cargo-default-${{ hashFiles('**/Cargo.toml','**/Cargo.lock') }} + - name: Justfile + run: cargo install just + - name: Check + run: just check-crates + + check-crates-msrv: + name: Check crates (MSRV) + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v3 + - name: Cache + uses: actions/cache@v3 + with: + path: | + ~/.cargo/registry + ~/.cargo/git + target + key: ${{ runner.os }}-cargo-msrv-${{ hashFiles('**/Cargo.toml','**/Cargo.lock') }} + - name: Justfile + run: cargo install just + - name: Check + run: just check-crates-msrv + + check-docs: + name: Check docs + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v3 + - name: Cache + uses: actions/cache@v3 + with: + path: | + ~/.cargo/registry + ~/.cargo/git + target + key: ${{ runner.os }}-cargo-doc-${{ hashFiles('**/Cargo.toml','**/Cargo.lock') }} + - name: Justfile + run: cargo install just + - name: Check + run: just check-docs \ No newline at end of file