-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add support for 'run outdated' and update dependencies
- Loading branch information
Showing
7 changed files
with
185 additions
and
139 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# vim: set ft=bash ts=3 sw=3 expandtab: | ||
# Show top-level dependencies with outdated constraints | ||
|
||
# See: https://github.com/python-poetry/poetry/issues/2684#issuecomment-1076560832 | ||
|
||
command_outdated() { | ||
echo "Updating dependencies with current constraints..." | ||
echo "" | ||
poetry update | ||
if [ $? != 0 ]; then | ||
echo "*** Failed to update dependencies" | ||
exit 1 | ||
fi | ||
|
||
echo "" | ||
echo "Checking for outdated constraints..." | ||
echo "" | ||
poetry show --outdated | grep --file=<(poetry show --tree | grep '^\w' | cut -d' ' -f1 | sed 's/.*/^&\\s/') | ||
if [ $? != 0 ]; then | ||
echo "*** Failed to check for outdated constraints" | ||
exit 1 | ||
fi | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
# vim: set ft=bash sw=3 ts=3 expandtab: | ||
|
||
help_outdated() { | ||
echo "- run outdated: Find top-level dependencies with outdated constraints" | ||
} | ||
|
||
task_outdated() { | ||
run_command outdated | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters