mirror of
https://github.com/tldr-pages/tldr.git
synced 2024-08-16 23:40:43 +03:00
CONTRIBUTING: add notes about placeholders and some examples (#8366)
* Add notes about placeholders and some examples * Apply suggestions from code review Co-authored-by: CleanMachine1 <78213164+CleanMachine1@users.noreply.github.com> * Use `tokens` instead of `things` Co-authored-by: Muhammad Falak R Wani <falakreyaz@gmail.com> Co-authored-by: CleanMachine1 <78213164+CleanMachine1@users.noreply.github.com> Co-authored-by: Muhammad Falak R Wani <falakreyaz@gmail.com>
This commit is contained in:
parent
01f68eb87f
commit
5b1acd3a89
@ -59,14 +59,25 @@ As a quick reference, the format of each page should match the following templat
|
||||
|
||||
- Example description:
|
||||
|
||||
`command -opt1 -opt2`
|
||||
`command --option`
|
||||
|
||||
- Example description:
|
||||
|
||||
`command -opt1 -opt2 -arg1 {{arg_value}}`
|
||||
`command --option1 --option2 {{arg_value}}`
|
||||
```
|
||||
|
||||
For more detailed page formatting guidelines,
|
||||
To see some examples of preexisting pages, you can look at:
|
||||
|
||||
- [pwd](https://github.com/tldr-pages/tldr/blob/main/pages/common/pwd.md) - one of the simpliest command examples
|
||||
- [caja](https://github.com/tldr-pages/tldr/blob/main/pages/common/tar.md) - page with placeholders
|
||||
|
||||
In our pages, we use placeholders which are defined as being tokens within curly brackets, for example `sleep {{5}}`, in this case the user can change 5 to any number.
|
||||
Other examples but not limited to of our placeholder syntax are:
|
||||
|
||||
- `{{path/to/directory}}`
|
||||
- `{{path/to/directory1 path/to/directory2 ...}}`
|
||||
|
||||
For more detailed formatting guidelines,
|
||||
refer to the [style guide](contributing-guides/style-guide.md).
|
||||
|
||||
## Subcommands
|
||||
|
Loading…
Reference in New Issue
Block a user