From 20dcc4f20d8dcf5c23c390a63902e4c1f06a29bd Mon Sep 17 00:00:00 2001 From: Vasily Guzov Date: Sun, 18 Oct 2026 13:30:09 +0300 Subject: [PATCH 1/4] feat: bootstrap viexp crate with lib/bin split and sanity test (#1) --- .gitignore | 5 +++++ Cargo.lock | 7 +++++++ Cargo.toml | 7 +++++++ src/lib.rs | 11 +++++++++++ src/main.rs | 3 +++ 5 files changed, 33 insertions(+) create mode 100644 Cargo.lock create mode 100644 Cargo.toml create mode 100644 src/lib.rs create mode 100644 src/main.rs diff --git a/.gitignore b/.gitignore index 01b5136..ddca65c 100644 --- a/.gitignore +++ b/.gitignore @@ -23,3 +23,8 @@ Thumbs.db *.swp *.swo *~ + + +# Added by cargo + +/target diff --git a/Cargo.lock b/Cargo.lock new file mode 100644 index 0000000..10dfd3a --- /dev/null +++ b/Cargo.lock @@ -0,0 +1,7 @@ +# This file is automatically @generated by Cargo. +# It is not intended for manual editing. +version = 4 + +[[package]] +name = "viexp" +version = "0.1.0" diff --git a/Cargo.toml b/Cargo.toml new file mode 100644 index 0000000..10b45ca --- /dev/null +++ b/Cargo.toml @@ -0,0 +1,7 @@ +[package] +name = "viexp" +version = "0.1.0" +edition = "2024" +license = "GPL-3.0-or-later" + +[dependencies] diff --git a/src/lib.rs b/src/lib.rs new file mode 100644 index 0000000..922e893 --- /dev/null +++ b/src/lib.rs @@ -0,0 +1,11 @@ +pub fn run() { + print!("viexp {}", env!("CARGO_PKG_VERSION")); +} + +#[cfg(test)] +mod tests { + #[test] + fn sanity() { + assert_eq!(2 + 2, 4); + } +} diff --git a/src/main.rs b/src/main.rs new file mode 100644 index 0000000..5eb6057 --- /dev/null +++ b/src/main.rs @@ -0,0 +1,3 @@ +fn main() { + viexp::run() +} -- 2.52.0 From 00ef64654e5ba11900898bb497e82046c007b434 Mon Sep 17 00:00:00 2001 From: Vasily Guzov Date: Sun, 18 Oct 2026 13:41:40 +0300 Subject: [PATCH 2/4] ci: add Gitea Actions workflow with fmt, clippy and test (#2) --- .gitea/workflows/ci.yaml | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 .gitea/workflows/ci.yaml diff --git a/.gitea/workflows/ci.yaml b/.gitea/workflows/ci.yaml new file mode 100644 index 0000000..4faa1dc --- /dev/null +++ b/.gitea/workflows/ci.yaml @@ -0,0 +1,10 @@ +name: ci +on: [push] +jobs: + check: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - run: cargo fmt --check + - run: cargo clippy -- -D warnings + - run: cargo test -- 2.52.0 From c9116c17429c86d6a6b7ea1440b3cf8e855d1657 Mon Sep 17 00:00:00 2001 From: Vasily Guzov Date: Sun, 18 Oct 2026 14:05:27 +0300 Subject: [PATCH 3/4] ci: fix paypline --- .gitea/workflows/ci.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.gitea/workflows/ci.yaml b/.gitea/workflows/ci.yaml index 4faa1dc..bc1d238 100644 --- a/.gitea/workflows/ci.yaml +++ b/.gitea/workflows/ci.yaml @@ -5,6 +5,8 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 + with: + fetch-depth: 0 - run: cargo fmt --check - run: cargo clippy -- -D warnings - run: cargo test -- 2.52.0 From fd57c2556dad1a3caffeee99b3306174e006527b Mon Sep 17 00:00:00 2001 From: Vasily Guzov Date: Sun, 18 Oct 2026 17:52:04 +0300 Subject: [PATCH 4/4] ci: fix paypline --- .gitea/workflows/ci.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.gitea/workflows/ci.yaml b/.gitea/workflows/ci.yaml index bc1d238..34c984a 100644 --- a/.gitea/workflows/ci.yaml +++ b/.gitea/workflows/ci.yaml @@ -5,8 +5,9 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 + - uses: dtolnay/rust-toolchain@stable with: - fetch-depth: 0 + components: rustfmt, clippy - run: cargo fmt --check - run: cargo clippy -- -D warnings - run: cargo test -- 2.52.0