Skip to content

Commit 13a5de2

Browse files
fix: move bashrc sourcing to bottom of initrc so bashrc can override initrc settings
1 parent 58f37d7 commit 13a5de2

1 file changed

Lines changed: 9 additions & 10 deletions

File tree

‎src/plugins/terminal/scripts/init-alpine.sh‎

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -231,16 +231,6 @@ _shorten_path() {
231231
232232
PROMPT_COMMAND='_PS1_PATH=$(_shorten_path); _PS1_EXIT=$?'
233233
234-
# Source user configs AFTER defaults (so user can override PROMPT_COMMAND)
235-
if [ -f "$HOME/.bashrc" ]; then
236-
source "$HOME/.bashrc"
237-
fi
238-
239-
if [ -f /etc/bash/bashrc ]; then
240-
source /etc/bash/bashrc
241-
fi
242-
243-
244234
# Display MOTD if available
245235
if [ -s /etc/acode_motd ]; then
246236
cat /etc/acode_motd
@@ -338,6 +328,15 @@ command_not_found_handle() {
338328
# Replicate behaviour of termux (non standard)
339329
alias clear='reset'
340330
331+
# Source user configs AFTER defaults (so user can override everything)
332+
if [ -f "$HOME/.bashrc" ]; then
333+
source "$HOME/.bashrc"
334+
fi
335+
336+
if [ -f /etc/bash/bashrc ]; then
337+
source /etc/bash/bashrc
338+
fi
339+
341340
EOF
342341
fi
343342

0 commit comments

Comments
 (0)