Skip to content

feat(posts): allow multiple source directories #130

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

Merged
merged 19 commits into from
Apr 10, 2025

Conversation

evantravers
Copy link
Contributor

I'm pretty new to the project, so it's likely I've missed a nuance. I also haven't dev tested this against a site because I'm still messing around with porting my website over.

Happy to take all the advice and criticism that I can get to help this awesome project. I've really enjoyed reading the code.

Completes #129

I'm still currently working under the impression that we should be able
to *either* configure a folder for drafts or add `draft: true` to the
frontmatter.
This config option just represents a folder that drafts could be within.
@mhanberg
Copy link
Collaborator

mhanberg commented Apr 4, 2025

Nice work so far!

Are you familiar with running a mix package from a local path? It might be helpful to create a new tableau project and then set the tableau dependency to your local branch, so you can integration test it.

Co-authored-by: Mitchell Hanberg <[email protected]>
@evantravers
Copy link
Contributor Author

I am familiar, just need to get it working with a sample site. I'll try to stand up your blog as a test.

I noticed that we tested future in that first test case too.
I believe what is happening here is that the directory nested in
`config.dir` isn't being searched for posts?
We've decided to go a simpler direction: instead of having a bunch of
custom flags for drafts, we are just going to allow people to write
posts in other folders, and optionally pass a list of strings to
`config.dir` for when they want to show their posts.
@mhanberg
Copy link
Collaborator

mhanberg commented Apr 5, 2025

Can you mark the pull request as draft (haha, coincidence) and when you're ready for a review click "ready for review"

@evantravers evantravers marked this pull request as draft April 6, 2025 00:01
@evantravers
Copy link
Contributor Author

Sorry for the noise sir. Thank you for being patient with me.

@mhanberg
Copy link
Collaborator

mhanberg commented Apr 6, 2025

Sorry for the noise sir. Thank you for being patient with me.

No worries, I just don't want to leave comments until you're ready for them 👍

@evantravers evantravers marked this pull request as ready for review April 6, 2025 02:15
Copy link
Collaborator

@mhanberg mhanberg left a comment

Choose a reason for hiding this comment

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

PR looks great! Just a couple changes and let's merge it 💪

@mhanberg mhanberg changed the title Add draft front_matter and _drafts folder options feat(posts): allow multiple post directories Apr 10, 2025
@mhanberg
Copy link
Collaborator

The PagesExtension is very similar to the PostsExtension, and could benefit from this feature as well. If you're up to it, it would be awesome to implement that as well.

Thanks for you work on this!

@mhanberg mhanberg changed the title feat(posts): allow multiple post directories feat(posts,pages): allow multiple post directories Apr 10, 2025
@mhanberg mhanberg changed the title feat(posts,pages): allow multiple post directories feat(posts,pages): allow multiple source directories Apr 10, 2025
@evantravers evantravers requested a review from mhanberg April 10, 2025 18:32
@mhanberg mhanberg changed the title feat(posts,pages): allow multiple source directories feat(posts): allow multiple source directories Apr 10, 2025
@mhanberg mhanberg merged commit 4220c6e into elixir-tools:main Apr 10, 2025
15 checks passed
@evantravers evantravers deleted the 129-drafts branch April 10, 2025 21:46
@mhanberg mhanberg mentioned this pull request Apr 10, 2025
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