3afba86d5f94e828e210757fa2f84bde753cd952
[pb.git] / README.md
1 All you really need is just the pb file, the others are there for demonstration purposes, you can just download that file by itself if you don't want the extra garbage.
2
3 # 'Installation'
4 Before running the script, open it up and change the variables at the top of the file to your liking.
5
6 You need a couple of things to get the script:
7 - A blog index file (a page with a list of all of your posts)
8 - A rolling blog file (a feed of posts will be placed here)
9 - A rss file
10
11 In each of these files, you need to include the comments:
12 ```
13 <!-- BLOG START -->
14 <!-- BLOG END -->
15
16 ```
17
18 # Usage
19 ### n / new
20 Takes in a name for your blog post, put the name inside quotations if you want to have spaces. Also, only alphanumeric characters, underscores, dashes and spaces are allowed in the blog name (at this point).
21
22 ### p / publish
23 Publishes a draft, which means that it takes the html snippet you wrote and shoves it inside your template file.
24
25 ### d / delete
26 Deletes an already published blog post, this does not delete your draft.
27
28 ### b / backup
29 Simply copies all draft and published blog entries into the backup directory.
30
31 ### r / refresh (planned)
32 Used when you change the template file and want to keep all blog entries consistent. It deletes all html files and republishes them all.
33
34 # Configuration
35 For more fine tuned configuration, navigate to the data\_dir directory that was created (by default it's blog/) and find the templates folder.
36 These are the html snippets that get included in your index, rolling and rss files.
37 You can use certain keywords that will be substituted in:
38 - {{TITLE}} for the title of the blog post
39 - {{DATE}}
40 - {{URL}} pointing to that post
41 - {{BODY}} the html of that post