Skip to content

Commit

Permalink
0.5
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexander Weber committed Jul 22, 2023
1 parent 47b7589 commit b6ea2bf
Show file tree
Hide file tree
Showing 13 changed files with 509 additions and 171 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/wiki.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
cargo run --target=x86_64-unknown-linux-gnu -- man -o ./markdown -f markdown
# render and include schema
cargo run --target=x86_64-unknown-linux-gnu -- config schema > ./docs/schema.json
cargo run --target=x86_64-unknown-linux-gnu -- workflow schema > ./docs/schema.json
fmerge merge -p "<-- %f -->" -f ./docs/README.md > ./docs/README_MERGED.md
mv ./docs/README_MERGED.md ./docs/README.md
Expand Down
10 changes: 6 additions & 4 deletions .neomake.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,12 @@ version: "0.5"
nodes:
build:
matrix:
- - env:
RELEASE: ""
- env:
RELEASE: "--release"
dense:
dimensions:
- - env:
RELEASE: ""
- env:
RELEASE: "--release"
tasks:
- script: |
set -e
Expand Down
64 changes: 64 additions & 0 deletions Cargo.lock

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

1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ threadpool = "^1.8"
schemars = "0.8.12"
toml = "0.7.6"
ron = "0.8.0"
fancy-regex = "0.11.0"

[dev-dependencies]
rusty-hook = "0.11.2"
46 changes: 26 additions & 20 deletions res/templates/max.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,12 @@ nodes:
args:
- -c
matrix:
- - env:
PRINT_VAL: value 0
- env:
PRINT_VAL: value 1
dense:
dimensions:
- - env:
PRINT_VAL: value 0
- env:
PRINT_VAL: value 1
tasks:
- shell:
program: python
Expand All @@ -31,20 +33,22 @@ nodes:

a:
matrix:
- - env:
VA: A0
- env:
VA: A1
- - env:
VB: B0
- env:
VB: B1
- env:
VB: B2
- - env:
VC: C0
- env:
VC: C1
dense:
dimensions:
- - env:
VA: A0
- env:
VA: A1
- - env:
VB: B0
- env:
VB: B1
- env:
VB: B2
- - env:
VC: C0
- env:
VC: C1
tasks:
- script: echo "$VA $VB $VC"
b:
Expand Down Expand Up @@ -75,8 +79,10 @@ nodes:

test:
matrix:
- - env:
OVERRIDE_ENV_VAR_0: new e0
dense:
dimensions:
- - env:
OVERRIDE_ENV_VAR_0: new e0
tasks:
- env:
OVERRIDE_ENV_VAR_1: new e1
Expand Down
18 changes: 10 additions & 8 deletions res/templates/python.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,16 @@ version: "0.5"
nodes:
count:
matrix:
- - env:
X: "0"
- env:
X: "1"
- - env:
Y: "0"
- env:
Y: "1"
dense:
dimensions:
- - env:
X: "0"
- env:
X: "1"
- - env:
Y: "0"
- env:
Y: "1"
tasks:
- shell:
program: "python3"
Expand Down
2 changes: 1 addition & 1 deletion src/args.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ use std::{

use clap::{Arg, ArgAction};

use crate::{error::Error, model::ExecutionPlan};
use crate::{error::Error, plan::ExecutionPlan};

#[derive(Debug, Eq, PartialEq)]
pub(crate) enum Privilege {
Expand Down
2 changes: 2 additions & 0 deletions src/error.rs
Original file line number Diff line number Diff line change
Expand Up @@ -41,4 +41,6 @@ pub(crate) enum Error {
DeserializeRon(#[from] ron::error::SpannedError),
#[error("handlebars")]
Handlebars(#[from] handlebars::RenderError),
#[error("regex")]
RegexError(#[from] fancy_regex::Error),
}
3 changes: 2 additions & 1 deletion src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ pub mod args;
pub mod error;
pub mod model;
pub mod output;
pub mod plan;
pub mod reference;
pub mod workflow;

Expand Down Expand Up @@ -84,7 +85,7 @@ async fn main() -> Result<(), crate::error::Error> {
format,
} => {
let m = model::Workflow::load(&workflow)?;
m.plan(&nodes, &format).await?;
m.describe(&nodes, &format).await?;
Ok(())
},
}
Expand Down
Loading

0 comments on commit b6ea2bf

Please sign in to comment.