Skip to content

CI: When only Hugo docs change, other workflows do not need to run #6254

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

Conversation

bernhardkaindl
Copy link
Collaborator

Optional improvement for fast CI completion when only Hugo docs change on push/PRs:

When only Hugo docs change on push and PRs, other workflows can be skipped using
paths-ignore: for docs/** and .github/workflows/hugo.yml to not trigger other
workflows if only these paths change when pushing to a branch / work on a PR.

This is completely optional, but would be nice to have when only working on Hugo docs.
It does not change scheduled CI runs. It changes only on-demand push/PR workflow runs.

Signed-off-by: Bernhard Kaindl <bernhard.kaindl@cloud.com>
@bernhardkaindl bernhardkaindl force-pushed the when-only-Hugo-docs-change-full-Xapi-CI-is-not-needed branch from 7cc24ae to 3a6a64e Compare January 27, 2025 16:29
@psafont
Copy link
Member

psafont commented Jan 28, 2025

We may not want to merge this if we want the new docs to have content autogenerated from the API

@lindig
Copy link
Contributor

lindig commented Jan 28, 2025

If we have code changes that also change documentation, the code-related workflows would still trigger the CI. So I am not sure if @psafont's concern is a reason to not merge this. We also have the cron builds; so would be willing to try this

Copy link
Collaborator Author

@bernhardkaindl bernhardkaindl left a comment

Choose a reason for hiding this comment

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

We may not want to merge this if we want the new docs to have content autogenerated from the API

If we have code changes that also change documentation, the code-related workflows would still trigger the CI. So I am not sure if @psafont's concern is a reason to not merge this. We also have the cron builds; so would be willing to try this

Indeed, Christian is correct.

And actually, this PR is not about autogenerating API docs:
This would need to be done as part of .github/workflows/hugo.yml.
This this PR does not change hugo.yml at all.

This PR is about the reverse direction:

It is about that the docs do not change to code:

As docs have no effect on the code, the code CI does not need to run when only docs were changed.

@psafont psafont added this pull request to the merge queue Jan 29, 2025
Merged via the queue into xapi-project:master with commit 08f8647 Jan 29, 2025
15 checks passed
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

Successfully merging this pull request may close these issues.

5 participants