#!/bin/bash
# dev/package/symbols - package symbol introspection and management
set -e
######
# Library Settings
dev_package_symbols_config_init() {
# package file callback entrypoints
local -a entrypoint_common=( config_init config_check )
lib_setting_arrays package_entrypoint_libs package_entrypoint_tools
package_entrypoint_libs=( lib_init "${entrypoint_common[@]}" )
package_entrypoint_tools=( init "${entrypoint_common[@]}" )
}
######
# Package Symbol Commands
package_sym() { lib_cmd_dispatch package_sym "$@"; }
package_sym_usage() {
cat <<USAGE
...
Source Code Symbol Commands:
all Prints all global symbols
conf [<file>+] Prints tool/library setting symbols
vars [<file>+] Prints function symbols
funcs [<file>+] Prints function symbols
USAGE
}
######
# Package Symbol Introspection
package_sym_all() {
package_sym_vars
package_sym_funcs
package_sym_conf
}
package_sym_vars() {
package_grep '^[a-z0-9_]+=' -nE | sed -e 's,^,$,' -e 's,=.*$,,'
}
package_sym_funcs() {
package_grep '[a-z0-9_]+\(\)' -nE | sed -e 's,().*$,(),'
}
package_sym_conf() {
warn "unimplemented"
}
Generated on Tue Apr 25 21:20:44 PDT 2017 by mcsh i7 v0.18.0.