Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions docs/spec/reference/cmd.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,19 +26,19 @@ cmd "config" {
}

cmd "list" {
example "Basic usage" r#"
example "Basic usage" #"""
$ mycli list
FRUIT COLOR
apple red
banana yellow
"#
example "JSON output" r#"
"""#
example "JSON output" #"""
$ mycli list --json
[
{"FRUIT": "apple", "COLOR": "red"},
{"FRUIT": "banana", "COLOR": "yellow"}
]
"#
"""#
}
```

Expand Down
11 changes: 6 additions & 5 deletions docs/spec/reference/flag.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,10 +43,11 @@ flag "--env <env>" {
flag "--file <file>" long_help="longer help for --help (as opposed to -h)"
// this is equivalent to the above but preferred when a lot of space is needed
flag "--file <file>" {
long_help r#"longer help for --help (as opposed to -h)
even
more
text
"#
long_help #"""
longer help for --help (as opposed to -h)
even
more
text
"""#
}
```
5 changes: 3 additions & 2 deletions docs/spec/reference/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,14 +36,15 @@ This is a tera template that can be used to customize the path for markdown docu
example, in mise I use the following to convert filenames to snake case:

```kdl
source_code_link_template r#"
source_code_link_template #"""
{%- set path = path | replace(from='-', to='_') -%}
{%- if cmd.subcommands | length > 0 -%}
{%- set path = path | split(pat="/") | slice(end=1) | concat(with="mod.rs") | join(sep="/") -%}
{%- else -%}
{%- set path = path ~ ".rs" -%}
{%- endif -%}
https://github.com/jdx/mise/blob/main/src/cli/{{path}}"#
https://github.com/jdx/mise/blob/main/src/cli/{{path}}
"""#
```

## Examples
Expand Down
4 changes: 2 additions & 2 deletions examples/mise.usage.kdl
Original file line number Diff line number Diff line change
Expand Up @@ -1194,9 +1194,9 @@ case $cur in
done
;;
esac
"#
"""#

complete "installed_tool@version" run=r#"
complete "installed_tool@version" run=#"""
cur="{{words[CURRENT]}}"
case $cur in
*@*)
Expand Down