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

Adding unset attribute rule #729

Merged
merged 1 commit into from
Sep 13, 2024

Conversation

aireilly
Copy link
Member

@aireilly aireilly commented Mar 6, 2024

Adds a new AsciiDoc rule that highlights when an attribute is not unset in the same file.

The rule fires for an attribute that is not unset in the file.

@aireilly aireilly added the AsciiDoc Issues with the AsciiDoc rule set only label Mar 6, 2024
Copy link

github-actions bot commented Mar 6, 2024

Click here to review and test in web IDE: Contribute

Copy link

github-actions bot commented Mar 6, 2024

🎊 Navigate the preview: https://redhat-documentation-vale-at-red-hat-729.surge.sh 🎊

@aireilly aireilly force-pushed the add-check-unset-attr branch 11 times, most recently from db2c76e to 7f950ec Compare March 6, 2024 17:52
@aireilly
Copy link
Member Author

aireilly commented Mar 7, 2024

This rule does not account for specific ifeval situations.

ifeval::["{context}" == "build-strategies-docker"]
:dockerstrategy:
endif::[]

<module text>

ifeval::["{context}" == "build-strategies-docker"]
:!dockerstrategy:
endif::[]

Update the rule to respect ifeval boundaries. For example, how can we validate this? https://github.com/aireilly/openshift-docs/blob/add-symlinks-to-codeowners/modules/cco-ccoctl-configuring.adoc?plain=1

@aireilly aireilly force-pushed the add-check-unset-attr branch 2 times, most recently from 660954b to 0b7fb82 Compare April 16, 2024 12:42
@aireilly aireilly changed the title Adding unset attribute rule Adding unset attribute rules May 9, 2024
@aireilly aireilly force-pushed the add-check-unset-attr branch 5 times, most recently from b481518 to d1b0c27 Compare May 9, 2024 14:24
@aireilly
Copy link
Member Author

aireilly commented May 9, 2024

This rule does not account for specific ifeval situations.

ifeval::["{context}" == "build-strategies-docker"]
:dockerstrategy:
endif::[]

<module text>

ifeval::["{context}" == "build-strategies-docker"]
:!dockerstrategy:
endif::[]

Update the rule to respect ifeval boundaries. For example, how can we validate this? https://github.com/aireilly/openshift-docs/blob/add-symlinks-to-codeowners/modules/cco-ccoctl-configuring.adoc?plain=1

Hacked around this by just counting set and unset attributes

@aireilly aireilly force-pushed the add-check-unset-attr branch from d1b0c27 to 08d0222 Compare May 9, 2024 14:27
@jeana-redhat
Copy link
Contributor

/cc

@aireilly
Copy link
Member Author

/cc

What does this mean?

@aireilly
Copy link
Member Author

@jeana-redhat Given upcoming tooling changes, I don't think I will be able to spend more time getting this into a better state for AsciiDoc, this will have to do.

@jeana-redhat
Copy link
Contributor

/cc

What does this mean?

well, in other repos, it seems to mark you as a reviewer. I was planning to come back around on this 😅

@aireilly aireilly force-pushed the add-check-unset-attr branch from 08d0222 to 13756dd Compare September 13, 2024 09:52
@aireilly aireilly force-pushed the add-check-unset-attr branch from 13756dd to 9a00270 Compare September 13, 2024 10:02
@aireilly aireilly changed the title Adding unset attribute rules Adding unset attribute rule Sep 13, 2024
@aireilly aireilly force-pushed the add-check-unset-attr branch from 9a00270 to 620790f Compare September 13, 2024 10:06
@aireilly aireilly force-pushed the add-check-unset-attr branch from 620790f to 2b927b1 Compare September 13, 2024 10:07
@aireilly
Copy link
Member Author

Merging this since it's reasonably useful and we're moving off AsciiDoc so why not? 🤷

@aireilly aireilly merged commit 6c70712 into redhat-documentation:main Sep 13, 2024
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
AsciiDoc Issues with the AsciiDoc rule set only
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants