-
Notifications
You must be signed in to change notification settings - Fork 31
/
Readme.md
107 lines (73 loc) Β· 3.31 KB
/
Readme.md
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
# alfred-emoji
[![Build Status](https://travis-ci.org/jsumners/alfred-emoji.svg?branch=master)](https://travis-ci.org/jsumners/alfred-emoji)
An [Alfred workflow][alfred] that makes it easy to search for emoji and copy
them to the clipboard π€.
![screenshot](images/screenshot.png)
> ## Note About Available Emoji
>
> The workflow is built against the latest available macOS within the GitHub
> continuous integration infrastructure. This means some emoji may be missing
> until the GitHub infrastructure is updated. It also means that some emoji
> may be present in the workflow that do not exist on your system if your
> system is running an earlier version of macOS.
>
> If this is not desired, follow the instructions below for generating the
> workflow on your own system.
## Installing the Workflow
[Download the provided Alfred workflow][releases].
Notice: This workflow relies on JXA (JavaScript for Automation) that is built
into macOS.
## Usage
```
emoji [query]
```
Press <kbd>return</kbd> (β΅): **Copy the symbol** of the selected emoji (e.g. π€£) to
your clipboard.
Press <kbd>alt</kbd>+<kbd>return</kbd> (β₯β΅): **Copy the code** of the selected emoji)
(e.g. `:rofl:`) to your clipboard.
Press <kbd>ctrl</kbd>+<kbd>return</kbd> (ββ΅): **Copy the codepoint** **of** the selected emoji)
(e.g. `U+1F923`) to your clipboard.
Press <kbd>shift</kbd>+<kbd>return</kbd> (β§β΅): **Copy the default symbol** of the selected emoji)
(e.g. π€£) to your clipboard without skin tone modifier.
Press <kbd>cmd</kbd>+<kbd>return</kbd> (ββ΅): **Paste the symbol** of the selected
emoji (e.g. π€£) directly to your frontmost application.
### Set skin tone
To change the emoji skin tone for supported emoji set the `skin_tone` environment variable in Alfred:
![screenshot skin tone settings](images/screenshot-skin-tone-setting.png)
Options:
- No value => π
- `0` => ππ»
- `1` => ππΌ
- `2` => ππ½
- `3` => ππΎ
- `4` => ππΏ
- `random` => ππ» | ππΌ | ππ½ | ππΎ | ππΏ
After setting skin tone you can still quickly copy the default emoji with the <kbd>shift</kbd> modifier.
## Automatic Updates
This workflow will automatically check for updates at most once per day. If a
new release is found, it automatically downloads and installs the latest
version of the workflow. All downloads come directly from official [GitHub
releases][releases].
## Optional Hotkey and Snippet Triggers
Trigger the workflow with either a custom hotkey or a custom snippet.
## Building the Workflow
1. Clone this repository
2. `npm install`
3. `npm run build`
## Loading the Workflow into Alfred
1. `npm run load`
## Inspiration
This is based on the original work by [Carlos Galdino][carlos]. His project
seems to be unmaintained (some emoji don't copy and some newer are missing).
Whereas his project is based on the Ruby language, this one is based on
JavaScript.
## Other
* [Associated Alfred Forum Post][alfredforum]
* [Emoji Keyword Library][emojilib]
## License
[MIT License](http://jsumners.mit-license.org/)
[alfred]: https://alfredapp.com/
[carlos]: https://github.com/carlosgaldino/alfred-emoji-workflow/
[releases]: https://github.com/jsumners/alfred-emoji/releases
[alfredforum]: https://www.alfredforum.com/topic/11126-alfred-emoji-search-emojis-by-name-or-keyword/
[emojilib]: https://github.com/muan/emojilib