Emoji
=====
Emoji for Python. This project was inspired by `kyokomi <https://github.com/kyokomi/emoji>`__.
Example
-------
The entire set of Emoji codes as defined by the `Unicode consortium <https://unicode.org/emoji/charts/full-emoji-list.html>`__
is supported in addition to a bunch of `aliases <https://www.webfx.com/tools/emoji-cheat-sheet/>`__. By
default, only the official list is enabled but doing ``emoji.emojize(language='alias')`` enables
both the full list and aliases.
.. code-block:: python
>>> import emoji
>>> print(emoji.emojize('Python is :thumbs_up:'))
Python is 👍
>>> print(emoji.emojize('Python is :thumbsup:', language='alias'))
Python is 👍
>>> print(emoji.demojize('Python is 👍'))
Python is :thumbs_up:
>>> print(emoji.emojize("Python is fun :red_heart:"))
Python is fun ❤
>>> print(emoji.emojize("Python is fun :red_heart:", variant="emoji_type"))
Python is fun ❤️ #red heart, not black heart
>>> print(emoji.is_emoji("👍"))
True
..
By default, the language is English (``language='en'``) but also supported languages are:
* Spanish (``'es'``)
* Portuguese (``'pt'``)
* Italian (``'it'``)
* French (``'fr'``)
* German (``'de'``)
* Farsi/Persian (``'fa'``)
* Indonesian (``'id'``)
* Simplified Chinese (``'zh'``)
* Japanese (``'ja'``)
* Korean (``'ko'``)
* Russian (``'ru'``)
* Arabic (``'ar'``)
* Turkish (``'tr'``)
.. code-block:: python
>>> print(emoji.emojize('Python es :pulgar_hacia_arriba:', language='es'))
Python es 👍
>>> print(emoji.demojize('Python es 👍', language='es'))
Python es :pulgar_hacia_arriba:
>>> print(emoji.emojize("Python é :polegar_para_cima:", language='pt'))
Python é 👍
>>> print(emoji.demojize("Python é 👍", language='pt'))
Python é :polegar_para_cima:️
..
Installation
------------
Via pip:
.. code-block:: console
$ python -m pip install emoji --upgrade
From master branch:
.. code-block:: console
$ git clone https://github.com/carpedm20/emoji.git
$ cd emoji
$ python -m pip install .
Developing
----------
.. code-block:: console
$ git clone https://github.com/carpedm20/emoji.git
$ cd emoji
$ python -m pip install -e .\[dev\]
$ pytest
$ coverage run -m pytest
$ coverage report
The ``utils/get_codes_from_unicode_emoji_data_files.py`` is used to generate
``unicode_codes/data_dict.py``. Generally speaking it scrapes a table on the
`Unicode Consortium's website <https://www.unicode.org/reports/tr51/#emoji_data>`__
with `BeautifulSoup <http://www.crummy.com/software/BeautifulSoup/>`__
and prints the contents to ``stdout`` as a Python dictionary. For more
information take a look in the `utils/README.md <utils/README.md>`__ file.
Links
-----
**Documentation**
`https://carpedm20.github.io/emoji/docs/ <https://carpedm20.github.io/emoji/docs/>`__
**Overview of all emoji:**
`https://carpedm20.github.io/emoji/ <https://carpedm20.github.io/emoji/>`__
(auto-generated list of the emoji that are supported by the current version of this package)
**For English:**
`Emoji Cheat Sheet <https://www.webfx.com/tools/emoji-cheat-sheet/>`__
`Official Unicode list <http://www.unicode.org/emoji/charts/full-emoji-list.html>`__
**For Spanish:**
`Unicode list <https://emojiterra.com/es/lista-es/>`__
**For Portuguese:**
`Unicode list <https://emojiterra.com/pt/lista/>`__
**For Italian:**
`Unicode list <https://emojiterra.com/it/lista-it/>`__
**For French:**
`Unicode list <https://emojiterra.com/fr/liste-fr/>`__
**For German:**
`Unicode list <https://emojiterra.com/de/liste/>`__
Authors
-------
Taehoon Kim / `@carpedm20 <http://carpedm20.github.io/about/>`__
Kevin Wurster / `@geowurster <http://twitter.com/geowurster/>`__
Maintainer
----------
Tahir Jalilov / `@TahirJalilov <https://github.com/TahirJalilov>`__
Raw data
{
"_id": null,
"home_page": "https://github.com/carpedm20/emoji/",
"name": "emoji",
"maintainer": null,
"docs_url": null,
"requires_python": "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,>=2.7",
"maintainer_email": null,
"keywords": "emoji",
"author": "Taehoon Kim, Kevin Wurster",
"author_email": "carpedm20@gmail.com",
"download_url": "https://files.pythonhosted.org/packages/43/a7/933168bceefda3b3c16bbcc1d9aee82273b3b983995fd4672f7d107d490b/emoji-2.11.1.tar.gz",
"platform": null,
"description": "Emoji\n=====\n\nEmoji for Python. This project was inspired by `kyokomi <https://github.com/kyokomi/emoji>`__.\n\n\nExample\n-------\n\nThe entire set of Emoji codes as defined by the `Unicode consortium <https://unicode.org/emoji/charts/full-emoji-list.html>`__\nis supported in addition to a bunch of `aliases <https://www.webfx.com/tools/emoji-cheat-sheet/>`__. By\ndefault, only the official list is enabled but doing ``emoji.emojize(language='alias')`` enables\nboth the full list and aliases.\n\n.. code-block:: python\n\n >>> import emoji\n >>> print(emoji.emojize('Python is :thumbs_up:'))\n Python is \ud83d\udc4d\n >>> print(emoji.emojize('Python is :thumbsup:', language='alias'))\n Python is \ud83d\udc4d\n >>> print(emoji.demojize('Python is \ud83d\udc4d'))\n Python is :thumbs_up:\n >>> print(emoji.emojize(\"Python is fun :red_heart:\"))\n Python is fun \u2764\n >>> print(emoji.emojize(\"Python is fun :red_heart:\", variant=\"emoji_type\"))\n Python is fun \u2764\ufe0f #red heart, not black heart\n >>> print(emoji.is_emoji(\"\ud83d\udc4d\"))\n True\n\n..\n\nBy default, the language is English (``language='en'``) but also supported languages are:\n\n* Spanish (``'es'``)\n* Portuguese (``'pt'``)\n* Italian (``'it'``)\n* French (``'fr'``)\n* German (``'de'``)\n* Farsi/Persian (``'fa'``)\n* Indonesian (``'id'``)\n* Simplified Chinese (``'zh'``)\n* Japanese (``'ja'``)\n* Korean (``'ko'``)\n* Russian (``'ru'``)\n* Arabic (``'ar'``)\n* Turkish (``'tr'``)\n\n\n.. code-block:: python\n\n >>> print(emoji.emojize('Python es :pulgar_hacia_arriba:', language='es'))\n Python es \ud83d\udc4d\n >>> print(emoji.demojize('Python es \ud83d\udc4d', language='es'))\n Python es :pulgar_hacia_arriba:\n >>> print(emoji.emojize(\"Python \u00e9 :polegar_para_cima:\", language='pt'))\n Python \u00e9 \ud83d\udc4d\n >>> print(emoji.demojize(\"Python \u00e9 \ud83d\udc4d\", language='pt'))\n Python \u00e9 :polegar_para_cima:\ufe0f\n\n..\n\nInstallation\n------------\n\nVia pip:\n\n.. code-block:: console\n\n $ python -m pip install emoji --upgrade\n\nFrom master branch:\n\n.. code-block:: console\n\n $ git clone https://github.com/carpedm20/emoji.git\n $ cd emoji\n $ python -m pip install .\n\n\nDeveloping\n----------\n\n.. code-block:: console\n\n $ git clone https://github.com/carpedm20/emoji.git\n $ cd emoji\n $ python -m pip install -e .\\[dev\\]\n $ pytest\n $ coverage run -m pytest\n $ coverage report\n\nThe ``utils/get_codes_from_unicode_emoji_data_files.py`` is used to generate\n``unicode_codes/data_dict.py``. Generally speaking it scrapes a table on the\n`Unicode Consortium's website <https://www.unicode.org/reports/tr51/#emoji_data>`__\nwith `BeautifulSoup <http://www.crummy.com/software/BeautifulSoup/>`__\nand prints the contents to ``stdout`` as a Python dictionary. For more\ninformation take a look in the `utils/README.md <utils/README.md>`__ file.\n\n\nLinks\n-----\n\n**Documentation**\n\n`https://carpedm20.github.io/emoji/docs/ <https://carpedm20.github.io/emoji/docs/>`__\n\n**Overview of all emoji:**\n\n`https://carpedm20.github.io/emoji/ <https://carpedm20.github.io/emoji/>`__\n\n(auto-generated list of the emoji that are supported by the current version of this package)\n\n**For English:**\n\n`Emoji Cheat Sheet <https://www.webfx.com/tools/emoji-cheat-sheet/>`__\n\n`Official Unicode list <http://www.unicode.org/emoji/charts/full-emoji-list.html>`__\n\n**For Spanish:**\n\n`Unicode list <https://emojiterra.com/es/lista-es/>`__\n\n**For Portuguese:**\n\n`Unicode list <https://emojiterra.com/pt/lista/>`__\n\n**For Italian:**\n\n`Unicode list <https://emojiterra.com/it/lista-it/>`__\n\n**For French:**\n\n`Unicode list <https://emojiterra.com/fr/liste-fr/>`__\n\n**For German:**\n\n`Unicode list <https://emojiterra.com/de/liste/>`__\n\n\nAuthors\n-------\n\nTaehoon Kim / `@carpedm20 <http://carpedm20.github.io/about/>`__\n\nKevin Wurster / `@geowurster <http://twitter.com/geowurster/>`__\n\nMaintainer\n----------\nTahir Jalilov / `@TahirJalilov <https://github.com/TahirJalilov>`__\n",
"bugtrack_url": null,
"license": "New BSD",
"summary": "Emoji for Python",
"version": "2.11.1",
"project_urls": {
"Homepage": "https://github.com/carpedm20/emoji/"
},
"split_keywords": [
"emoji"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "bd48508a980e9c9f12dbc2e45e57f027abdd92320e5be37c5c551588a86acb48",
"md5": "e6d733cf3bdc08da469d4231cb3dec24",
"sha256": "b7ba25299bbf520cc8727848ae66b986da32aee27dc2887eaea2bff07226ce49"
},
"downloads": -1,
"filename": "emoji-2.11.1-py2.py3-none-any.whl",
"has_sig": false,
"md5_digest": "e6d733cf3bdc08da469d4231cb3dec24",
"packagetype": "bdist_wheel",
"python_version": "py2.py3",
"requires_python": "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,>=2.7",
"size": 433814,
"upload_time": "2024-04-21T07:57:57",
"upload_time_iso_8601": "2024-04-21T07:57:57.978833Z",
"url": "https://files.pythonhosted.org/packages/bd/48/508a980e9c9f12dbc2e45e57f027abdd92320e5be37c5c551588a86acb48/emoji-2.11.1-py2.py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "43a7933168bceefda3b3c16bbcc1d9aee82273b3b983995fd4672f7d107d490b",
"md5": "9b2aff6ea004c07e564dedf06de7987b",
"sha256": "062ff0b3154b6219143f8b9f4b3e5c64c35bc2b146e6e2349ab5f29e218ce1ee"
},
"downloads": -1,
"filename": "emoji-2.11.1.tar.gz",
"has_sig": false,
"md5_digest": "9b2aff6ea004c07e564dedf06de7987b",
"packagetype": "sdist",
"python_version": "source",
"requires_python": "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,>=2.7",
"size": 441576,
"upload_time": "2024-04-21T07:58:00",
"upload_time_iso_8601": "2024-04-21T07:58:00.031733Z",
"url": "https://files.pythonhosted.org/packages/43/a7/933168bceefda3b3c16bbcc1d9aee82273b3b983995fd4672f7d107d490b/emoji-2.11.1.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-04-21 07:58:00",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "carpedm20",
"github_project": "emoji",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"lcname": "emoji"
}