Skip to content

Commit c52cbda

Browse files
authored
Link to nu commands on "Nu Map from Functional Languages" page (#2066)
* Link to nu commands on "Nu Map from Functional Languages" page * Add more commands * Add other commands
1 parent 14d5d70 commit c52cbda

File tree

1 file changed

+41
-41
lines changed

1 file changed

+41
-41
lines changed

book/nushell_map_functional.md

Lines changed: 41 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -4,44 +4,44 @@ The idea behind this table is to help you understand how Nu builtins and plugins
44

55
Note: this table assumes Nu 0.43 or later.
66

7-
| Nushell | Clojure | Tablecloth (Ocaml / Elm) | Haskell |
8-
| ------------ | ---------------------------- | ------------------------------- | ------------------------ |
9-
| append | conj, into, concat | append, (++), concat, concatMap | (++) |
10-
| into binary | Integer/toHexString | | showHex |
11-
| count | count | length, size | length, size |
12-
| date | java.time.LocalDate/now | | |
13-
| each | map, mapv, iterate | map, forEach | map, mapM |
14-
| exit | System/exit | | |
15-
| first | first | head | head |
16-
| format | format | | Text.Printf.printf |
17-
| group-by | group-by | | group, groupBy |
18-
| help | doc | | |
19-
| is-empty | empty? | isEmpty | |
20-
| last | last, peek, take-last | last | last |
21-
| lines | | | lines, words, split-with |
22-
| match | | match (Ocaml), case (Elm) | case |
23-
| nth | nth | Array.get | lookup |
24-
| open | with-open | | |
25-
| transpose | (apply mapv vector matrix) | | transpose |
26-
| prepend | cons | cons, :: | :: |
27-
| print | println | | putStrLn, print |
28-
| range, 1..10 | range | range | 1..10, 'a'..'f' |
29-
| reduce | reduce, reduce-kv | foldr | foldr |
30-
| reverse | reverse, rseq | reverse, reverseInPlace | reverse |
31-
| select | select-keys | | |
32-
| shuffle | shuffle | | |
33-
| size | count | | size, length |
34-
| skip | rest | tail | tail |
35-
| skip until | drop-while | | |
36-
| skip while | drop-while | dropWhile | dropWhile, dropWhileEnd |
37-
| sort-by | sort, sort-by, sorted-set-by | sort, sortBy, sortWith | sort, sortBy |
38-
| split row | split, split-{at,with,lines} | split, words, lines | split, words, lines |
39-
| str | clojure.string functions | String functions | |
40-
| str join | join | concat | intercalate |
41-
| str trim | trim, triml, trimr | trim, trimLeft, trimRight | strip |
42-
| sum | apply + | sum | sum |
43-
| take | take, drop-last, pop | take, init | take, init |
44-
| take until | take-while | takeWhile | takeWhile |
45-
| take while | take-while | takeWhile | takeWhile |
46-
| uniq | set | Set.empty | Data.Set |
47-
| where | filter, filterv, select | filter, filterMap | filter |
7+
| Nushell | Clojure | Tablecloth (Ocaml / Elm) | Haskell |
8+
|------------------------------------------------|------------------------------|---------------------------------|--------------------------|
9+
| [append](../commands/docs/append.md) | conj, into, concat | append, (++), concat, concatMap | (++) |
10+
| [into binary](../commands/docs/into_binary.md) | Integer/toHexString | | showHex |
11+
| [length](../commands/docs/length.md) | count | length, size | length, size |
12+
| [date](../commands/docs/date.md) | java.time.LocalDate/now | | |
13+
| [each](../commands/docs/each.md) | map, mapv, iterate | map, forEach | map, mapM |
14+
| [exit](../commands/docs/each.md) | System/exit | | |
15+
| [first](../commands/docs/first.md) | first | head | head |
16+
| [format](../commands/docs/format.md) | format | | Text.Printf.printf |
17+
| [group-by](../commands/docs/group-by.md) | group-by | | group, groupBy |
18+
| [help](../cookbook/help.md) | doc | | |
19+
| [is-empty](../commands/docs/is-empty.md) | empty? | isEmpty | |
20+
| [last](../commands/docs/last.md) | last, peek, take-last | last | last |
21+
| [lines](../commands/docs/lines.md) | | | lines, words, split-with |
22+
| [match](../commands/docs/match.md) | | match (Ocaml), case (Elm) | case |
23+
| [select](../commands/docs/select.md) | nth | Array.get | lookup |
24+
| [open](../commands/docs/open.md) | with-open | | |
25+
| [transpose](../commands/docs/transpose.md) | (apply mapv vector matrix) | | transpose |
26+
| [prepend](../commands/docs/prepend.md) | cons | cons, :: | :: |
27+
| [print](../commands/docs/print.md) | println | | putStrLn, print |
28+
| [slice](../commands/docs/slice.md), 1..10 | range | range | 1..10, 'a'..'f' |
29+
| [reduce](../commands/docs/reduce.md) | reduce, reduce-kv | foldr | foldr |
30+
| [reverse](../commands/docs/reverse.md) | reverse, rseq | reverse, reverseInPlace | reverse |
31+
| [select](../commands/docs/select.md) | select-keys | | |
32+
| [shuffle](../commands/docs/shuffle.md) | shuffle | | |
33+
| [length](../commands/docs/length.md) | count | | size, length |
34+
| [skip](../commands/docs/skip.md) | rest | tail | tail |
35+
| [skip until](../commands/docs/skip_until.md) | drop-while | | |
36+
| [skip while](../commands/docs/skip_while.md) | drop-while | dropWhile | dropWhile, dropWhileEnd |
37+
| [sort-by](../commands/docs/sort-by.md) | sort, sort-by, sorted-set-by | sort, sortBy, sortWith | sort, sortBy |
38+
| [split row](../commands/docs/split_row.md) | split, split-{at,with,lines} | split, words, lines | split, words, lines |
39+
| [str](../commands/docs/str.md) | clojure.string functions | String functions | |
40+
| [str join](../commands/docs/str_join.md) | join | concat | intercalate |
41+
| [str trim](../commands/docs/str_trim.md) | trim, triml, trimr | trim, trimLeft, trimRight | strip |
42+
| [math sum](../commands/docs/math_sum.md) | apply + | sum | sum |
43+
| [take](../commands/docs/take.md) | take, drop-last, pop | take, init | take, init |
44+
| [take until](../commands/docs/take_until.md) | take-while | takeWhile | takeWhile |
45+
| [take while](../commands/docs/take_while.md) | take-while | takeWhile | takeWhile |
46+
| [uniq](../commands/docs/uniq.md) | set | Set.empty | Data.Set |
47+
| [where](../commands/docs/where.md) | filter, filterv, select | filter, filterMap | filter |

0 commit comments

Comments
 (0)