Python Language Updating all outdated packages on Linux


Example

pip doesn't current contain a flag to allow a user to update all outdated packages in one shot. However, this can be accomplished by piping commands together in a Linux environment:

pip list --outdated --local | grep -v '^\-e' | cut -d = -f 1  | xargs -n1 pip install -U

This command takes all packages in the local virtualenv and checks if they are outdated. From that list, it gets the package name and then pipes that to a pip install -U command. At the end of this process, all local packages should be updated.