mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2024-11-19 21:41:07 +01:00
fix(pip): fix pipupall
error with freeze
format (#11280)
This commit is contained in:
parent
a7d910c3a6
commit
0066280c3e
1 changed files with 2 additions and 2 deletions
|
@ -94,12 +94,12 @@ alias pipreq="pip freeze > requirements.txt"
|
||||||
# Install packages from requirements file
|
# Install packages from requirements file
|
||||||
alias pipir="pip install -r requirements.txt"
|
alias pipir="pip install -r requirements.txt"
|
||||||
|
|
||||||
# Update all installed packages
|
# Upgrade all installed packages
|
||||||
function pipupall {
|
function pipupall {
|
||||||
# non-GNU xargs does not support nor need `--no-run-if-empty`
|
# non-GNU xargs does not support nor need `--no-run-if-empty`
|
||||||
local xargs="xargs --no-run-if-empty"
|
local xargs="xargs --no-run-if-empty"
|
||||||
xargs --version 2>/dev/null | grep -q GNU || xargs="xargs"
|
xargs --version 2>/dev/null | grep -q GNU || xargs="xargs"
|
||||||
pip list --outdated --format freeze | cut -d= -f1 | ${=xargs} pip install --upgrade
|
pip list --outdated | awk 'NR > 2 { print $1 }' | ${=xargs} pip install --upgrade
|
||||||
}
|
}
|
||||||
|
|
||||||
# Uninstalled all installed packages
|
# Uninstalled all installed packages
|
||||||
|
|
Loading…
Reference in a new issue