diff --git a/de/home/.local/bin/nf-list b/de/home/.local/bin/nf-list new file mode 100755 index 0000000..6eb309a --- /dev/null +++ b/de/home/.local/bin/nf-list @@ -0,0 +1,16 @@ +#!/usr/bin/env bash + +if ! which -s jq;then + printf 'jq is not installed\n' + exit 1 +fi + +#exit 0 + +json_cache="${HOME}/.cache/nerfont-cheatsheet.json" + +if [[ ! $(find "${json_cache}" -cmin -10080 -print 2>/dev/null) ]]; then + curl 'https://raw.githubusercontent.com/ryanoasis/nerd-fonts/refs/heads/master/glyphnames.json' -o "${json_cache}" +fi + +jq -r 'to_entries[] | "\(.value.char) - \(.key)"' "${json_cache}" | tail +2 | wofi --dmenu | awk '{print $1}' | wl-copy diff --git a/de/include b/de/include index 1fe59a6..08e6077 100644 --- a/de/include +++ b/de/include @@ -56,3 +56,4 @@ .XCompose .config/sway-profiles-rs .config/mc-server-info +.local/bin/nf-list