Post

How I set up this blog

This is a short tutorial on how I set up this blog on Github Pages with Jekyll

How I set up this blog

This blog is created with the help of Jekyll’s Chirpy theme. The contents are made using obsidian. The main tutorial this blog is referencing could be found here.

Installation

Jekyll

You could install Jekyll from this page and choose the OS that you are using.

Chripy

The chirpy theme github could be found here. The youtube tutorial above will guide you on setting up Chirpy.

Obsidian

You could download Obisdian here. After installing, I recommend watching this short tutorial to get you started on Obsidian.

Making Content

In order to make content using Obsidian and upload it to your github pages, first navigate into your github pages directory(finish the youtube tutorial first). Locate the _posts file and delete it. Create an obsidian vault in that directory with the name _posts as well.

Making a post

In order to make a post, you could refer to this blog. After reading the blog, you would notice that it could get a bit tedious and annoying if you have to go through the steps everytime you want to make a post, so I used this powershell script generated by Claude.ai to automate it:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
# Get the title from user input

$title = Read-Host "Enter the post title"

# Format the filename version of the title (replace spaces with underscores)

$fileTitle = $title -replace ' ', '_'

# Get current date and format it

$date = Get-Date

$fileDate = $date.ToString("yyyy-MM-dd")

$frontMatterDate = $date.ToString("yyyy-MM-dd HH:mm:ss +0700")

# Create filename with underscores

$fileName = "$fileDate-$fileTitle.md"

# Set the directory paths

$blogRoot = Join-Path $env:USERPROFILE "Documents\karev-tech.github.io"

$directoryPath = Join-Path $blogRoot "_posts"

# Verify paths exist

if (-not (Test-Path $blogRoot)) {

    Write-Error "Blog directory not found: $blogRoot"

    exit 1

}

  

if (-not (Test-Path $directoryPath)) {

    Write-Error "Posts directory not found: $directoryPath"

    exit 1

}
# Create the full file path

$filePath = Join-Path $directoryPath $fileName
# Create front matter content (using original title)

$content = @"

---

title: $title

date: $frontMatterDate

categories: []

tags: []     # TAG names should always be lowercase

description:

---

"@

# Create the file with the front matter

$content | Out-File -FilePath $filePath -Encoding utf8

# Output success message

Write-Host "Created new blog post: $filePath"

# Change directory to blog root

try {

    Set-Location -Path $blogRoot -ErrorAction Stop

    Write-Host "Changed directory to: $blogRoot"

} catch {

    Write-Error "Failed to change directory: $_"

}

To customize it, adjust +0700 in the frontMatterDate to your timezone, and change the blog root to your corresponding path.

That’s pretty much it! Thanks for reading this short blog. This is my first blog, and post, so any and all feedback are welcome

This post is licensed under CC BY 4.0 by the author.