Back to writing
archived

How to Schedule a Blog Post on Hashnode

A 2020 workaround for scheduling a Hashnode post by storing content in GitHub and publishing it with a scheduled GitHub Actions workflow.

Everyone has been asking this for a very long time. In today’s blog, I will show you how you can schedule a blog to be released on hashnode.

This is not an official way.

This is going to be a step by step guide. Please follow along to make sure you don’t miss something.

Connect your GitHub repo with Hashnode

  • Go to the integrations tab on your blog’s dashboard. Hashnode GitHub integration settings

  • Now click on Connect Hashnode App on Github under Publish articles from GitHub. It will take you to the GitHub apps page where you need to press install. Configure your blog repo from where you want to publish your articles.

Installing the Hashnode GitHub app for one repository

I am only giving access to only one repo because I don’t want to expo all of the repo to hashnode. You can also choose to do the same if you don’t want to give access to all the GitHub repositories to hashnode.

Install PR Scheduler on your GitHub repository

  • PR scheduler is a Github App that allows you to schedule your PR requests to be merged at a specific date and time. To use this app you have to first connect it to your GitHub repo.

  • Go to the PR Scheduler website and click install. Then follow the instructions to connect the app. The video below shows the process.

Installing and configuring PR Scheduler

Again, I am restricting the access of this app to a single repository.

Once you have done the above two steps we are ready to schedule our PR.

Schedule the blog pull request with PR Scheduler

Pull request containing a draft Hashnode article

  • Once you have created the pull request, type @prscheduler <date-time>. For example, @prscheduler 25/10/2020T18:13:41 schedules it for 18:13:41 UTC on 25 October 2020. See the PR Scheduler documentation for more details.

PR Scheduler command added to a pull request

After this, your blog will be scheduled to be merged at the specified time. Once it gets merged, it will be visible on your hashnode blog.

Conclusion

This is a small hack put together by me to schedule my blog post. A huge thanks to hashnode team for enabling the GitHub integration for publishing the blogs. I hope they will soon support the schedule post out of the box.