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

Only build preview site for iss branches #56

Open
JeremyMcCormick opened this issue May 23, 2024 · 2 comments
Open

Only build preview site for iss branches #56

JeremyMcCormick opened this issue May 23, 2024 · 2 comments
Labels
configuration and build Configuration and build

Comments

@JeremyMcCormick
Copy link
Collaborator

JeremyMcCormick commented May 23, 2024

We could establish a convention that only branches beginning with iss trigger the deployment of a branch version of the site. This would avoid clutter in the branch versions directory, especially from branches that don't actually update the site content and only change configuration or documentation.

Consequently, any changes beyond the most minor updates to the site, such as fixing spelling mistakes, should have their own issue and branch.

@JeremyMcCormick JeremyMcCormick added the configuration and build Configuration and build label May 23, 2024
@gmantele
Copy link
Member

An alternative would be to create the directory v/iss{ISSUE_NUMBER} while taking the ISSUE_NUMBER automatically from the CI, instead of relying on the branch name. But since we do not known the issue number while being in a PullRequest/Branch, maybe the best automatic choice would be: take the PullRequest number. I can fairly well imagine that sometimes, a single PullRequest may answer to closely related Issues (though it is not strictly following a Git workflow). If things are well done, the PullRequest is referring to the/all related GitHub Issues.

@JeremyMcCormick JeremyMcCormick changed the title Only build preview site for 'iss' branches Only build preview site for iss branches May 23, 2024
@JeremyMcCormick
Copy link
Collaborator Author

JeremyMcCormick commented May 23, 2024

An alternative would be to create the directory v/iss{ISSUE_NUMBER} while taking the ISSUE_NUMBER automatically from the CI, instead of relying on the branch name. But since we do not known the issue number while being in a PullRequest/Branch, maybe the best automatic choice would be: take the PullRequest number. I can fairly well imagine that sometimes, a single PullRequest may answer to closely related Issues (though it is not strictly following a Git workflow). If things are well done, the PullRequest is referring to the/all related GitHub Issues.

It seems more natural to connect the branch versions to issues in the tracker. If a PR resolves multiple issues, it should just use one of them.

I really prefer though that issues are scoped in a way that would typically connect them to a single PR, aside from small patches and fixes. Having a PR that resolves multiple issues shouldn't be the typical pattern and I would discourage it.

Plus the idea here is that some PRs for small fixes/patches don't need a site version built. So we have to filter on some part of the branch name to do this automatically.

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

No branches or pull requests

2 participants