Skip to content

Commit

Permalink
Use pacman-conf instead of sed
Browse files Browse the repository at this point in the history
Tested for the two places we call this that it provides the exact same
output on my system.

Closes #171.
  • Loading branch information
pbrisbin committed Oct 22, 2024
1 parent cd6859f commit 7411a49
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion bin/downgrade
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,9 @@ sed_msg() {
fi
}

read_pacman_conf() { sed '/^#\?'"$1"' *= *\(.*\)$/!d; s//\1/' "$PACMAN_CONF"; }
read_pacman_conf() {
pacman-conf --config "$PACMAN_CONF" "$1"
}

read_downgrade_conf() {
local var=$1
Expand Down

0 comments on commit 7411a49

Please sign in to comment.