Generate static blog from markdown files in your git repository.
- Clone this repo
- Install dependencies
go get- Run the CLI tool
go run main.go -r <repo-url> -t <token> -o <output-dir> -n <blog-name> -th <theme-name>Example
go run main.go -r https://github.com/madeindra/markdownblog-example -o generated -n "Example Blog" -th examples
CLI Flags:
-hor--help: Show help-ror--repo: The URL of the git repository (Github only, must be a public repo if no token is provided)-tor--token: The access token for the git repository-oor--output: The output directory for the generated blog-nor--name: The name of the blog, will be used as the title of the blog-thor--theme: The name of the theme to be used for the blog (will find this in thethemesdirectory)
- Create a new folder in
themesdirectory. The name of the folder will be the name of the theme. - Inside the theme folder, create a
templatesfolder and anassetsfolder. - Create a
template.htmlfile in thetemplatesfolder. (Seethemes/examples/template.htmlfor reference) - Put all your static files (css, js, images) in the
assetsfolder.
- Generate from a Github repo (public & private)
- Generate from a Gitlab repo (public & private)
- Branch selection
- Generate from a source directory
- Add more themes