summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorDenis Isidoro <denisidoro@users.noreply.github.com>2020-04-10 23:01:35 -0300
committerGitHub <noreply@github.com>2020-04-10 23:01:35 -0300
commit6678cda0322406c75a97a5977491352acef870bb (patch)
tree1d118dd97066cb2809fa6f46b46950c0ed241867 /tests
parent1f5db34902a0e552fe60971c0047ebf4987122ac (diff)
Add support for post-choice manipulation (#335)
Fixes #325
Diffstat (limited to 'tests')
-rw-r--r--tests/cheats/more_cases.cheat6
1 files changed, 5 insertions, 1 deletions
diff --git a/tests/cheats/more_cases.cheat b/tests/cheats/more_cases.cheat
index 044595a..898a052 100644
--- a/tests/cheats/more_cases.cheat
+++ b/tests/cheats/more_cases.cheat
@@ -35,6 +35,9 @@ echo "<x> <y> <x> <z>"
# with preview
cat "<file>"
+# with map
+echo "<mapped>"
+
# fzf
ls / | fzf
@@ -45,7 +48,8 @@ $ table_elem: echo -e '0 rust rust-lang.org\n1 clojure clojure.org' ---
$ table_elem2: echo -e '0;rust;rust-lang.org\n1;clojure;clojure.org' --- --column 2 --delimiter ';'
$ multi_col: ls -la | awk '{print $1, $9}' --- --column 2 --delimiter '\s' --multi
$ langs: echo 'clojure rust javascript' | tr ' ' '\n' --- --multi
-$ examples: echo -e 'foo bar\nlorem ipsum\ndolor sit' --- --mult
+$ mapped: echo 'true false' | tr ' ' '\n' --- --map "[[ $0 == t* ]] && echo 1 || echo 0"
+$ examples: echo -e 'foo bar\nlorem ipsum\ndolor sit' --- --multi
$ multiword: echo -e 'foo bar\nlorem ipsum\ndolor sit\nbaz'i
$ file: ls . --- --preview 'cat {}' --preview-window '50%'