tag-app-delivery
tag-app-delivery copied to clipboard
Introduce a GitHub Action That Sends a Message to a PR to Notify i18n Tasks.
This PR adds a GitHub Action that sends a message to a PR to notify i18n tasks following the discussion in https://github.com/cncf/tag-app-delivery/issues/537 .
Background
Currently, when adding English content (files under website/content/en/), we place a copy in the corresponding directories of other languages. This approach ensures that if there is no translated version available when browsing in different languages, the English content is displayed. Additionally, when updates are made, the same changes need to be applied to the corresponding files in other languages.
Our website's i18n support is relatively new, so this task is often overlooked. To prevent such oversights, This PR introduces a GitHub Action that would serve as a reminder.
To reviewers
At the time of opening this PR, the GitHub Action implementation is still in draft, but I would appreciate your feedback on the following points:
- It detects changes under
website/content/en
and the targets of symbolic links; is there any other area that should be covered? - Is the content of the message appropriate?
Related Issues and PRs
- https://github.com/cncf/tag-app-delivery/issues/537
- https://github.com/cncf/tag-app-delivery/pull/545
- https://github.com/cncf/tag-app-delivery/pull/571
Deploy Preview for tag-app-delivery canceled.
Name | Link |
---|---|
Latest commit | c51c42cc528828ce8ab6dd297e8614e3965d5f66 |
Latest deploy log | https://app.netlify.com/sites/tag-app-delivery/deploys/65fb07adfc25e0000856b035 |
The GitHub Action appears to be non-functional, possibly because this PR was created from a forked repository.
I will do a demo on this PR once the problem is resolved. Please wait! 🙏
The problem has been resolved...! But, I cannot demonstrate it on this PR for some reason (*). I have run the same thing here, so please take a look at that.
*) I've made the GitHub Action is triggered by
on.pull_request_target
. it is necessary to grant GitHub Action the permission to post messages when a PR is created from a fork.
- https://github.com/thollander/actions-comment-pull-request?tab=readme-ov-file#permissions
Additionally,
on.pull_request_target
causes the GitHub Action to run within the context of the base branch. And there are no GitHub Action files in the base branch. For this reason, I was unable to demonstrate it on this PR.
@hhiroshell are you able to demonstrate the working Action on your own repo or in some other way?
@lianmakesthings I've demonstrated it in my own repository. please take a look below. https://github.com/hhiroshell/tag-app-delivery/pull/5
Thanks @hhiroshell, great work! 👏