Update initialization logic
This commit is contained in:
parent
a45e1386d6
commit
beefd1dc57
2 changed files with 10 additions and 6 deletions
3
bash/bashrc.d/init.d/path.sh
Executable file
3
bash/bashrc.d/init.d/path.sh
Executable file
|
@ -0,0 +1,3 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
export "PATH=${PATH}:${HOME}/.local/bin:${HOME}/.local/share/flatpak/exports/bin:${HOME}/.cargo/bin"
|
|
@ -6,8 +6,14 @@ cd "${HOME:?}/.bashrc.d" || (
|
|||
exit 1
|
||||
)
|
||||
|
||||
# Initialize basic stuff
|
||||
[[ -f "init.d/path.sh" ]] && source "init.d/path.sh"
|
||||
[[ -f "init.d/variables.sh" ]] && source "init.d/variables.sh"
|
||||
[[ -f "init.d/aliases.sh" ]] && source "init.d/aliases.sh"
|
||||
[[ -f "init.d/functions.sh" ]] && source "init.d/functions.sh"
|
||||
|
||||
# Create new configuration file
|
||||
[[ ! -f "config.sh" ]] && cat << EOF >> config.sh
|
||||
[[ ! -f "config.sh" ]] && $(which cat) << EOF >> config.sh
|
||||
#!/usr/bin/env bash
|
||||
CONFIG_FLOW_CONTROL=0
|
||||
CONFIG_AUTOSAVE_HISTORY=1
|
||||
|
@ -20,11 +26,6 @@ EOF
|
|||
# Load configuration file
|
||||
source "config.sh"
|
||||
|
||||
# Initialize basic stuff
|
||||
[[ -f "init.d/variables.sh" ]] && source "init.d/variables.sh"
|
||||
[[ -f "init.d/aliases.sh" ]] && source "init.d/aliases.sh"
|
||||
[[ -f "init.d/functions.sh" ]] && source "init.d/functions.sh"
|
||||
|
||||
# Process configuration changes
|
||||
# -> Flow control
|
||||
[[ "${CONFIG_FLOW_CONTROl}" == "0" ]] && stty -ixon
|
||||
|
|
Loading…
Reference in a new issue