Skip to content
Closed
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
2 changes: 2 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ jobs:
- uses: actions/checkout@v4
- name: Setup Rust
uses: leynos/shared-actions/.github/actions/setup-rust@v1.1.0
- name: Show Ninja version
run: ninja --version
- name: Format
run: make check-fmt
- name: Lint
Expand Down
77 changes: 76 additions & 1 deletion Cargo.lock

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

2 changes: 2 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,8 @@ float_arithmetic = "deny"
rstest = "0.18.0"
cucumber = "0.20.0"
tokio = { version = "1", features = ["macros", "rt-multi-thread"], default-features = false }
insta = { version = "1", features = ["yaml"] }
tempfile = "3"

[[test]]
name = "cucumber"
Expand Down
10 changes: 10 additions & 0 deletions docs/netsuke-design.md
Original file line number Diff line number Diff line change
Expand Up @@ -1071,6 +1071,16 @@ representation portable.
generator reports `IrGenError::MultipleRules` when encountered.
- Duplicate output files are rejected. Attempting to define the same output
path twice results in `IrGenError::DuplicateOutput`.
- The Ninja generator sorts actions and edges before output and
deduplicates edges based on their full set of explicit outputs. Sorting uses
the joined path strings to keep ordering stable across platforms, ensuring
deterministic `build.ninja` files.
- Script actions are emitted under `/bin/sh -e -c` with each line indented so
multi-line recipes execute portably.
- Optional fields such as `description`, `depfile`, `deps`, `pool`, and
`restat` are written only when present, matching Ninja's syntax exactly.
- Integration tests snapshot the generated Ninja file with `insta` and
execute the Ninja binary to validate structure and no-op behaviour.

## Section 6: Process Management and Secure Execution

Expand Down
8 changes: 4 additions & 4 deletions docs/roadmap.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,11 +55,11 @@ compilation pipeline from parsing to execution.

- [ ] **Code Generation and Execution:**

- [ ] Implement the Ninja file synthesizer in
[src/ninja_gen.rs](src/ninja_gen.rs) to traverse the BuildGraph IR.
- [x] Implement the Ninja file synthesizer in
[src/ninja_gen.rs](src/ninja_gen.rs) to traverse the BuildGraph IR. *(done)*

- [ ] Write logic to generate Ninja rule statements from ir::Action structs
and build statements from ir::BuildEdge structs.
- [x] Write logic to generate Ninja rule statements from ir::Action structs
and build statements from ir::BuildEdge structs. *(done)*

- [ ] Implement the process management logic in `main.rs` to invoke the ninja
executable as a subprocess using `std::process::Command`.
Expand Down
1 change: 1 addition & 0 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,5 @@ pub mod cli;
pub mod hasher;
pub mod ir;
pub mod manifest;
pub mod ninja_gen;
pub mod runner;
Loading