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

Add (more) explicit references to Jinja2 docs in conditionals doc #61814

Open
wants to merge 1 commit into
base: devel
from

Conversation

@croesnick
Copy link

commented Sep 4, 2019

Resolves: #61758

SUMMARY

The current documentation of conditionals and how to built them up from the basic blocks came with a prepended note referring to the Jinja2 documentation. This could be easily overlooked when diving directly into the examples of conditionals. To this end, I reorganised the initial part of the section on when a bit to emphasise that the actual functionality of comparisions, tests, filters and such come from Jinja2, hence being a logical reference point once building up own expressions for conditionals.

ISSUE TYPE

Docs Pull Request

COMPONENT NAME

=docs/docsite/rst/user_guide/playbooks_conditionals.rst

ADDITIONAL INFORMATION

None

@ansibot

This comment has been minimized.

Copy link
Contributor

commented Sep 4, 2019

@samdoran

This comment has been minimized.

Copy link
Member

commented Sep 12, 2019

I will just second the idea that this is documented in the Jinja docs. I'm not sure duplicating that information in our docs is constructive.

@sivel sivel removed the needs_triage label Sep 12, 2019

@samccann

This comment has been minimized.

Copy link
Contributor

commented Sep 13, 2019

Hmm... I'm not seeing duplicated information in this PR really. What I see is three more links back to the jinja2 docs (hotlinks for specific functionality). The rest is just text cleanup (and looks on the surface to be an improvement).

Two high level comments to start:

  • Are we opposed to adding extra hotlinks back to the jinja2 docs? My personal preference is that we don't add the extra links because we don't control that website and will not know if the link locations change. That's just the general techwriter fear there, so take w/ a grain of salt.

  • Moving the initial jinja2 link suggests only the 'when' statement supports it. So that link should return to where it was.

My suggestion would be to move the improved Jinja2 documentation note back to where the original was (above the when statement section), and keep the text changes in this PR because they seem to clean things up abit, that would be an improvement. I'm open to being convinced the other hotlinks are worth keeping as well if others feel strongly about that.

@ansibot ansibot added the stale_ci label Sep 13, 2019


tasks:
- name: "shut down CentOS 6 and Debian 7 systems"
command: /sbin/shutdown -t now
when: (ansible_facts['distribution'] == "CentOS" and ansible_facts['distribution_major_version'] == "6") or
(ansible_facts['distribution'] == "Debian" and ansible_facts['distribution_major_version'] == "7")

Multiple conditions that all need to be true (a logical 'and') can also be specified as a list::
Multiple conditions that all need to be true (i.e., a logical ``and``) can also be specified as a list::

This comment has been minimized.

Copy link
@samdoran

samdoran Sep 13, 2019

Member

We working to remove uses of i.e. from the docs (#62224)

Suggested change
Multiple conditions that all need to be true (i.e., a logical ``and``) can also be specified as a list::
Multiple conditions that all need to be true (such as a logical ``and``) can also be specified as a list::
@samdoran

This comment has been minimized.

Copy link
Member

commented Sep 13, 2019

Hmm, I think I misinterpreted this PR and didn't look at it carefully enough. It looks like it's just linking to the Jinja docs more, which is a good thing. Sorry for the confusion.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
5 participants
You can’t perform that action at this time.