omp packages

@djoeyg/pi-emoji0.2.0

Slack-style :emoji: and kaomoji completion in the editor, with custom entries

GitHub Actions Published 9 days ago MIT ~173 downloads/mo

Untested on omp

This is a pi package. No one has reported whether it works on omp yet. If you try it, add your result below.

Did it work for you?

Result

One report per person. A new report replaces your old one.

Reports 0

No reports yet.

Readme

@djoeyg/pi-emoji

Slack-style emoji for pi. Type : plus a few letters and pick from the popup; the emoji is inserted as plain text.

pi install npm:@djoeyg/pi-emoji

Usage

  • :tada → pick 🎉 :tada:. Names ignore _ vs -, so :thumbs_up and :thumbs-up both match.
  • Kaomoji use the same mechanism: :shrug → ¯\_(ツ)_/¯, :tableflip, :lenny, ...
  • Completion only starts at a word boundary after at least two characters, so http://, 10:30 and foo::bar are left alone.

Custom entries

Run /emoji to add, remove or list entries. They are stored as a flat JSON map of name to replacement text:

  • ~/.pi/agent/emoji.json for all projects
  • .pi/emoji.json for one project (overrides user entries)
{ "elmo-fire": "🔥", "ship-it": "🚢 (ง'̀-'́)ง" }

Custom names override built-ins. Slack-style image emoji such as :elmo-fire: cannot be rendered in a terminal, so map them to any text you like.

Data

data/emoji.json is generated from emojibase shortcodes (Slack, GitHub and CLDR sets merged, Slack names win): node scripts/generate-emoji.mjs <emojibase-data/en>. Skin-tone variants are not included.