add flags for public / private

This commit is contained in:
dusk 2025-10-08 17:57:56 +00:00
parent 0429fa636b
commit 77444bff2e
No known key found for this signature in database
3 changed files with 4 additions and 2 deletions

View file

@ -194,7 +194,7 @@ public class Context
public LookupContext LookupContextFor(SystemId systemId, bool? _hasPrivateOverride = null, bool? _hasPublicOverride = null)
{
// TODO(yusdacra): these should be passed as a parameter to this method all the way from command tree
// todo(dusk): these should be passed as a parameter ideally
bool hasPrivateOverride = _hasPrivateOverride ?? Parameters.HasFlag("private", "priv");
bool hasPublicOverride = _hasPublicOverride ?? Parameters.HasFlag("public", "pub");

View file

@ -46,6 +46,8 @@ pub fn all() -> impl Iterator<Item = Command> {
.hidden_flag(("raw", ["r"]))
.hidden_flag(("show-embed", ["se"]))
.hidden_flag(("by-id", ["id"]))
.hidden_flag(("private", ["priv"]))
.hidden_flag(("public", ["pub"]))
})
}

View file

@ -4,7 +4,7 @@ use command_parser::Tree;
use commands::COMMAND_TREE;
fn main() {
related();
parse();
}
fn related() {