Compare commits
6 commits
87db209786
...
f1bce47ea3
| Author | SHA1 | Date | |
|---|---|---|---|
| f1bce47ea3 | |||
| b82764b518 | |||
| 7bd3610c5c | |||
| a661f047a6 | |||
| 3df3a636dd | |||
| a2f0834602 |
2 changed files with 48 additions and 3 deletions
43
.forgejo/workflows/ci.yml
Normal file
43
.forgejo/workflows/ci.yml
Normal file
|
|
@ -0,0 +1,43 @@
|
||||||
|
name: Cargo Build & Test
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- main
|
||||||
|
pull_request:
|
||||||
|
|
||||||
|
env:
|
||||||
|
CARGO_TERM_COLOR: always
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
formatting:
|
||||||
|
name: hem - Formatting
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v4
|
||||||
|
- name: Install Rust
|
||||||
|
uses: https://github.com/dtolnay/rust-toolchain@1.88
|
||||||
|
with:
|
||||||
|
components: rustfmt
|
||||||
|
- run: cargo fmt --check
|
||||||
|
build_and_test:
|
||||||
|
name: hem - Build & Test
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v4
|
||||||
|
- name: Install Rust
|
||||||
|
uses: https://github.com/dtolnay/rust-toolchain@1.88
|
||||||
|
id: toolchain
|
||||||
|
with:
|
||||||
|
components: clippy
|
||||||
|
- name: ⚡ Cache
|
||||||
|
uses: actions/cache@v2
|
||||||
|
with:
|
||||||
|
path: |
|
||||||
|
~/.cargo/registry
|
||||||
|
~/.cargo/git
|
||||||
|
target
|
||||||
|
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}-${{ steps.toolchain.outputs.cachekey }}
|
||||||
|
- run: cargo clippy --all-targets -- -D warnings
|
||||||
|
- run: cargo build --verbose
|
||||||
|
- run: cargo test --verbose
|
||||||
|
|
@ -1,3 +1,5 @@
|
||||||
|
#![expect(dead_code)]
|
||||||
|
|
||||||
use clap::Parser;
|
use clap::Parser;
|
||||||
|
|
||||||
mod cli;
|
mod cli;
|
||||||
|
|
@ -5,10 +7,10 @@ mod expr;
|
||||||
|
|
||||||
fn main() -> miette::Result<()> {
|
fn main() -> miette::Result<()> {
|
||||||
let args = cli::Args::parse();
|
let args = cli::Args::parse();
|
||||||
let input_delim = args.delimiter();
|
let _input_delim = args.delimiter();
|
||||||
let input = args.input();
|
let _input = args.input();
|
||||||
|
|
||||||
let expression = expr::parse(&args.expression)?;
|
let _expression = expr::parse(&args.expression)?;
|
||||||
|
|
||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue