URI:
       emoji - scripts - various script and utils
  HTML git clone git://z3bra.org/scripts
   DIR Log
   DIR Files
   DIR Refs
       ---
       emoji (471B)
       ---
            1 #!/bin/sh
            2 
            3 spec='https://unicode.org/Public/emoji/14.0/emoji-test.txt'
            4 cache=$HOME/.cache/emoji.txt
            5 
            6 sync() {
            7         curl -sL $spec \
            8                 | sed '/^#/d;/^$/d' \
            9                 | grep fully-qualified \
           10                 | sed 's/.*#\s*//;s/\s*E[0-9.]\+\s*/\t/;/:/d' \
           11                 > $cache
           12 }
           13 
           14 [ -f $cache ] || sync
           15 
           16 if tty -s; then
           17         pick < $cache | cut -f1
           18 elif [ -n "$WAYLAND_DISPLAY" ]; then
           19         sed 's/\t/    /' $cache \
           20                 | tofi --prompt-text "emoji" \
           21                 | sed -r 's/\s+.*$//' | tr -d '\n' | wl-copy
           22 else
           23         cat $cache
           24 fi