glow/README.md

61 lines
1.1 KiB
Markdown
Raw Normal View History

2019-11-15 18:27:41 +00:00
# Gold
2019-11-09 22:12:54 +00:00
Render markdown on the CLI, with _pizzazz_!
## Usage
2019-12-13 02:25:02 +00:00
Use a markdown source as the primary argument:
2019-11-09 22:12:54 +00:00
2019-11-22 03:51:44 +00:00
Read from file:
2019-11-09 22:12:54 +00:00
```
2019-11-26 20:03:46 +00:00
./gold README.md
2019-11-09 22:12:54 +00:00
```
2019-11-22 03:51:44 +00:00
Read from stdin:
```
2019-11-26 20:03:46 +00:00
./gold -
2019-11-22 03:51:44 +00:00
```
Fetch README from GitHub:
```
2019-11-26 20:03:46 +00:00
./gold github.com/charmbracelet/gold
2019-11-25 04:03:26 +00:00
```
Fetch markdown from an HTTP source:
```
2019-11-26 20:03:46 +00:00
./gold https://host.tld/file.md
2019-11-22 03:51:44 +00:00
```
2019-11-26 20:03:46 +00:00
When `gold` is started without any markdown source, it will try to find a
`README.md` or `README` file in the current working directory.
### Word Wrapping
2019-12-13 02:25:02 +00:00
The `-w` flag lets you set a maximum width, at which the output will be wrapped:
```
./gold -w 60
```
### Styles
2019-12-13 02:25:02 +00:00
You can choose a style with the `-s` flag (`dark` being the default):
```
./gold -s [dark|light]
```
Alternatively you can also supply a custom JSON stylesheet:
2019-11-26 20:03:46 +00:00
```
./gold -s mystyle.json
```
Check out the [Gold Style Gallery](https://github.com/charmbracelet/gold/blob/master/styles/gallery/README.md)
to find more available styles!
2019-11-28 06:11:17 +00:00
## Example Output
![Gold Dark Style](https://github.com/charmbracelet/gold/raw/master/styles/gallery/dark.png)
2019-11-24 04:19:13 +00:00
2019-11-09 22:12:54 +00:00
## Colors
Currently `gold` uses the [Aurora ANSI colors](https://godoc.org/github.com/logrusorgru/aurora#Index).