Skip to content

Commit

Permalink
Initial modules setup
Browse files Browse the repository at this point in the history
  • Loading branch information
maouw committed Oct 26, 2023
1 parent 9966d96 commit fb67e99
Show file tree
Hide file tree
Showing 9 changed files with 1,648 additions and 0 deletions.
719 changes: 719 additions & 0 deletions scripts/1-util.bash

Large diffs are not rendered by default.

43 changes: 43 additions & 0 deletions scripts/cmd_config.bash
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
# ## COMMAND: config

# help_config()
function help_config {
cat <<EOF
Show the current configuration for hyakvnc
Usage: hyakvnc config [config options...]
Description:
Show the current configuration for hyakvnc, as set in the user configuration file at ${HYAKVNC_CONFIG_FILE}, in the current environment, or the default values set by hyakvnc.
Options:
-h, --help Show this help message and exit
Examples:
# Show configuration
hyakvnc config
EOF
}

# cmd_config()
function cmd_config {
# Parse arguments:
while true; do
case "${1:-}" in
-h | --help)
help_config
return 0
;;
-*)
help log ERROR "Unknown option for config: ${1:-}\n"
return 1
;;
*)
break
;;
esac
done
export -p | sed -E 's/^declare\s+-x\s+//; /^HYAKVNC_/!d'
return 0
}

Loading

0 comments on commit fb67e99

Please sign in to comment.