1
0
mirror of https://github.com/thebaer/squigglelog synced 2018-07-20 10:45:21 +00:00
squigglelog/README.md

44 lines
1.1 KiB
Markdown
Raw Normal View History

2015-01-28 02:35:07 +00:00
~log
====
2015-01-29 06:30:39 +00:00
Use **squigglelog** to easily create a simple log for your tilde.
1. Install squigglelog with `./install.sh`
2. [Create new posts](https://github.com/thebaer/squigglelog/tree/master/entries#squigglelog-entries) in the `entries/` folder, or use the `squiggle.sh` utility.
3. Generate your ~log:
2015-01-28 02:35:07 +00:00
```bash
2015-01-29 06:30:39 +00:00
./squigglelog -t mysquigglelog -o mylog
2015-01-28 02:35:07 +00:00
```
2015-01-29 06:30:39 +00:00
This will use any template in `templates/` defined with _mysquigglelog_ (see below) to generate your full squigglelog page in ~/public_html/ called mylog.html.
2015-01-28 02:35:07 +00:00
#### templates
Your template should look like this.
```html
{{define "mysquigglelog"}}
<html>
<head>
<title>My ~log!</title>
</head>
<body>
<h1>~log</h1>
<p>Welcome to my ~log.</p>
{{template "log" .}}
</body>
</html>
{{end}}
```
2015-01-29 06:30:39 +00:00
There are two important lines in this file
`{{define "mysquigglelog"}}`
This is what you will reference in the `-t` flag passed to the generator. The template file name does not matter.
`{{template "log" .}}`
This must be included verbatim in your template. It will include the `templates/log.html` template, which holds all the posts.