Don't create a config file in stdout mode.
This commit is contained in:
parent
155c18e2ab
commit
c87ae4bb5d
1 changed files with 5 additions and 6 deletions
11
fetch
11
fetch
|
@ -2185,9 +2185,6 @@ getconfig () {
|
|||
return
|
||||
fi
|
||||
|
||||
# Make the directory if it doesn't exist
|
||||
mkdir -p "$HOME/.config/fetch/"
|
||||
|
||||
# Check $HOME/.config/fetch and create the
|
||||
# dir/files if they don't exist.
|
||||
if [ -f "$HOME/.config/fetch/config" ]; then
|
||||
|
@ -2217,9 +2214,6 @@ case "$@" in
|
|||
;;
|
||||
esac
|
||||
|
||||
# If config files are enabled
|
||||
[ "$config" == "on" ] && getconfig
|
||||
|
||||
# }}}
|
||||
|
||||
|
||||
|
@ -2469,6 +2463,11 @@ done
|
|||
# Restore cursor and clear screen on ctrl+c
|
||||
trap 'printf "\033[?25h"; clear; exit' 2
|
||||
|
||||
if [ "$config" == "on" ]; then
|
||||
mkdir -p "$HOME/.config/fetch/"
|
||||
getconfig
|
||||
fi
|
||||
|
||||
# Get colors / bold
|
||||
colors
|
||||
bold
|
||||
|
|
Loading…
Reference in a new issue