A little confused: How do you use feature branches for draft posts if your posts are in a CMS API, not the repo?
Do you make a branch where the only difference is that it fetches and renders "draft" posts in addition to "published"?
Yeah, that's a great question! So while I do like using a CMS to keep my content online, I like the idea of keeping a copy of my actual blog content in the repo, so future migrations aren't a total headache. My (somewhat convoluted) workflow is currently as follows:
I author the post in my repo locally using typora. These posts go in the /src/posts/drafts folder in the repo, and are generally added to source control by way of a PR from a branch with a name like draft/post-name.
Once the post is ready to go, I create a header image using SketchApp
I make the post public by publishing it via TakeShape
I then cross-post to dev.to by starting a new post from the markdown in my repo, and uploading any missing images, and setting the canonical_url to my own blog
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
A little confused: How do you use feature branches for draft posts if your posts are in a CMS API, not the repo?
Do you make a branch where the only difference is that it fetches and renders "draft" posts in addition to "published"?
Yeah, that's a great question! So while I do like using a CMS to keep my content online, I like the idea of keeping a copy of my actual blog content in the repo, so future migrations aren't a total headache. My (somewhat convoluted) workflow is currently as follows:
I author the post in my repo locally using typora. These posts go in the /src/posts/drafts folder in the repo, and are generally added to source control by way of a PR from a branch with a name like
draft/post-name
.Once the post is ready to go, I create a header image using SketchApp
I make the post public by publishing it via TakeShape
I then cross-post to dev.to by starting a new post from the markdown in my repo, and uploading any missing images, and setting the
canonical_url
to my own blog