Skip to content

The blog of Landon Wainwright that uses the simplegoblog package

License

Notifications You must be signed in to change notification settings

landonia/landotube

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

67 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

landotube

My blog landotube created using the simplegoblog. Deployed using Docker.

Overview

I have uploaded my blog to github as an example on how to create a blog using simplegoblog. All changes to the blog will be committed here and available for all to see.

Maturity

This is my first actual application written using the Go Language and therefore you should expect some bugs.

Installation

With a healthy Go Language installed, simply run go get github.com/landonia/landoblog

Out of Box Example

With a healthy Go Language installed, simply run go build github.com/landonia/landotube/main

Custom Example

	package main

	import (
		"fmt"
		"github.com/landonia/simplegoblog/blog"
	)

	func main() {
		blog := SimpleBlog.Create(directory)

		// If you want to overwrite the NotFound page
		blog.NotFoundPage("page.html")

		// Or
		blog.NotFoundFunction(func(){})

		// Any custom handlers
		err := blog.AddCustomHandler("/custom", func() {})
		if err != nil {
			panic(err.Error())
		}

		// Start the server
		err != blog.Start()
		if err != nil {
			panic(err.Error())
		}
	}

Future

As the blog posts are marshalled to/from json and written to disk it would make sense to add a feature that would allow you to use a json backed data store such as mongodb.

About

simplegoblog was written by Landon Wainwright | GitHub.

Follow me on Twitter @landotube! Although I don't really tweet much tbh.

About

The blog of Landon Wainwright that uses the simplegoblog package

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published