It would be nice to be able to run actions conditionally, e.g. based on user input from prompt actions or depending on the user OS (#11 probably should be closed in favor of this feature, but I'm not sure).
Example
actions {
confirm "should_commit" {
hint "Whether to stage and commit everything on finish"
default false
}
number "magic_number" {
hint "Enter magic number"
}
run when="should_commit == true && (magic_number == 42 || magic_number == 420)" r#"
git add .
git commit -S -m 'chore: init repository'
"#
}
Notes
I'll need to implement a simple expression parser (with precedence and grouping) and evaluator.
It'd be a good idea to add a distinct prompt for numbers. Done.
Description
It would be nice to be able to run actions conditionally, e.g. based on user input from prompt actions or depending on the user OS
(#11 probably should be closed in favor of this feature, but I'm not sure).Example
Notes
It'd be a good idea to add a distinct prompt for numbers.Done.