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

feat: add hex publish docs github action #41

Merged
merged 1 commit into from
Nov 12, 2024
Merged

Conversation

yordis
Copy link
Member

@yordis yordis commented Oct 24, 2024

Context

This will allow us to trigger publishing docs only from the trunk branch without creating a new release

@yordis yordis force-pushed the add-hex-publish-docs branch 5 times, most recently from aed9114 to 3bad968 Compare October 24, 2024 16:21
@yordis yordis changed the title add hex publish docs feat: add hex publish docs github action Oct 24, 2024
@yordis yordis marked this pull request as ready for review October 24, 2024 16:23
@yordis yordis requested a review from a team as a code owner October 24, 2024 16:23
Comment on lines 18 to 20
- name: Verify Branch
if: github.ref != 'refs/heads/main'
run: exit 1
Copy link
Member Author

@yordis yordis Oct 24, 2024

Choose a reason for hiding this comment

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

Is this the best way to do it? Should I put this at the job level instead?

Copy link
Member

Choose a reason for hiding this comment

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

I'd put it at the job level if statement. Easier to parse

@btkostner
Copy link
Member

Don't the docs get published with mix hex.publish? That's ran for every release created. What's the use case for this? I'd imagine viewing hexdocs you'd want it to be the latest published version instead of things that are not yet released.

One other thing I've done before is have the main docs published to github pages so the "dev" docs are viewable

@yordis
Copy link
Member Author

yordis commented Nov 11, 2024

I'd imagine viewing hexdocs you'd want it to be the latest published version instead of things that are not yet released.

This would be for the lastest version that needs some docs refreshing, or adding extra guides and so on to hexdocs

Comment on lines 18 to 20
- name: Verify Branch
if: github.ref != 'refs/heads/main'
run: exit 1
Copy link
Member

Choose a reason for hiding this comment

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

I'd put it at the job level if statement. Easier to parse

group: hex-publish-docs
cancel-in-progress: true

jobs:
Copy link
Member

Choose a reason for hiding this comment

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

If it's not a mix package this will be empty and result in null which I think GHA will error out on. You'll want this to template out to jobs: {} if it's not a mix package.

@yordis
Copy link
Member Author

yordis commented Nov 12, 2024

I'd put it at the job level if statement. Easier to pars

I remember I did that initially, but I forgot why I moved to the inside 😭

@yordis yordis force-pushed the add-hex-publish-docs branch from 3bad968 to 382d5d9 Compare November 12, 2024 17:29
@yordis yordis requested a review from btkostner November 12, 2024 17:29
@yordis yordis force-pushed the add-hex-publish-docs branch from 382d5d9 to 8189599 Compare November 12, 2024 17:30
Copy link
Member

@btkostner btkostner left a comment

Choose a reason for hiding this comment

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

Should be good

@yordis yordis added this pull request to the merge queue Nov 12, 2024
Merged via the queue into main with commit 43097ee Nov 12, 2024
2 checks passed
@yordis yordis deleted the add-hex-publish-docs branch November 12, 2024 18:26
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.

2 participants