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

Modify command warning #74475

Merged
merged 1 commit into from Apr 28, 2021
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.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 2 additions & 0 deletions changelogs/fragments/cmd_wording.yml
@@ -0,0 +1,2 @@
minor_changes:
- command - update the user warning message to point out command name (https://github.com/ansible/ansible/pull/74475).
4 changes: 2 additions & 2 deletions lib/ansible/modules/command.py
Expand Up @@ -232,9 +232,9 @@ def check_command(module, commandline):
command = commandline.split()[0]
command = os.path.basename(command)

disable_suffix = "If you need to use command because {mod} is insufficient you can add" \
disable_suffix = "If you need to use '{cmd}' because the {mod} module is insufficient you can add" \
" 'warn: false' to this command task or set 'command_warnings=False' in" \
" ansible.cfg to get rid of this message."
" the defaults section of ansible.cfg to get rid of this message."
substitutions = {'mod': None, 'cmd': command}

if command in arguments:
Expand Down