Code for personal website
https://ekzyis.com/
i can now use ```sql or ```python and it will automatically have syntax highlighting |
||
---|---|---|
blog | ||
html | ||
nginx | ||
public | ||
raw | ||
.gitignore | ||
LICENSE | ||
Makefile | ||
README.md | ||
deploy.sh | ||
go.mod | ||
go.sum | ||
html.go | ||
markdown.go | ||
renderer.go | ||
sync-dev.sh | ||
syntax.go |
README.md
ekzyis.com
My personal website including blog.
Development
This site consists of only static HTML, CSS, JS in public/.
The files are built (or "rendered") with the golang text/template
standard package. It doesn't use html/template
since I had problems including HTML like a common header, navigation menu, footer for a reusable layout. But this shouldn't be a problem since there is no user-generated content (yet?).
To build the files, a Makefile is used.
Run make build
to create the renderer
binary.
Run make render
to render all files in public/.
Deployment is done by rendering all files in production mode and then copying them where a webserver like nginx
can serve them.
I use deploy.sh
for this.
How to create new blog post
- Create new Markdown file in blog/
- It needs to have this header:
Title: title
Date: date
ReadingTime: time
Sats: 0
Comments: comments
---
- Update
ComputeTitle
inhtml.go
(TODO: make this no longer required) - Run
make render
.
Done!