Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 40 additions & 0 deletions .github/workflows/main-ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: Main CI

on:
push:
branches: [ main ]

env:
CARGO_TERM_COLOR: always

jobs:
format:
name: Format
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with:
components: rustfmt
- name: Check formatting
run: cargo fmt --check

clippy:
name: Clippy
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with:
components: clippy
- name: Run clippy
run: cargo clippy -- -D warnings

test:
name: Test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- name: Run tests
run: cargo test --verbose
40 changes: 40 additions & 0 deletions .github/workflows/pr-ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: PR CI

on:
pull_request:
branches: [ main ]

env:
CARGO_TERM_COLOR: always

jobs:
format:
name: Format
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with:
components: rustfmt
- name: Check formatting
run: cargo fmt --check

clippy:
name: Clippy
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with:
components: clippy
- name: Run clippy
run: cargo clippy -- -D warnings

test:
name: Test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- name: Run tests
run: cargo test --verbose
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
/target
7 changes: 7 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
[package]
name = "rust-hello-world"
version = "0.1.0"
edition = "2024"

[dependencies]
40 changes: 40 additions & 0 deletions docs.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
# Noridoc: rust-hello-world

Path: @/.worktrees/rust-hello-world

### Overview

- Binary Rust package serving as a minimal "Hello World" example
- Verifies Rust toolchain installation and basic project setup (rustc 1.91.0, cargo 1.91.0)
- Uses standard Cargo project structure with src/main.rs entry point
- Edition 2024 - latest Rust edition available

### How it fits into the larger codebase

- Located in a git worktree (separate working directory) to maintain isolation from the main monorepo
- Does not affect main repository commits since .worktrees/ is gitignored at @/.gitignore
- Demonstrates the first Rust infrastructure setup for the Nori system
- Serves as a template for future Rust packages or can be replaced with actual project code
- No dependencies on other parts of the monorepo; entirely self-contained

### Core Implementation

- Entry point: src/main.rs contains a simple println!("Hello, world!") implementation
- Build configuration: Cargo.toml defines package metadata (name: rust-hello-world, version: 0.1.0, edition: 2024)
- Build output directory: target/ (gitignored via local .gitignore)
- Cargo.lock tracks dependency versions (currently no external dependencies)
- No dependencies defined, pure standard library usage

### Things to Know

- This is a binary crate (executable), not a library crate
- The gitignored .worktrees/ directory means this package does not integrate with the main repository version control
- Rust 1.91.0 is the minimum required toolchain - defined by rust-toolchain.toml if present or system default
- target/ build artifacts are local to the worktree and gitignored
- The package can be compiled with `cargo build` or run directly with `cargo run`
- CI/CD: Separate GitHub Actions workflows for different Git events:
- @/.github/workflows/pr-ci.yml runs on pull requests
- @/.github/workflows/main-ci.yml runs on pushes to main
- Both run: cargo fmt --check (formatting), cargo clippy -- -D warnings (linting), cargo test --verbose (tests)

Created and maintained by Nori.
3 changes: 3 additions & 0 deletions src/main.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
fn main() {
println!("Hello, world!");
}