Merge remote-tracking branch 'github/master'
This commit is contained in:
commit
ada00862d7
2 changed files with 6 additions and 2 deletions
|
@ -30,6 +30,10 @@ fi
|
||||||
# Don't produce "no pkgs installed" output -- breaks things
|
# Don't produce "no pkgs installed" output -- breaks things
|
||||||
PKG_OUTPUT=$(pkg_info 2>&1)
|
PKG_OUTPUT=$(pkg_info 2>&1)
|
||||||
if [ ! "$PKG_OUTPUT" = "pkg_info: no packages installed" ]; then
|
if [ ! "$PKG_OUTPUT" = "pkg_info: no packages installed" ]; then
|
||||||
echo "$(echo "$PKG_OUTPUT" | grep "^$name-" | cut '-d ' -f1 | sed "s/$name-//g")"
|
echo -n "$(echo "$PKG_OUTPUT" \
|
||||||
|
| awk '{print $1}' \
|
||||||
|
| sed 's/^\(.*\)-\([^-]*\)$/name:\1 ver:\2/g' \
|
||||||
|
| grep "name:$name ver:" \
|
||||||
|
| sed 's/^.*ver:\(.*\)/\1/g')"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
|
@ -107,7 +107,7 @@ if [ -n "$curr_version" ]; then # PKG *is* installed
|
||||||
assert "! ${version} = ${curr_version}" $LINENO
|
assert "! ${version} = ${curr_version}" $LINENO
|
||||||
cmd="${rm_cmd} ${name}-${curr_version}"
|
cmd="${rm_cmd} ${name}-${curr_version}"
|
||||||
execcmd "remove" "${cmd}"
|
execcmd "remove" "${cmd}"
|
||||||
cmd="${add_cmd} ${name}-${version}"
|
cmd="${add_cmd} -r ${name}-${version}"
|
||||||
execcmd "add" "${cmd}"
|
execcmd "add" "${cmd}"
|
||||||
fi
|
fi
|
||||||
else # Don't care what version to use
|
else # Don't care what version to use
|
||||||
|
|
Loading…
Reference in a new issue