cat / 012
clone

a spreadsheet for the terminal: lotus 1-2-3 looks, google sheets keys and formulas, one go binary

Demos: work in a notebook output's grid; chart the recipe's totals from it

Dami committed f8b00ba
Co-Authored-By: Claude <noreply@anthropic.com>
commit
f8b00baea04e0fd6015c4480c7f03fa87adc02ff
parent
c7a33bd5e0b1c14cc28681f698056508430fe77c
author
Dami <dami.etoile@gmail.com>
kind
docs risk score 0.3 of 3, Jev's estimate
7 files changed, +34 -28
Mdemos/notebook.tape39++++++++++++++++++------------
Mdemos/nu-recipe.tape12++-------
Adocs/media/notebook-grid.pngbin
Mdocs/media/notebook.gifbin
Mdocs/media/nu-recipe.gifbin
Mdocs/nushell/cookbook.md7+++--
Mdocs/nushell/notebooks.md4++-
M demos/notebook.tape +24 -15
@@ -1,6 +1,7 @@
11 # Notebooks: 012 nu opens a notebook, its first cell ready to type in.22 # A code cell reads a CSV as sales, a second reads it as $sales, and its3-# output goes to a sheet (G) where a formula sums it; with the notebook3+# output, entered with Enter, is a grid to select in, and goes to a4+# sheet (G) where a formula sums it; with the notebook45 # reactive, editing sales runs both again and the sheet follows. The terminal (ttyd) sends Shift+Enter as Enter, so56 # cells run with Esc then r. Needs nu on the PATH.67 Output out/notebook.gif
@@ -12,52 +13,60 @@ Sleep 2s
1213 Show1314 1415 Sleep 800ms15-Type@25ms "sales = open data/sales.csv | where Region in [North South] | select Region Quarter Units"16+Type@15ms "sales = open data/sales.csv | where Region in [North South] | select Region Quarter Units"1617 Sleep 500ms1718 Escape1819 Type "r"19-Sleep 1.5s20+Sleep 1s2021 Type "b"2122 Enter22-Type@25ms "top = $sales | where Units > 250 | sort-by Units --reverse"23+Type@15ms "top = $sales | where Units > 250 | sort-by Units --reverse"2324 Sleep 500ms2425 Escape2526 Type "r"2627 Sleep 2s2728 Screenshot out/stills/notebook-cells.png29+Down30+Enter31+Sleep 400ms32+Ctrl+Shift+Down33+Sleep 1s34+Screenshot out/stills/notebook-grid.png35+Escape Escape36+Sleep 500ms2837 Type "G"2938 Sleep 800ms3039 Enter3140 Sleep 1.2s3241 Ctrl+K33-Type@40ms "next sh"42+Type@20ms "next sh"3443 Sleep 500ms3544 Enter36-Sleep 600ms45+Sleep 400ms3746 Right Right Right Right3847 Type "=SUM(nu.top)" Enter39-Sleep 1.5s48+Sleep 1s4049 Screenshot out/stills/notebook-sent.png4150 Ctrl+K42-Type@40ms "previous sh"51+Type@20ms "previous sh"4352 Sleep 500ms4453 Enter45-Sleep 600ms54+Sleep 400ms4655 Ctrl+K47-Type@50ms "reacti"48-Sleep 600ms56+Type@20ms "reacti"57+Sleep 400ms4958 Enter5059 Sleep 400ms51-Up Up60+Up Up Up5261 Sleep 300ms5362 Enter54-Type@30ms " | where Quarter != Q1"63+Type@20ms " | where Quarter != Q1"5564 Escape5665 Type "r"57-Sleep 2.5s66+Sleep 2s5867 Screenshot out/stills/notebook-reactive.png5968 Ctrl+K60-Type@40ms "next sh"69+Type@20ms "next sh"6170 Sleep 500ms6271 Enter6372 Sleep 2s
M demos/nu-recipe.tape +3 -9
A docs/media/notebook-grid.png +0 -0

Binary file.

M docs/media/notebook.gif +0 -0

Binary file.

M docs/media/nu-recipe.gif +0 -0

Binary file.

M docs/nushell/cookbook.md +4 -3
M docs/nushell/notebooks.md +3 -1