diff options
author | Matthias Schiffer <mschiffer@universe-factory.net> | 2024-04-17 22:38:03 +0200 |
---|---|---|
committer | Matthias Schiffer <mschiffer@universe-factory.net> | 2024-04-20 14:38:17 +0200 |
commit | 35e68444dd5e9d3d5fc39409c48be6eb3fa05e07 (patch) | |
tree | 34401e1ea5b25b71d8a78304386fd46c8c5c48d5 | |
parent | 44bc19c60edb90edce5d37bd08c04ad6cfbf7c23 (diff) | |
download | rebel-35e68444dd5e9d3d5fc39409c48be6eb3fa05e07.tar rebel-35e68444dd5e9d3d5fc39409c48be6eb3fa05e07.zip |
Replace recipe separator with ::
Make the single : usable for other syntax in the recipe language.
-rw-r--r-- | crates/common/src/types.rs | 2 | ||||
-rw-r--r-- | crates/driver/src/context.rs | 2 | ||||
-rw-r--r-- | crates/driver/src/parse.rs | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/crates/common/src/types.rs b/crates/common/src/types.rs index a5d6678..2a06275 100644 --- a/crates/common/src/types.rs +++ b/crates/common/src/types.rs @@ -15,7 +15,7 @@ pub struct TaskID { impl Display for TaskID { fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { - write!(f, "{}:{}", self.recipe, self.task) + write!(f, "{}::{}", self.recipe, self.task) } } diff --git a/crates/driver/src/context.rs b/crates/driver/src/context.rs index 3bf4bf5..be98813 100644 --- a/crates/driver/src/context.rs +++ b/crates/driver/src/context.rs @@ -92,7 +92,7 @@ impl<'ctx> Display for TaskRef<'ctx> { if let Some(version) = version_arg { write!(f, "#{}", version)?; } - write!(f, ":{}", self.id.task)?; + write!(f, "::{}", self.id.task)?; if host_arg.is_some() || target_arg.is_some() { write!(f, "@")?; diff --git a/crates/driver/src/parse.rs b/crates/driver/src/parse.rs index da85c99..5857efb 100644 --- a/crates/driver/src/parse.rs +++ b/crates/driver/src/parse.rs @@ -36,7 +36,7 @@ peg::parser! { = $(name() ("/" name())?) rule task_id() -> TaskID<'input> - = recipe:recipe_id() ":" task:name() { + = recipe:recipe_id() "::" task:name() { TaskID { recipe, task } } |