From: Ian Jackson Date: Sat, 15 May 2021 16:30:24 +0000 (+0100) Subject: lib enquiries: Some todos X-Git-Tag: otter-0.6.0~278 X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=commitdiff_plain;h=74041cb94869ece7f19741502553036192f36989;p=otter.git lib enquiries: Some todos Signed-off-by: Ian Jackson --- diff --git a/src/bin/otter.rs b/src/bin/otter.rs index 7d58b497..9eba6f2c 100644 --- a/src/bin/otter.rs +++ b/src/bin/otter.rs @@ -984,8 +984,10 @@ impl LibGlobArgs { ap: &'_ mut ArgumentParser<'ap> ) { use argparse::*; + // xxx allow lack of library name to list library names ap.refer(&mut self.pat.lib).required() .add_argument("LIB-NAME",Store,"library name"); + // xxx allow lack of pattern to list whole library ap.refer(&mut self.pat.item).required() .add_argument("ITEM-GLOB-PATTERN",Store,"item glob pattern"); } diff --git a/src/mgmtchannel.rs b/src/mgmtchannel.rs index c5668cc1..54f55619 100644 --- a/src/mgmtchannel.rs +++ b/src/mgmtchannel.rs @@ -125,6 +125,7 @@ impl MgmtChannel { #[throws(AE)] pub fn list_items(&mut self, pat: &shapelib::ItemSpec) -> Vec { + // xxx allow globbing of library names let cmd = MgmtCommand::LibraryListByGlob { glob: pat.clone() }; let mut items = match self.cmd(&cmd)? { MgmtResponse::LibraryItems(items) => items,