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

feat: Add a step to validate the filename #138

Merged
merged 5 commits into from
Oct 8, 2024

Conversation

benjaminParisel
Copy link
Collaborator

@benjaminParisel benjaminParisel commented Oct 3, 2024

  • check if the filename follow the convention (kebab-case)
  • suggest a new filename to resolve the issue.

Covers bonitasoft/bonita-documentation-site#589

@benjaminParisel
Copy link
Collaborator Author

Tested with bonitasoft/bonita-documentation-site#791 PR.
Publish a comment on PR with this display when the page filename step is on error.

image

Copy link
Member

@tbouffard tbouffard left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, great work! 🎉

I haven't approved the PR yet, because I'd first like to talk about the current situation:

});
commentBody += `
> [!warning]
> Additionally, don't forget to add the \`:page-aliases:\` attribute after renaming the **existing files** to avoid broken links or references. `;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion: Here the warning applies to file that previously existed prior the PR creation.
If the file is a new file created in the PR, there is no need to add an alias (and it shouldn't be added).
Let's talk in person to find a more convenient message.

@tbouffard
Copy link
Member

LGTM, great work! 🎉

I haven't approved the PR yet, because I'd first like to talk about the current situation:

* the warning message about eventual alias creation

* if we do a manual rename operations in all repositories prior merging/releasing this new feature. This is what was planned in [Tool: enforce file name to use kebab-case in documentation content bonita-documentation-site#589](https://github.com/bonitasoft/bonita-documentation-site/issues/589)

Answering to my own questions:

  • warning message: I am going to propose an alternative
  • the actions provides a way to skip the step. It is used with a reusable workflow in the documentation content repositories, so by adding a new input to the reusable workflow, it will be possible to disable the step.

@benjaminParisel benjaminParisel merged commit 9212409 into main Oct 8, 2024
1 check passed
@benjaminParisel benjaminParisel deleted the feat/check_file_name branch October 8, 2024 09:43
@tbouffard tbouffard added the enhancement New feature or request label Oct 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants