]> git.r.bdr.sh - rbdr/blog/blame - README.md
Allow regeneration of assets
[rbdr/blog] / README.md
CommitLineData
4ae55e06 1# blog
7a5a585e 2
d92ac8cc 3Blog at unlimited.pizza -> Only 3 at a time.
7a5a585e
BB
4
5## How to install
6
7`npm install -g .` will expose the `blog` binary to your CLI.
8
9## How to add a new entry
10
11Create a directory with a `.md` markdown file, and an `/assets`
12directory with anything you want in there. This can be in any directory.
13
14```
15.
16└── this-is-an-example-post
17 ├── assets
18 │   └── example.png
19 └── this-is-an-example-post.md
20```
21
22You can add this to the blog using the following command, it will shift
23all entries and remove the oldest one if limit of posts is reached
24(defualts to 3):
25
26`blog --add path/to/blog_post`
27
28These commands will regenerate the static files. At that point you can
d92ac8cc 29preview your blog by serving the files on the `static` directory.
7a5a585e
BB
30
31If you need to make corrections use:
32
33`blog --update path/to/blog_post`
34
35This will replace the latest with the contents of the `path` without
36shifting the existing entries.
37
38`blog --publish`
39
d92ac8cc 40Will publish the blog. (Currently unsupported)
39744467
BB
41
42## How to publish
43
44At the moment, the app does not include any publishers. [surge][surge] is an easy
45way to do it, just point it to your static directory.
46
d92ac8cc
BB
47## Debugging
48
49If you want to know more about what's going on when blog generates
50data, set the environment variable `NODE_DEBUG=blog`. This will
51enable the debug messages
52
39744467
BB
53
54[surge]: https://surge.sh