Skip to content
Myr

filter-key-value.sh

This file

Path

examples/filter-key-value.sh

13 lines · 207 bytes · Shell

Last changed by

Not known.

History of this file

Take it

The walk stopped after 200 commits: lines older than 6837ed2 point at it.

feat(deps): bump github.com/charmbracelet/bubbletea from 0.27.0 to 1.0.0 (#661)dependabot[bot]before adoption6837ed2

lines 1–13why, one step back
1#!/bin/bash
23export LIST=$(cat <<END4Cow:Moo5Cat:Meow6Dog:Woof7END8)910ANIMAL=$(echo "$LIST" | cut -d':' -f1 | gum filter)11SOUND=$(echo "$LIST" | grep $ANIMAL | cut -d':' -f2)1213echo "The $ANIMAL goes $SOUND"