Skip to content

Commit f75dfa6

Browse files
authored
docs: add new gifs (#533)
* docs: add new gifs * Update README.md * docs: spin.gif * docs: add spin.gif to readme * fix: lint * don't commit filter.tape
1 parent 2a35019 commit f75dfa6

17 files changed

+227
-14
lines changed

README.md

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ export GUM_INPUT_WIDTH=80
130130
gum input
131131
```
132132

133-
<img alt="Gum input displaying most customization options" width="600" src="https://stuff.charm.sh/gum/customization.gif">
133+
<img alt="Gum input displaying most customization options" width="600" src="https://vhs.charm.sh/vhs-5zb9DlQYA70aL9ZpYLTwKv.gif">
134134

135135
## Input
136136

@@ -141,7 +141,7 @@ gum input > answer.txt
141141
gum input --password > password.txt
142142
```
143143

144-
<img src="https://stuff.charm.sh/gum/input_1.gif" width="600" alt="Shell running gum input typing Not much, you?" />
144+
<img src="https://vhs.charm.sh/vhs-1nScrStFI3BMlCp5yrLtyg.gif" width="600" alt="Shell running gum input typing Not much, you?" />
145145

146146
## Write
147147

@@ -151,7 +151,7 @@ Prompt for some multi-line text (`ctrl+d` to complete text entry).
151151
gum write > story.txt
152152
```
153153

154-
<img src="https://stuff.charm.sh/gum/write.gif" width="600" alt="Shell running gum write typing a story" />
154+
<img src="https://vhs.charm.sh/vhs-7abdKKrUEukgx9aJj8O5GX.gif" width="600" alt="Shell running gum write typing a story" />
155155

156156
## Filter
157157

@@ -164,7 +164,7 @@ echo Cherry >> flavors.txt
164164
gum filter < flavors.txt > selection.txt
165165
```
166166

167-
<img src="https://stuff.charm.sh/gum/filter.gif" width="600" alt="Shell running gum filter on different bubble gum flavors" />
167+
<img src="https://vhs.charm.sh/vhs-61euOQtKPtQVD7nDpHQhzr.gif" width="600" alt="Shell running gum filter on different bubble gum flavors" />
168168

169169
Select multiple options with the `--limit` flag or `--no-limit` flag. Use `tab` or `ctrl+space` to select, `enter` to confirm.
170170

@@ -191,7 +191,7 @@ cat songs.txt | gum choose --limit 5
191191
cat foods.txt | gum choose --no-limit --header "Grocery Shopping"
192192
```
193193

194-
<img src="https://stuff.charm.sh/gum/choose.gif" width="600" alt="Shell running gum choose with numbers and gum flavors" />
194+
<img src="https://vhs.charm.sh/vhs-3zV1LvofA6Cbn5vBu1NHHl.gif" width="600" alt="Shell running gum choose with numbers and gum flavors" />
195195

196196
## Confirm
197197

@@ -202,7 +202,7 @@ Confirm whether to perform an action. Exits with code `0` (affirmative) or `1`
202202
gum confirm && rm file.txt || echo "File not removed"
203203
```
204204

205-
<img src="https://stuff.charm.sh/gum/confirm_2.gif" width="600" alt="Shell running gum confirm" />
205+
<img src="https://vhs.charm.sh/vhs-3xRFvbeQ4lqGerbHY7y3q2.gif" width="600" alt="Shell running gum confirm" />
206206

207207
## File
208208

@@ -212,7 +212,7 @@ Prompt the user to select a file from the file tree.
212212
EDITOR $(gum file $HOME)
213213
```
214214

215-
<img src="https://stuff.charm.sh/gum/file.gif" width="600" alt="Shell running gum file" />
215+
<img src="https://vhs.charm.sh/vhs-2RMRqmnOPneneIgVJJ3mI1.gif" width="600" alt="Shell running gum file" />
216216

217217
## Pager
218218

@@ -222,7 +222,7 @@ Scroll through a long document with line numbers and a fully customizable viewpo
222222
gum pager < README.md
223223
```
224224

225-
<img src="https://stuff.charm.sh/gum/pager.gif" width="600" alt="Shell running gum pager" />
225+
<img src="https://vhs.charm.sh/vhs-3iMDpgOLmbYr0jrYEGbk7p.gif" width="600" alt="Shell running gum pager" />
226226

227227
## Spin
228228

@@ -235,7 +235,7 @@ To view or pipe the command's output, use the `--show-output` flag.
235235
gum spin --spinner dot --title "Buying Bubble Gum..." -- sleep 5
236236
```
237237

238-
<img src="https://stuff.charm.sh/gum/spin.gif" width="600" alt="Shell running gum spin while sleeping for 5 seconds" />
238+
<img src="https://vhs.charm.sh/vhs-3YFswCmoY4o3Q7MyzWl6sS.gif" width="600" alt="Shell running gum spin while sleeping for 5 seconds" />
239239

240240
Available spinner types include: `line`, `dot`, `minidot`, `jump`, `pulse`, `points`, `globe`, `moon`, `monkey`, `meter`, `hamburger`.
241241

@@ -247,7 +247,7 @@ Select a row from some tabular data.
247247
gum table < flavors.csv | cut -d ',' -f 1
248248
```
249249

250-
<img src="https://stuff.charm.sh/gum/table.gif" width="600" alt="Shell running gum table" />
250+
<!-- <img src="https://stuff.charm.sh/gum/table.gif" width="600" alt="Shell running gum table" /> -->
251251

252252
## Style
253253

@@ -260,7 +260,7 @@ gum style \
260260
'Bubble Gum (1¢)' 'So sweet and so fresh!'
261261
```
262262

263-
<img src="https://stuff.charm.sh/gum/style.gif" width="600" alt="Bubble Gum, So sweet and so fresh!" />
263+
<img src="https://github.com/charmbracelet/gum/assets/42545625/67468acf-b3e0-4e78-bd89-360739eb44fa" width="600" alt="Bubble Gum, So sweet and so fresh!" />
264264

265265
## Join
266266

@@ -281,7 +281,7 @@ BUBBLE_GUM=$(gum join "$BUBBLE" "$GUM")
281281
gum join --align center --vertical "$I_LOVE" "$BUBBLE_GUM"
282282
```
283283

284-
<img src="https://stuff.charm.sh/gum/join.gif" width="600" alt="I LOVE Bubble Gum written out in four boxes with double borders around them." />
284+
<img src="https://github.com/charmbracelet/gum/assets/42545625/68f7a25d-b495-48dd-982a-cee0c8ea5786" width="600" alt="I LOVE Bubble Gum written out in four boxes with double borders around them." />
285285

286286
## Format
287287

@@ -308,7 +308,7 @@ For more information on template helpers, see the [Termenv
308308
docs](https://github.com/muesli/termenv#template-helpers). For a full list of
309309
named emojis see the [GitHub API](https://api.github.com/emojis).
310310

311-
<img src="https://stuff.charm.sh/gum/format.gif" width="600" alt="Running gum format for different types of formats" />
311+
<img src="https://github.com/charmbracelet/gum/assets/42545625/5cfbb0c8-0022-460d-841b-fec37527ca66" width="300" alt="Running gum format for different types of formats" />
312312

313313
## Log
314314

examples/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
11
*.gif
2+
*.png

examples/README.md

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
# Glamour
2+
3+
A casual introduction. 你好世界!
4+
5+
## Let's talk about artichokes
6+
7+
The artichoke is mentioned as a garden
8+
plant in the 8th century BC by Homer
9+
and Hesiod. The naturally occurring
10+
variant of the artichoke, the cardoon,
11+
which is native to the Mediterranean
12+
area, also has records of use as a
13+
food among the ancient Greeks and
14+
Romans. Pliny the Elder mentioned
15+
growing of 'carduus' in Carthage
16+
and Cordoba.
17+
18+
He holds him with his skinny hand,
19+
There was ship,' quoth he.
20+
'Hold off! unhand me, grey-beard loon!'
21+
An artichoke dropt he.
22+
23+
## Other foods worth mentioning
24+
25+
1. Carrots
26+
2. Celery
27+
3. Tacos
28+
• Soft
29+
• Hard
30+
4. Cucumber
31+
32+
## Things to eat today
33+
34+
* Carrots
35+
* Ramen
36+
* Currywurst

examples/choose.tape

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
Output choose.gif
2+
3+
Set Width 1000
4+
Set Height 430
5+
Set Shell bash
6+
7+
Type "gum choose {1..5}"
8+
Sleep 500ms
9+
Enter
10+
Sleep 500ms
11+
Down@250ms 3
12+
Sleep 500ms
13+
Up@250ms 2
14+
Enter
15+
Sleep 1.5s
16+
Ctrl+L
17+
Sleep 500ms
18+
Type "gum choose --limit 2 Banana Cherry Orange"
19+
Sleep 500ms
20+
Enter
21+
Sleep 500ms
22+
Type@250ms "jxjxk"
23+
Sleep 1s
24+
Enter
25+
Sleep 2s
26+

examples/confirm.tape

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
Output confirm.gif
2+
3+
Set Width 1000
4+
Set Height 350
5+
Set Shell bash
6+
7+
Sleep 500ms
8+
Type "gum confirm && echo 'Me too!' || echo 'Me neither.'"
9+
Sleep 1s
10+
Enter
11+
Sleep 1s
12+
Right
13+
Sleep 500ms
14+
Left
15+
Sleep 500ms
16+
Enter
17+
Sleep 1.5s
18+
Ctrl+L
19+
Type "gum confirm && echo 'Me too!' || echo 'Me neither.'"
20+
Sleep 500ms
21+
Enter
22+
Sleep 500ms
23+
Right
24+
Sleep 500ms
25+
Enter
26+
Sleep 1s

examples/customize.tape

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
Output customize.gif
2+
3+
Set Width 1000
4+
Set Height 350
5+
Set Shell bash
6+
7+
Sleep 1s
8+
Type `gum input --cursor.foreground "#F4AC45" \` Enter
9+
Type `--prompt.foreground "#04B575" --prompt "What's up? " \` Enter
10+
Type `--placeholder "Not much, you?" --value "Not much, you?" \` Enter
11+
Type `--width 80` Enter
12+
Sleep 1s
13+
Ctrl+A
14+
Sleep 1s
15+
Ctrl+E
16+
Sleep 1s
17+
Ctrl+U
18+
Sleep 1s
19+

examples/fav.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Banana

examples/file.tape

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
Output file.gif
2+
Set Width 800
3+
Set Height 525
4+
Set Shell bash
5+
6+
Type "gum file .."
7+
Enter
8+
Sleep 1s
9+
Down@150ms 6
10+
Sleep 1s
11+
Enter
12+
Sleep 1s
13+
Type "j"
14+
Sleep 1s
15+

examples/flavors.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
Banana
2+
Cherry
3+
Orange
4+
Strawberry

examples/format.ansi

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
> gum format -t code < main.go
2+
3+
4+
   package main
5+
   
6+
   import "fmt"
7+
   
8+
   func main() {
9+
    fmt.Println("Charm_™ Gum")
10+
   }
11+
   
12+


examples/input.tape

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
Output input.gif
2+
3+
Set Width 800
4+
Set Height 250
5+
Set Shell bash
6+
7+
Sleep 1s
8+
Type `gum input --placeholder "What's up?"`
9+
Sleep 1s
10+
Enter
11+
Sleep 1s
12+
Type "Not much, you?"
13+
Sleep 1s
14+
Enter
15+
Sleep 1s
16+

examples/main.go

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
package main
2+
3+
import "fmt"
4+
5+
func main() {
6+
fmt.Println("Charm_™ Gum")
7+
}

examples/pager.tape

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
Output pager.gif
2+
3+
Set Shell bash
4+
Set Width 900
5+
Set Height 750
6+
7+
Sleep 1s
8+
Type "gum pager < README.md"
9+
Enter
10+
Sleep 1.5s
11+
Down@100ms 25
12+
Sleep 1s
13+
Up@100ms 25
14+
Sleep 3s
15+

examples/spin.tape

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
Output spin.gif
2+
3+
Set Shell bash
4+
Set Width 1200
5+
Set Height 300
6+
Set FontSize 36
7+
8+
Sleep 500ms
9+
Type `gum spin --title "Buying Gum..." -- sleep 5`
10+
Sleep 1s
11+
Enter
12+
Sleep 4s
13+

examples/story.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
Once upon a time
2+
In a land far, far away....

examples/write.tape

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
Output write.gif
2+
3+
Set Width 800
4+
Set Height 350
5+
Set Shell bash
6+
7+
Sleep 500ms
8+
Type "gum write > story.txt"
9+
Enter
10+
Sleep 1s
11+
Type "Once upon a time"
12+
Sleep 1s
13+
Alt+Enter
14+
Type "In a land far, far away...."
15+
Sleep 500ms
16+
Enter
17+
Sleep 1s
18+
Type "cat story.txt"
19+
Enter
20+
Sleep 2s
21+

input/command.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ import (
1414
// Run provides a shell script interface for the text input bubble.
1515
// https://github.com/charmbracelet/bubbles/textinput
1616
func (o Options) Run() error {
17-
1817
var value string
1918
if o.Value != "" {
2019
value = o.Value

0 commit comments

Comments
 (0)