aboutsummaryrefslogtreecommitdiffstats
path: root/src/actionhelper.c
diff options
context:
space:
mode:
authorgramanas <anastasis.gramm2@gmail.com>2018-10-29 17:20:28 +0200
committergramanas <anastasis.gramm2@gmail.com>2018-10-29 17:20:28 +0200
commit5683c51d17b5eed7d2f070aa4e49cc21b65d82e5 (patch)
treef6eea31de970bf3b5233545b7296a0d81e60836e /src/actionhelper.c
parent56fdf6de6ee00f1eb4303065c26811310a7c0728 (diff)
downloadck-5683c51d17b5eed7d2f070aa4e49cc21b65d82e5.tar.gz
ck-5683c51d17b5eed7d2f070aa4e49cc21b65d82e5.tar.bz2
ck-5683c51d17b5eed7d2f070aa4e49cc21b65d82e5.zip
Add list with basename and update readme
Diffstat (limited to 'src/actionhelper.c')
-rw-r--r--src/actionhelper.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/actionhelper.c b/src/actionhelper.c
index 6428ab0..5899024 100644
--- a/src/actionhelper.c
+++ b/src/actionhelper.c
@@ -202,6 +202,7 @@ ListOpt list_make_options(cklist *args) {
._lst = LST_PLAIN,
.pName = NULL,
.attr = 0,
+ .bName = 0,
.err = 0
};
@@ -211,6 +212,10 @@ ListOpt list_make_options(cklist *args) {
listOpt.attr = 1;
continue;
}
+ if (strcmp(list_get(args), "-b") == 0) {
+ listOpt.bName = 1;
+ continue;
+ }
if (strcmp(list_get(args), "-t") == 0) {
if (!list_next(args)) {
listOpt.err = 1;
@@ -421,7 +426,8 @@ void print_LIST_help() {
ckhelp(" `-p program_name`: list only the configs of the specified program.");
ckhelp(" `ckconf`: list the ck configuration values.\n");
ckhelp("There are also some flags:");
- ckhelp(" `-a`: add the attributes next to the config paths (secret,primary)");
+ ckhelp(" `-a`: add the attributes next to the config paths (secret,primary,root)");
+ ckhelp(" `-b`: print the config basenames instead of the full path");
ckhelp(" `-t`: change the list type. (does not work with tree or ckconf)");
ckhelp(" `plain`: default plain listing");
ckhelp(" `python`: enclose the list in [ , ]");