Skip to content

Latest commit

 

History

History
87 lines (61 loc) · 1.56 KB

File metadata and controls

87 lines (61 loc) · 1.56 KB

chetansachdev.com

Personal blog built with Hexo and deployed to GitHub Pages via the gh-pages branch.

Prerequisites

  • Node.js (v14+)
  • npm

Setup

npm install

Development

Start the local dev server with live reload:

npm start

The site is available at http://localhost:4000.

Creating a New Post

npm run new -- "My Post Title"

This generates source/_posts/my-post-title.md. Edit that file to add your content.

Post front matter example:

---
title: My Post Title
date: 2026-06-14 10:00:00
tags:
  - javascript
categories:
  - tech
---

Write your content in Markdown below the front matter.

Testing

Preview the site locally before deploying:

npm start

Check that:

  • New posts appear correctly
  • Images load
  • Links work

Deployment

Builds the site and deploys the public/ folder to the gh-pages branch:

npm run deploy

This runs hexo clean && hexo generate && hexo deploy under the hood, pushing to: https://github.com/cksachdev/chetansachdev.com.git → branch gh-pages

GitHub Pages then serves the site at chetansachdev.com.

Project Structure

.
├── _config.yml       # Hexo site configuration
├── package.json
├── scaffolds/        # Post/page/draft templates
├── source/
│   ├── _posts/       # Blog posts (Markdown)
│   └── _drafts/      # Unpublished drafts
├── themes/           # Active theme(s)
└── public/           # Generated output (git-ignored)