Skip to content

Commit

Permalink
feat: init
Browse files Browse the repository at this point in the history
  • Loading branch information
matoous committed Jan 6, 2024
0 parents commit 9d6eb23
Show file tree
Hide file tree
Showing 19 changed files with 4,725 additions and 0 deletions.
30 changes: 30 additions & 0 deletions .github/workflows/actions.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: Github Actions

on:
pull_request:
paths:
- '.github/**'

defaults:
run:
working-directory: ./.github

permissions:
contents: read

jobs:
actionlint:
name: Lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
persist-credentials: false
sparse-checkout: |
.github
- uses: reviewdog/[email protected]
with:
filter_mode: nofilter
fail_on_error: true
reporter: github-pr-check
73 changes: 73 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
name: CI
on:
pull_request:
push:
branches:
- main
merge_group:

jobs:
check:
name: Check
runs-on: ubuntu-latest
steps:
- name: Checkout sources
uses: actions/checkout@v4
- name: Install stable toolchain
uses: helix-editor/rust-toolchain@v1
with:
profile: minimal
override: true

- uses: Swatinem/rust-cache@v2
with:
shared-key: "build"

- name: Run cargo check
run: cargo check

test:
name: Test Suite
runs-on: ubuntu-latest
env:
RUST_BACKTRACE: 1
steps:
- name: Checkout sources
uses: actions/checkout@v4

- name: Install stable toolchain
uses: dtolnay/[email protected]

- uses: Swatinem/rust-cache@v2
with:
shared-key: "build"

- name: Run cargo test
run: cargo test --workspace

lints:
name: Lints
runs-on: ubuntu-latest
steps:
- name: Checkout sources
uses: actions/checkout@v4

- name: Install stable toolchain
uses: dtolnay/[email protected]
with:
components: rustfmt, clippy

- uses: Swatinem/rust-cache@v2
with:
shared-key: "build"

- name: Run cargo fmt
run: cargo fmt --all --check

- name: Run cargo clippy
run: cargo clippy --workspace --all-targets -- -D warnings

- name: Run cargo doc
run: cargo doc --no-deps --workspace --document-private-items
env:
RUSTDOCFLAGS: -D warnings
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
target/
db/
index/
Loading

0 comments on commit 9d6eb23

Please sign in to comment.