daux.io/docs/01_Features/Static_Site_Generation.md

65 lignes
1.3 KiB
Markdown
Brut Vue normale Historique

2020-04-25 14:44:43 +02:00
If you don't want to serve the live version of your site, you can also generate files, these can be one of the three supported formats :
2015-12-12 00:22:43 +01:00
2020-04-25 14:44:43 +02:00
- HTML output
- Single page HTML output
- Atlassian Confluence upload
2015-12-12 00:22:43 +01:00
Generating a complete set of pages, with navigation
```bash
2016-07-29 23:20:01 +02:00
daux --destination=[Output Directory Relative Direction]
2015-12-12 00:22:43 +01:00
```
## Options
2020-04-25 14:44:43 +02:00
For more options, run
2015-12-12 00:22:43 +01:00
```bash
2016-07-29 23:20:01 +02:00
daux generate --help
2015-12-12 00:22:43 +01:00
```
### Specify the configuration file
### Specify the format
Valid options are `html`, `confluence` or `html-file`.
You can also add your own formats through Processors
```bash
2016-07-29 23:20:01 +02:00
daux --format=html
2015-12-12 00:22:43 +01:00
```
### Specify a processor
2020-04-25 14:44:43 +02:00
A processor can be specified through the `--processor` option, this should be the name of a class inside the `Todaymade\Daux\Extension` namespace.
2015-12-12 00:22:43 +01:00
By running :
```bash
2016-07-29 23:20:01 +02:00
daux --processor=Processor
2015-12-12 00:22:43 +01:00
```
Daux will be looking for `Todaymade\Daux\Extension\Processor` inside the `daux` folder.
You can try to run this command, we added a small example Processor.
### Specify the source
By default, the source is taken from the `docs_directory` configuration value in `global.json` but you can override it here.
```bash
2016-07-29 23:20:01 +02:00
daux --source=docs_to_generate
2015-12-12 00:22:43 +01:00
```
The path can be absolute or relative
### Specify the destination
By default the destination is `static`
```bash
2016-07-29 23:20:01 +02:00
daux --destination=generated_docs
2015-12-12 00:22:43 +01:00
```
The path can be absolute or relative