moved load_conf top of files
This commit is contained in:
@@ -34,6 +34,8 @@
|
||||
# * OF SUCH DAMAGE.
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
load_conf "compress"
|
||||
|
||||
# ------------------------------------------------------------------------------
|
||||
# Smartly uncompress archives
|
||||
# Usage: utaz [option] [directorie(s)|file(s)]
|
||||
@@ -839,6 +841,4 @@ export -f taz
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
|
||||
load_conf "compress"
|
||||
|
||||
# EOF
|
||||
|
||||
@@ -34,6 +34,8 @@
|
||||
# * OF SUCH DAMAGE.
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
load_conf disp
|
||||
|
||||
# ------------------------------------------------------------------------------
|
||||
# Color definitions
|
||||
set_colors()
|
||||
@@ -715,8 +717,7 @@ export -f mdcat
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
|
||||
# Load disp section variables
|
||||
load_conf disp
|
||||
# Load color codes
|
||||
set_colors
|
||||
|
||||
# EOF
|
||||
|
||||
@@ -34,6 +34,8 @@
|
||||
# * OF SUCH DAMAGE.
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
load_conf "filefct"
|
||||
|
||||
# ------------------------------------------------------------------------------
|
||||
# Expand wildcards in a file/directory list and quote the results
|
||||
# Usage: expandlist [options] <item1 [item2 ... itemN]>
|
||||
@@ -866,6 +868,4 @@ export -f finddead
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
|
||||
load_conf "filefct"
|
||||
|
||||
# EOF
|
||||
|
||||
@@ -34,6 +34,8 @@
|
||||
# * OF SUCH DAMAGE.
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
load_conf "fun"
|
||||
|
||||
# ------------------------------------------------------------------------------
|
||||
# Make non-IT peoples think you're busy doing something hard
|
||||
# Usage: busy [options] [pattern]
|
||||
@@ -485,6 +487,4 @@ export -f hack
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
|
||||
load_conf "fun"
|
||||
|
||||
# EOF
|
||||
|
||||
@@ -34,8 +34,9 @@
|
||||
# * OF SUCH DAMAGE.
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
# ------------------------------------------------------------------------------
|
||||
load_conf git
|
||||
|
||||
# ------------------------------------------------------------------------------
|
||||
# Built-in defaults (can be overridden from [git] section in profile.conf)
|
||||
: "${GIT_MAIN_BRANCH:=main}"
|
||||
: "${GIT_DEFAULT_REMOTE:=origin}"
|
||||
@@ -651,6 +652,4 @@ export -f groot
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
|
||||
load_conf git
|
||||
|
||||
# EOF
|
||||
|
||||
@@ -34,6 +34,8 @@
|
||||
# * OF SUCH DAMAGE.
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
load_conf info
|
||||
|
||||
# ------------------------------------------------------------------------------
|
||||
# Show profile version
|
||||
# Usage: ver
|
||||
@@ -408,5 +410,4 @@ export -f showinfo
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
|
||||
load_conf info
|
||||
# EOF
|
||||
|
||||
@@ -34,6 +34,10 @@
|
||||
# * OF SUCH DAMAGE.
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
load_conf lang
|
||||
|
||||
# ------------------------------------------------------------------------------
|
||||
# check if a given locale is installed on the system
|
||||
locale_check()
|
||||
{
|
||||
locale -a | grep -qx "$1" || {
|
||||
@@ -42,6 +46,7 @@ locale_check()
|
||||
}
|
||||
return 0
|
||||
}
|
||||
export -f locale_check
|
||||
|
||||
|
||||
# ------------------------------------------------------------------------------
|
||||
@@ -172,11 +177,10 @@ build_locale_shortcuts()
|
||||
|
||||
unset cfg item alias loc fname locale_items
|
||||
}
|
||||
export -f build_locale_shortcuts
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
|
||||
load_conf lang
|
||||
# Dynamically build locale functions based on SET_LOCALE configuration
|
||||
build_locale_shortcuts
|
||||
|
||||
# ------------------------------------------------------------------------------
|
||||
# EOF
|
||||
|
||||
@@ -34,6 +34,8 @@
|
||||
# * OF SUCH DAMAGE.
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
load_conf "net"
|
||||
|
||||
# ------------------------------------------------------------------------------
|
||||
# Download a resource using curl, wget, or fetch.
|
||||
# Usage: dwl [-t <seconds>] [-r|--resume] <url> [output_file]
|
||||
@@ -370,9 +372,4 @@ export -f myextip
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
|
||||
# ------------------------------------------------------------------------------
|
||||
# EOF
|
||||
|
||||
load_conf "net"
|
||||
|
||||
# EOF
|
||||
|
||||
@@ -34,6 +34,9 @@
|
||||
# * OF SUCH DAMAGE.
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
load_conf "packages"
|
||||
|
||||
|
||||
# ------------------------------------------------------------------------------
|
||||
# Detect the active package manager of the current distribution.
|
||||
# Detection is based on /etc/os-release (ID / ID_LIKE), then falls back to
|
||||
@@ -272,6 +275,4 @@ export -f pkgf
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
|
||||
load_conf "packages"
|
||||
|
||||
# EOF
|
||||
|
||||
@@ -34,6 +34,9 @@
|
||||
# * OF SUCH DAMAGE.
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
load_conf "processes"
|
||||
|
||||
|
||||
# ------------------------------------------------------------------------------
|
||||
# Search processes matching the given string
|
||||
# Usage: ppg <string>
|
||||
@@ -515,7 +518,5 @@ export -f kt
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
|
||||
load_conf "processes"
|
||||
|
||||
# EOF
|
||||
|
||||
|
||||
@@ -34,6 +34,7 @@
|
||||
# * OF SUCH DAMAGE.
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
load_conf "prompt"
|
||||
|
||||
# ------------------------------------------------------------------------------
|
||||
# Parse a prompt theme file safely — it is NEVER sourced or executed.
|
||||
@@ -599,8 +600,6 @@ _pt_theme="${CONF_prompt[PROMPT_THEME]:-}"
|
||||
_pt_dir="${CONF_prompt[PROMPT_THEME_DIR]:-}"
|
||||
[[ -n "$_pt_theme" ]] && load_theme "$_pt_theme" ${_pt_dir:+"$_pt_dir"}
|
||||
unset _pt_theme _pt_dir
|
||||
|
||||
load_conf "prompt"
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
|
||||
|
||||
@@ -34,6 +34,8 @@
|
||||
# * OF SUCH DAMAGE.
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
load_conf "pwd"
|
||||
|
||||
# ------------------------------------------------------------------------------
|
||||
# genpwd : generate a password with different criteria
|
||||
# Usage: genpwd [options] [--extracars=<cars>] [--length=<n>] [nb_passwd]
|
||||
@@ -478,6 +480,4 @@ export -f pwdscore
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
|
||||
load_conf "pwd"
|
||||
|
||||
# EOF
|
||||
|
||||
@@ -34,6 +34,8 @@
|
||||
# * OF SUCH DAMAGE.
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
load_conf "rain"
|
||||
|
||||
# ------------------------------------------------------------------------------
|
||||
# Generic rain-like engine and presets
|
||||
|
||||
@@ -703,6 +705,4 @@ rainbow()
|
||||
export -f rainbow
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
load_conf "rain"
|
||||
|
||||
# EOF
|
||||
|
||||
@@ -34,6 +34,8 @@
|
||||
# * OF SUCH DAMAGE.
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
load_conf "ssh"
|
||||
|
||||
# ------------------------------------------------------------------------------
|
||||
# Remove host entries (name and IP) from ~/.ssh/known_hosts for the active user
|
||||
# Usage: rmhost <hostname|ip> [hostname2|ip2 [...]]
|
||||
@@ -249,6 +251,4 @@ export -f ssr
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
|
||||
load_conf "ssh"
|
||||
|
||||
# EOF
|
||||
|
||||
Reference in New Issue
Block a user