From fe510b0705a5b4e3740da9daed918f16a87e68ce Mon Sep 17 00:00:00 2001 From: John Jago Date: Mon, 8 Mar 2021 11:39:32 -0600 Subject: [PATCH] docs: update README with more details --- CHANGELOG.md | 14 ++++++------ README.md | 61 +++++++++++++++++++++++++++++++++++++++++----------- blognow.go | 4 +--- 3 files changed, 56 insertions(+), 23 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 87e1749..4769df1 100755 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,8 +1,12 @@ # Changelog -## [Unreleased] +## 0.3.0 (2021-03-08) -## [0.2.0] (2019-08-03) +#### Changed +- Upgrade to Water.css 2 with dark theme support +- Upgrade to Go modules + +## 0.2.0 (2019-08-03) ### Added - CSS styles via Water.css @@ -14,7 +18,7 @@ ### Fixed - Posts on archive page are sorted by date, newest on top -## [0.1.0] (2019-07-21) +## 0.1.0 (2019-07-21) ### Added - Create a new blog with the `blognow [name]` command @@ -22,7 +26,3 @@ - Blog title and tagline - Single post page - Archive page to view all posts - -[Unreleased]: https://github.com/johnjago/blognow/compare/0.2.0...HEAD -[0.2.0]: https://github.com/johnjago/blognow/releases/tag/0.2.0 -[0.1.0]: https://github.com/johnjago/blognow/releases/tag/0.1.0 diff --git a/README.md b/README.md index fdba2c0..33daad1 100644 --- a/README.md +++ b/README.md @@ -1,21 +1,49 @@ # Blognow ![Build status](https://travis-ci.org/johnjago/blognow.svg?branch=master) [![Go Report Card](https://goreportcard.com/badge/github.com/johnjago/blognow)](https://goreportcard.com/report/github.com/johnjago/blognow) -Blognow is a static site generator for blogs. There is no configuration, -confusing theme files, or complex hierarchies of pages and posts. It uses an -opinionated design that is optimized for reading, with particular attention -to typography. +Blognow is a static site generator for blogs. -The screenshots below do not reflect the final design. As of now, it's more -of a placeholder. +There is no configuration, confusing theme files, or complex hierarchies of +pages and posts. It uses an opinionated, straightforward design courtesy of +[Water.css](https://github.com/kognise/water.css). -Blognow is in **alpha** and should not be used in production. It's changing a -lot right now as I work to design a great workflow for writing and publishing -to a static site. +## Build -## Proposed usage +To build the binary, run + +```sh +go build . +``` + +You should then have the binary `blognow` in the same directory as the project. +The path to the binary can then be added to the PATH for easy usage no matter +where you are. + +## Usage `blognow my-blog` creates a new blog in the directory my-blog. +You'll see a few directories inside: + +- **posts** is where you write posts as .md files +- **templates** are the HTML templates (you shouldn't need to modify anything here) +- **config.toml** is a configuration file, ready to go. It really is no configuration, + but you may want to change the name of the blog. + +### config.toml + +A default config file is automatically created when you make a new blog. + +``` +baseURL = "https://example.org/" +title = "My Blog" +tagline = "Don't sail too close to the wind" +dateFormat = "2 January 2006" +``` + +There is no configuration apart from the four lines you see here. + +### Generating the blog + `blognow` generates a static site in dist/. You can copy these files to any place where you can host static websites. It looks in the posts/ directory and formats any correctly structured .md file as HTML. @@ -23,7 +51,7 @@ and formats any correctly structured .md file as HTML. It creates an index page (the latest post), individual post pages, and an archive page. -The format for a post is: +### Post format ``` --- @@ -59,10 +87,17 @@ $ http-server dist/ ![](img/archive-page.png) +### Dark theme + +If the computer is set to use a dark theme, a dark theme will automatically +be applied. + +![](img/dark.png) + ## Contribute -Blognow is currently under development and is not stable. If you would like to -report an issue or suggest a feature, check out the GitHub issues. +Blognow is currently under development. If you would like to report an issue or +suggest a feature, please do so! Pull requests are welcome! diff --git a/blognow.go b/blognow.go index 40fe713..6af92d2 100644 --- a/blognow.go +++ b/blognow.go @@ -1,6 +1,4 @@ -/* -This is the CLI for Blognow. -*/ +// blognow is a CLI application for generating static blogs. package main import (