Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

doc: Clarify the purpose of pdm outdated and --unconstrained option #2965

Merged
merged 3 commits into from
Jun 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions news/2952.feature.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Add notifiers in CLI output when global project is being used.
1 change: 1 addition & 0 deletions news/2965.doc.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Clarify the purposes of `pdm outdated` and `--unconstrained` option.
2 changes: 1 addition & 1 deletion src/pdm/cli/commands/outdated.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ def _find_first_diff(a: str, b: str) -> int:


class Command(BaseCommand):
"""Check for outdated packages and list the latest versions."""
"""Check for outdated packages and list the latest versions on indexes."""

def add_arguments(self, parser: ArgumentParser) -> None:
parser.add_argument(
Expand Down
6 changes: 3 additions & 3 deletions src/pdm/cli/completions/pdm.fish
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ complete -c pdm -A -n '__fish_seen_subcommand_from add' -l save-minimum -d 'Save
complete -c pdm -A -n '__fish_seen_subcommand_from add' -l save-wildcard -d 'Save wildcard version specifiers'
complete -c pdm -A -n '__fish_seen_subcommand_from add' -l skip -d 'Skip some tasks and/or hooks by their comma-separated names. Can be supplied multiple times. Use ":all" to skip all hooks. Use ":pre" and ":post" to skip all pre or post hooks.'
complete -c pdm -A -n '__fish_seen_subcommand_from add' -l stable -d 'Only allow stable versions to be pinned'
complete -c pdm -A -n '__fish_seen_subcommand_from add' -l unconstrained -d 'Ignore the version constraint of packages'
complete -c pdm -A -n '__fish_seen_subcommand_from add' -l unconstrained -d 'Ignore the version constraints in pyproject.toml and overwrite with new ones from the resolution result.'
complete -c pdm -A -n '__fish_seen_subcommand_from add' -l update-all -d 'Update all dependencies and sub-dependencies'
complete -c pdm -A -n '__fish_seen_subcommand_from add' -l update-eager -d 'Try to update the packages and their dependencies recursively'
complete -c pdm -A -n '__fish_seen_subcommand_from add' -l update-reuse -d 'Reuse pinned versions already present in lock file if possible'
Expand Down Expand Up @@ -259,7 +259,7 @@ complete -c pdm -A -n '__fish_seen_subcommand_from lock' -l verbose -d 'Use `-v`
complete -c pdm -A -n '__fish_seen_subcommand_from lock' -l without -d 'Exclude groups of optional-dependencies or dev-dependencies'

# outdated
complete -c pdm -f -n '__fish_pdm_a919b69078acdf0a_complete_no_subcommand' -a outdated -d 'Check for outdated packages and list the latest versions.'
complete -c pdm -f -n '__fish_pdm_a919b69078acdf0a_complete_no_subcommand' -a outdated -d 'Check for outdated packages and list the latest versions on indexes.'
complete -c pdm -A -n '__fish_seen_subcommand_from outdated' -l global -d 'Use the global project, supply the project root with `-p` option'
complete -c pdm -A -n '__fish_seen_subcommand_from outdated' -l help -d 'Show this help message and exit.'
complete -c pdm -A -n '__fish_seen_subcommand_from outdated' -l json -d 'Output in JSON format'
Expand Down Expand Up @@ -518,7 +518,7 @@ complete -c pdm -A -n '__fish_seen_subcommand_from update' -l save-wildcard -d '
complete -c pdm -A -n '__fish_seen_subcommand_from update' -l skip -d 'Skip some tasks and/or hooks by their comma-separated names. Can be supplied multiple times. Use ":all" to skip all hooks. Use ":pre" and ":post" to skip all pre or post hooks.'
complete -c pdm -A -n '__fish_seen_subcommand_from update' -l stable -d 'Only allow stable versions to be pinned'
complete -c pdm -A -n '__fish_seen_subcommand_from update' -l top -d 'Only update those listed in pyproject.toml'
complete -c pdm -A -n '__fish_seen_subcommand_from update' -l unconstrained -d 'Ignore the version constraint of packages'
complete -c pdm -A -n '__fish_seen_subcommand_from update' -l unconstrained -d 'Ignore the version constraints in pyproject.toml and overwrite with new ones from the resolution result.'
complete -c pdm -A -n '__fish_seen_subcommand_from update' -l update-all -d 'Update all dependencies and sub-dependencies'
complete -c pdm -A -n '__fish_seen_subcommand_from update' -l update-eager -d 'Try to update the packages and their dependencies recursively'
complete -c pdm -A -n '__fish_seen_subcommand_from update' -l update-reuse -d 'Reuse pinned versions already present in lock file if possible'
Expand Down
6 changes: 3 additions & 3 deletions src/pdm/cli/completions/pdm.zsh
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ _pdm() {
'list:List packages installed in the current working set'
'lock:Resolve and lock dependencies'
'self:Manage the PDM program itself (previously known as plugin)'
'outdated:Check for outdated packages and list the latest versions'
'outdated:Check for outdated packages and list the latest versions on indexes'
'publish:Build and publish the project to PyPI'
'python:Manage installed Python interpreters'
'py:Manage installed Python interpreters'
Expand Down Expand Up @@ -82,7 +82,7 @@ _pdm() {
"--frozen-lockfile[Don't try to create or update the lockfile. \[env var: PDM_FROZEN_LOCKFILE\]]"
'--venv[Run the command in the virtual environment with the given key. \[env var: PDM_IN_VENV\]]:venv:'
{-k,--skip}'[Skip some tasks and/or hooks by their comma-separated names]'
{-u,--unconstrained}'[Ignore the version constraint of packages]'
{-u,--unconstrained}'[Ignore the version constraints in pyproject.toml and overwrite with new ones from the resolution result]'
{--pre,--prerelease}'[Allow prereleases to be pinned]'
"--stable[Only allow stable versions to be pinned]"
{-e+,--editable+}'[Specify editable packages]:packages'
Expand Down Expand Up @@ -473,7 +473,7 @@ _pdm() {
"--no-sync[Only update lock file but do not sync packages]"
"--frozen-lockfile[Don't try to create or update the lockfile. \[env var: PDM_FROZEN_LOCKFILE\]]"
{-k,--skip}'[Skip some tasks and/or hooks by their comma-separated names]'
{-u,--unconstrained}'[Ignore the version constraint of packages]'
{-u,--unconstrained}'[Ignore the version constraints in pyproject.toml and overwrite with new ones from the resolution result]'
{--pre,--prerelease}'[Allow prereleases to be pinned]'
"--stable[Only allow stable versions to be pinned]"
{-d,--dev}'[Select dev dependencies]'
Expand Down
2 changes: 1 addition & 1 deletion src/pdm/cli/options.py
Original file line number Diff line number Diff line change
Expand Up @@ -430,7 +430,7 @@ def ignore_python_option(
"--unconstrained",
action="store_true",
default=False,
help="Ignore the version constraint of packages",
help="Ignore the version constraints in pyproject.toml and overwrite with new ones from the resolution result",
)


Expand Down
Loading