caronc / apprise

Apprise - Push Notifications that work with just about every platform!
https://hub.docker.com/r/caronc/apprise
BSD 2-Clause "Simplified" License
10.94k stars 385 forks source link

Apprise Emoji Support Added #1011

Closed caronc closed 6 months ago

caronc commented 7 months ago

Description:

Related issue (if applicable): #649

Emoji support added! :+1:

Emoji's simply translate entries like :smile: to :smile: and so-forth prior to the body or title being sent upstream.

The AppriseAsset holds the global flag of the usage for this new feature. It introduces a new variable called interpret_emojis which can be set to the following:

The CLI has also been updated to add a -j or --interpret-emojis flag. If this isn't specified then the underlining AppriseAsset takes the value of None (see above for it's definition). Otherwise it is set to True.

Translations are based on this link: https://github.com/ikatyang/emoji-cheat-sheet and at the time of doing this PR, i have not added them all yet.

Checklist

Testing

Anyone can help test this source code as follows:

# Create a virtual environment to work in as follows:
python3 -m venv apprise

# Change into our new directory
cd apprise

# Activate our virtual environment
source bin/activate

# Install the branch
pip install git+https://github.com/caronc/apprise.git@649-emoji-support

# Test out the changes with the following command:
apprise -t ":smile:" -b ":grin:" --interpret-emojis
  <apprise url related to ticket>
codecov-commenter commented 7 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Comparison is base (a25ff00) 99.51% compared to head (cc7a4f2) 99.52%. Report is 1 commits behind head on master.

:exclamation: Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #1011 +/- ## ======================================= Coverage 99.51% 99.52% ======================================= Files 126 127 +1 Lines 16868 16881 +13 Branches 3457 3463 +6 ======================================= + Hits 16787 16800 +13 Misses 70 70 Partials 11 11 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

caronc commented 7 months ago

Everything seems to work as it should. It's now just adding all of the emoji's into the emojis.py file.

....This is going to take some time to do... it's a LOT of data entry. If anyone wants to help out, that would be great! :rocket: