-
-
Notifications
You must be signed in to change notification settings - Fork 11
Expand file tree
/
Copy path05-group-by-behavior.cast
More file actions
6 lines (6 loc) · 1.38 KB
/
05-group-by-behavior.cast
File metadata and controls
6 lines (6 loc) · 1.38 KB
1
2
3
4
5
6
{"version": 2, "width": 140, "height": 48, "timestamp": 1773233385, "env": {"SHELL": "/usr/bin/zsh", "TERM": "xterm-256color"}}
[0.008158, "o", "\r\n# group_by behavior\r\n"]
[0.80988, "o", "\r\n$ echo '[{\"x\":1},{\"x\":2},{\"x\":1}]' | jq 'group_by(.x)'\r\n"]
[0.812639, "o", "\u001b[1;39m[\r\n \u001b[1;39m[\r\n \u001b[1;39m{\r\n \u001b[0m\u001b[1;34m\"x\"\u001b[0m\u001b[1;39m: \u001b[0m\u001b[0;39m1\u001b[0m\u001b[1;39m\r\n \u001b[1;39m}\u001b[0m\u001b[1;39m,\r\n \u001b[1;39m{\r\n \u001b[0m\u001b[1;34m\"x\"\u001b[0m\u001b[1;39m: \u001b[0m\u001b[0;39m1\u001b[0m\u001b[1;39m\r\n \u001b[1;39m}\u001b[0m\u001b[1;39m\r\n \u001b[1;39m]\u001b[0m\u001b[1;39m,\r\n \u001b[1;39m[\r\n \u001b[1;39m{\r\n \u001b[0m\u001b[1;34m\"x\"\u001b[0m\u001b[1;39m: \u001b[0m\u001b[0;39m2\u001b[0m\u001b[1;39m\r\n \u001b[1;39m}\u001b[0m\u001b[1;39m\r\n \u001b[1;39m]\u001b[0m\u001b[1;39m\r\n\u001b[1;39m]\u001b[0m\r\n"]
[1.814827, "o", "\r\n$ echo '[{\"x\":1},{\"x\":2},{\"x\":1}]' | _opam/bin/query-json 'group_by(.x)'\r\n"]
[1.821698, "o", "{ \u001b[1m\u001b[34m\"1\"\u001b[39m\u001b[0m: [ { \u001b[1m\u001b[34m\"x\"\u001b[39m\u001b[0m: \u001b[32m1\u001b[39m\u001b[0m }, { \u001b[1m\u001b[34m\"x\"\u001b[39m\u001b[0m: \u001b[32m1\u001b[39m\u001b[0m } ], \u001b[1m\u001b[34m\"2\"\u001b[39m\u001b[0m: [ { \u001b[1m\u001b[34m\"x\"\u001b[39m\u001b[0m: \u001b[32m2\u001b[39m\u001b[0m } ] }\r\n"]