mirror of
https://github.com/sharkdp/bat
synced 2024-11-23 04:13:11 +00:00
Map fish_history
to YAML
This commit is contained in:
parent
ca9843fa83
commit
839e62cff8
3 changed files with 29 additions and 0 deletions
|
@ -66,6 +66,9 @@ impl<'a> SyntaxMapping<'a> {
|
|||
mapping
|
||||
.insert("*.pac", MappingTarget::MapTo("JavaScript (Babel)"))
|
||||
.unwrap();
|
||||
mapping
|
||||
.insert("fish_history", MappingTarget::MapTo("YAML"))
|
||||
.unwrap();
|
||||
|
||||
// See #2151, https://nmap.org/book/nse-language.html
|
||||
mapping
|
||||
|
|
15
tests/syntax-tests/highlighted/fish_history/fish_history
vendored
Normal file
15
tests/syntax-tests/highlighted/fish_history/fish_history
vendored
Normal file
|
@ -0,0 +1,15 @@
|
|||
[38;5;238m───────┬────────────────────────────────────────────────────────────────────────[0m
|
||||
[38;5;238m│ [0mFile: [1mfish_history[0m
|
||||
[38;5;238m───────┼────────────────────────────────────────────────────────────────────────[0m
|
||||
[38;5;238m 1[0m [38;5;238m│[0m [38;5;231m-[0m[38;5;231m [0m[38;5;203mcmd[0m[38;5;231m:[0m[38;5;231m [0m[38;5;186mecho "hello world"[0m
|
||||
[38;5;238m 2[0m [38;5;238m│[0m [38;5;231m [0m[38;5;203mwhen[0m[38;5;231m:[0m[38;5;231m [0m[38;5;141m1656950812[0m
|
||||
[38;5;238m 3[0m [38;5;238m│[0m [38;5;231m-[0m[38;5;231m [0m[38;5;203mcmd[0m[38;5;231m:[0m[38;5;231m [0m[38;5;186mls /tmp[0m
|
||||
[38;5;238m 4[0m [38;5;238m│[0m [38;5;231m [0m[38;5;203mwhen[0m[38;5;231m:[0m[38;5;231m [0m[38;5;141m1656950818[0m
|
||||
[38;5;238m 5[0m [38;5;238m│[0m [38;5;231m [0m[38;5;203mpaths[0m[38;5;231m:[0m
|
||||
[38;5;238m 6[0m [38;5;238m│[0m [38;5;231m [0m[38;5;231m-[0m[38;5;231m [0m[38;5;186m/tmp[0m
|
||||
[38;5;238m 7[0m [38;5;238m│[0m [38;5;231m-[0m[38;5;231m [0m[38;5;203mcmd[0m[38;5;231m:[0m[38;5;231m [0m[38;5;186mcp .local/share/fish/fish_history .[0m
|
||||
[38;5;238m 8[0m [38;5;238m│[0m [38;5;231m [0m[38;5;203mwhen[0m[38;5;231m:[0m[38;5;231m [0m[38;5;141m1656950833[0m
|
||||
[38;5;238m 9[0m [38;5;238m│[0m [38;5;231m [0m[38;5;203mpaths[0m[38;5;231m:[0m
|
||||
[38;5;238m 10[0m [38;5;238m│[0m [38;5;231m [0m[38;5;231m-[0m[38;5;231m [0m[38;5;186m.local/share/fish/fish_history[0m
|
||||
[38;5;238m 11[0m [38;5;238m│[0m [38;5;231m [0m[38;5;231m-[0m[38;5;231m [0m[38;5;141m.[0m
|
||||
[38;5;238m───────┴────────────────────────────────────────────────────────────────────────[0m
|
11
tests/syntax-tests/source/fish_history/fish_history
vendored
Normal file
11
tests/syntax-tests/source/fish_history/fish_history
vendored
Normal file
|
@ -0,0 +1,11 @@
|
|||
- cmd: echo "hello world"
|
||||
when: 1656950812
|
||||
- cmd: ls /tmp
|
||||
when: 1656950818
|
||||
paths:
|
||||
- /tmp
|
||||
- cmd: cp .local/share/fish/fish_history .
|
||||
when: 1656950833
|
||||
paths:
|
||||
- .local/share/fish/fish_history
|
||||
- .
|
Loading…
Reference in a new issue