Merge pull request #146 into master

fd23a93 container: src: lib_edit: add 'subscript' to case (Aaron Fiore)
This commit was merged in pull request #146.
This commit is contained in:
2024-09-24 18:30:35 -07:00

View File

@@ -59,7 +59,7 @@ function lib_edit::__parse_args()
Configuration type:
type${global_arg_delim_2}<fetch|hledger|iadd|manual|meta|shell|rules|preprocess>
type${global_arg_delim_2}<fetch|hledger|iadd|manual|meta|{shell|subscript}|rules|preprocess>
Account:
@@ -73,8 +73,8 @@ function lib_edit::__parse_args()
\e[37;2m# Edit hledger configuration\e[0m
$ $global_usage type${global_arg_delim_2}hledger
\e[37;2m# Edit meta and subprofile configurations\e[0m
$ $global_usage type${global_arg_delim_2}meta${global_arg_delim_3}shell
\e[37;2m# Edit meta and subscript files\e[0m
$ $global_usage type${global_arg_delim_2}meta${global_arg_delim_3}subscript
\e[37;2m# Edit _manual_ journal for year 2023\e[0m
$ $global_usage type${global_arg_delim_2}manual year=2023
@@ -160,7 +160,7 @@ function lib_edit::__parse_args()
read -ra _read <<<"$_arg_type"
for _type in "${_read[@]}"; do
if [[ ! "$_type" =~ ^fetch$|^hledger$|^iadd$|^manual$|^meta$|^preprocess$|^rules$|^shell$ ]]; then
if [[ ! "$_type" =~ ^fetch$|^hledger$|^iadd$|^manual$|^meta$|^preprocess$|^rules$|^shell$|^subscript$ ]]; then
lib_utils::die_usage "$_usage"
fi
if [[ ! -z "$_arg_account" ]]; then
@@ -323,7 +323,7 @@ function lib_edit::__edit()
# Execute
$EDITOR "${_paths[@]}" || lib_utils::die_fatal
;;
shell)
shell | subscript)
[ -z "$global_conf_subscript" ] && lib_utils::die_fatal
local _dir