-
Notifications
You must be signed in to change notification settings - Fork 554
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 workflows to track outdated terms #1360
Add workflows to track outdated terms #1360
Conversation
- Add check-outdated-terms.yaml - Add post-outdated-terms-report.yaml Signed-off-by: Yunkon Kim <hermitkim1@gmail.com>
✅ Deploy Preview for cncfglossary ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@yunkon-kim
Thank you for the contribution !!
echo "(DEBUG) Original file path: ./content/en/${FILE_NAME}" | ||
|
||
# Actually compare between the old and lastest English terms and log diff in the file | ||
git diff ${OLD_BRANCH}..${LATEST_BRANCH} -- ./content/en/${FILE_NAME} > ./outdated/${FILE_NAME} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what if there is no matched file name ?
(if the file name of source English file name has been changed?)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@seokho-son thank you for this helpful question.
Based on a list of localized files, this workflow will check if the source English is outdated or not. This workflow cannot detect changing file names.
To handle this, I could use the following command.
git diff ${OLD_BRANCH}..${LATEST_BRANCH} -- ./content/en/${FILE_NAME} > ./outdated/${FILE_NAME} | |
git diff ${OLD_BRANCH}..${LATEST_BRANCH} -- ./content/en/ > ./outdated/20221018_changes.diff |
This command will output the entire change, not individual changes. I expect a long report will be posted, and an l10n approver must review all changes and pick out the localized ones.
Although l10n approvers work increases, this seems to be the more accurate way.
Is this an appropriate answer to your question? 😃
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@yunkon-kim
I think an error handling is enough at this phase.
If there is no matched file from English source (in ./content/en/*), this workflow may report the situation as well. (e.g., "there is no matched file for /ko/xxx.md . Need to check changed or removed source file")
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@seokho-son thanks for your opinion.
I applied your opinion and made another update commit. You can see a test result: yunkon-kim/test-on-github-actions#100
Signed-off-by: Yunkon Kim <hermitkim1@gmail.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @yunkon-kim
I think this PR is ready for testing. (within Korean team only)
Thanks for your hard work!!
PTAL @jihoon-seo |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm! Thank you @yunkon-kim !
Signed-off-by: Yunkon Kim <hermitkim1@gmail.com>
Signed-off-by: Yunkon Kim <hermitkim1@gmail.com>
Signed-off-by: Yunkon Kim hermitkim1@gmail.com
Describe your changes
This PR will add 2 workflows to check outdated terms.
The check-outdated-terms workflow has the following steps:
The post-outdated-terms-report has the following steps:
dev-ko
branch.Related issue number or link (ex:
resolves #issue-number
)Checklist before opening this PR (put
x
in the checkboxes)git commit -s
) is to affirm that commits comply DCO. If you are working locally, you could add an alias to yourgitconfig
by runninggit config --global alias.ci "commit -s"
.