add a [-f|--force] option to remove confirmation on some commands
This commit is contained in:
parent
9eae80c002
commit
2ccd8c1b8d
|
@ -8,6 +8,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
||||||
|
|
||||||
### Added
|
### Added
|
||||||
|
|
||||||
|
* bkctld: add a [-f|--force] option to remove confirmation on some commands
|
||||||
|
|
||||||
### Changed
|
### Changed
|
||||||
|
|
||||||
* Better help message composition and formating
|
* Better help message composition and formating
|
||||||
|
|
3
bkctld
3
bkctld
|
@ -50,6 +50,9 @@ while :; do
|
||||||
show_version
|
show_version
|
||||||
exit 0
|
exit 0
|
||||||
;;
|
;;
|
||||||
|
-f|--force)
|
||||||
|
FORCE=1
|
||||||
|
;;
|
||||||
*)
|
*)
|
||||||
# Default case: If no more options then break out of the loop.
|
# Default case: If no more options then break out of the loop.
|
||||||
break
|
break
|
||||||
|
|
|
@ -27,6 +27,7 @@ LOGLEVEL="${LOGLEVEL:-6}"
|
||||||
CRITICAL="${CRITICAL:-48}"
|
CRITICAL="${CRITICAL:-48}"
|
||||||
WARNING="${WARNING:-24}"
|
WARNING="${WARNING:-24}"
|
||||||
DUC=$(command -v duc-nox || command -v duc)
|
DUC=$(command -v duc-nox || command -v duc)
|
||||||
|
FORCE=0
|
||||||
|
|
||||||
show_version() {
|
show_version() {
|
||||||
cat <<END
|
cat <<END
|
||||||
|
|
Loading…
Reference in a new issue