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

🧪 GitHub Action - Ensure the folder is exactly the same as the Rules URI #1322

Closed
3 tasks done
JackDevAU opened this issue Apr 29, 2024 · 2 comments
Closed
3 tasks done
Assignees

Comments

@JackDevAU
Copy link
Member

JackDevAU commented Apr 29, 2024

CC @adamcogan @Aibono1225 @drwharris @bradystroud

Hi Team,

Description

When someone creates a PR that updates a rules uri and doesn't update the folder name, NetlifyCMS editor doesn't allow the user to edit the rule. We should fix this before it goes live.

Tasks

@Aibono1225
Copy link
Member

Aibono1225 commented May 14, 2024

Update:

Add a new GitHub Action that validates the folder name vs rules uri

Created a PR for running the auto fix: SSWConsulting/SSW.Rules.Content#8540 🙂

Make a Wiki about how to construct the uri and foldername and how they need to match

There's already a wiki that mentions updating folder name when rename a rule: https://github.com/SSWConsulting/SSW.Rules.Content/wiki/How-to-Rename-Rules

@Aibono1225
Copy link
Member

Aibono1225 commented May 14, 2024

Done - Now we have a github action running on Rules.Content that will check and auto-fix folder names. 🙂

See action log: https://github.com/SSWConsulting/SSW.Rules.Content/actions/workflows/check-folder-name.yml

I tested it with a rule and the action automatically renamed the folder, and put the old folder name in the redirects 💪
Image
Figure: SSWConsulting/SSW.Rules.Content@3474d97

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants