![version](https://img.shields.io/pypi/v/discord-pretty-help) ![python](https://img.shields.io/badge/python-3.8+-blue)
# discord-pretty-help
An embed version of the built-in help command for discord.py
Inspired by the DefaultHelpCommand that discord.py uses, but revised for embeds and additional sorting on individual pages that can be "scrolled" through.
## Installation
`pip install discord-pretty-help`
## Usage
Example of how to use it:
```python
from discord.ext import commands
from pretty_help import PrettyHelp
bot = commands.Bot(command_prefix="!", help_command=PrettyHelp())
```
### Added Optional Args
- `color` - Set the default embed color
- `delete_invoke` - Delete the message that invoked the help command. Requires message delete permission. Defaults is `False`
- `ending_note` - Set the footer of the embed. Ending notes are fed a `commands.Context` (`ctx`) and a `PrettyHelp` (`help`) instance for more advanced customization.
- `image_url` - The url of the image to be used on the embed
- `index_title` - Set the index page name default is *"Categories"*
- `menu` - The menu to use for navigating pages. Uses a `pretty_help.PrettyMenu()` instance. Default is `pretty_help.AppMenu()`
- `no_category` - Set the name of the page with commands not part of a category. Default is "*No Category*"
- `paginator`- The paginator to use. One is created by default.
- `send_typing` - A bool that indicates if the bot will send a typing indicator. Defaults to ``True``
- `show_index` - Show the index page or not
- `sort_commands` - Sort commands and categories alphabetically
- `thumbnail_url` - The url of the thumbnail to be used on the embed
## Menus
### pretty_help.EmojiMenu
- Uses Emojis to navigate
- `active_time` - Set the time (in seconds) that the message will be active. Default is 30s
- `delete_after_timeout` - Delete the message after `active_time` instead of removing reactions. Default `False`
- `page_left` - The emoji to use to page left
- `page_right` - The emoji to use to page right
- `remove` - The emoji to use to remove the help message
![example](/images/example-emoji.gif)
### pretty_help.AppMenu
- Uses Application Interactions (buttons) for navigating
- `timeout` - The duration the interaction will be active for. Defaults to `None`.
- `ephemeral` - Send as an ephemeral message. Defaults to `False`.
![example](/images/example-app.gif)
By default, the help will just pick a random color on every invoke. You can change this using the `color` argument:
### Example of using a different menu and customization:
```python
from discord.ext import commands
from pretty_help import EmojiMenu, PrettyHelp
# ":discord:743511195197374563" is a custom discord emoji format. Adjust to match your own custom emoji.
menu = EmojiMenu(page_left="\U0001F44D", page_right="👎", remove=":discord:743511195197374563", active_time=5)
# Custom ending note
ending_note = "The ending note from {ctx.bot.user.name}\nFor command {help.clean_prefix}{help.invoked_with}"
bot = commands.Bot(command_prefix="!")
bot.help_command = PrettyHelp(menu=menu, ending_note=ending_note)
```
The basic `help` command will break commands up by cogs. Each cog will be a different page. Those pages can be navigated.
![example](/images/example.gif)
# Changelog
## [2.0.0]
- Subcommands in pages are indicated with a 🔗, previously it was unclear they were sub commands of the page title
- Support Application commands
- Support for GroupCogs
- Navigation using discord interactions e.g. Buttons and select menus
# Notes:
- discord.py must already be installed to use this
- `manage-messages` permission is recommended so reactions can be removed automatically
## Forks for other discord.py based libraries (could be out of date):
* [nextcord-pretty-help](https://github.com/squigjess/nextcord-pretty-help)
Raw data
{
"_id": null,
"home_page": "https://github.com/casuallycalm/discord-pretty-help",
"name": "discord-pretty-help",
"maintainer": "",
"docs_url": null,
"requires_python": ">=3.8,<4.0",
"maintainer_email": "",
"keywords": "discord,discord.py,discord bot",
"author": "CasuallyCalm",
"author_email": "29642143+casuallycalm@users.noreply.github.com",
"download_url": "https://files.pythonhosted.org/packages/57/b0/944c1e318af82d2cd387d6570d72a4ea9482c78103f598addb48f460a471/discord_pretty_help-2.0.7.tar.gz",
"platform": null,
"description": "![version](https://img.shields.io/pypi/v/discord-pretty-help) ![python](https://img.shields.io/badge/python-3.8+-blue)\n\n# discord-pretty-help\n\nAn embed version of the built-in help command for discord.py\n\n\n\nInspired by the DefaultHelpCommand that discord.py uses, but revised for embeds and additional sorting on individual pages that can be \"scrolled\" through. \n\n## Installation\n\n`pip install discord-pretty-help`\n\n## Usage\n\nExample of how to use it:\n\n```python\nfrom discord.ext import commands\nfrom pretty_help import PrettyHelp\n\nbot = commands.Bot(command_prefix=\"!\", help_command=PrettyHelp())\n```\n\n\n\n### Added Optional Args\n\n- `color` - Set the default embed color\n- `delete_invoke` - Delete the message that invoked the help command. Requires message delete permission. Defaults is `False`\n- `ending_note` - Set the footer of the embed. Ending notes are fed a `commands.Context` (`ctx`) and a `PrettyHelp` (`help`) instance for more advanced customization.\n- `image_url` - The url of the image to be used on the embed\n- `index_title` - Set the index page name default is *\"Categories\"*\n- `menu` - The menu to use for navigating pages. Uses a `pretty_help.PrettyMenu()` instance. Default is `pretty_help.AppMenu()`\n- `no_category` - Set the name of the page with commands not part of a category. Default is \"*No Category*\"\n- `paginator`- The paginator to use. One is created by default.\n- `send_typing` - A bool that indicates if the bot will send a typing indicator. Defaults to ``True``\n- `show_index` - Show the index page or not\n- `sort_commands` - Sort commands and categories alphabetically\n- `thumbnail_url` - The url of the thumbnail to be used on the embed\n\n## Menus\n\n### pretty_help.EmojiMenu \n- Uses Emojis to navigate\n- `active_time` - Set the time (in seconds) that the message will be active. Default is 30s\n- `delete_after_timeout` - Delete the message after `active_time` instead of removing reactions. Default `False`\n- `page_left` - The emoji to use to page left\n- `page_right` - The emoji to use to page right\n- `remove` - The emoji to use to remove the help message\n\n![example](/images/example-emoji.gif)\n\n### pretty_help.AppMenu\n- Uses Application Interactions (buttons) for navigating\n- `timeout` - The duration the interaction will be active for. Defaults to `None`.\n- `ephemeral` - Send as an ephemeral message. Defaults to `False`.\n\n![example](/images/example-app.gif)\n\nBy default, the help will just pick a random color on every invoke. You can change this using the `color` argument:\n\n### Example of using a different menu and customization:\n\n```python\n\nfrom discord.ext import commands\nfrom pretty_help import EmojiMenu, PrettyHelp\n\n# \":discord:743511195197374563\" is a custom discord emoji format. Adjust to match your own custom emoji.\nmenu = EmojiMenu(page_left=\"\\U0001F44D\", page_right=\"\ud83d\udc4e\", remove=\":discord:743511195197374563\", active_time=5)\n\n# Custom ending note\nending_note = \"The ending note from {ctx.bot.user.name}\\nFor command {help.clean_prefix}{help.invoked_with}\"\n\nbot = commands.Bot(command_prefix=\"!\")\n\nbot.help_command = PrettyHelp(menu=menu, ending_note=ending_note)\n```\n\nThe basic `help` command will break commands up by cogs. Each cog will be a different page. Those pages can be navigated. \n\n![example](/images/example.gif)\n\n\n# Changelog\n\n## [2.0.0]\n - Subcommands in pages are indicated with a \ud83d\udd17, previously it was unclear they were sub commands of the page title\n - Support Application commands\n - Support for GroupCogs\n - Navigation using discord interactions e.g. Buttons and select menus \n\n\n# Notes:\n- discord.py must already be installed to use this\n- `manage-messages` permission is recommended so reactions can be removed automatically\n\n## Forks for other discord.py based libraries (could be out of date):\n* [nextcord-pretty-help](https://github.com/squigjess/nextcord-pretty-help)",
"bugtrack_url": null,
"license": "MIT",
"summary": "And nicer looking interactive help menu for discord.py",
"version": "2.0.7",
"project_urls": {
"Homepage": "https://github.com/casuallycalm/discord-pretty-help",
"Repository": "https://github.com/casuallycalm/discord-pretty-help"
},
"split_keywords": [
"discord",
"discord.py",
"discord bot"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "55037b5dd28b66a4db9ba02b4bdf2718b5b211e36ba44b76d5bd58c02009a4f5",
"md5": "ccb1c19b94b6b618703e4a3aeec78cd1",
"sha256": "ca8ee02bed8012b511fde57303d003c30c67d59b106f8afaa01bb7befad37990"
},
"downloads": -1,
"filename": "discord_pretty_help-2.0.7-py3-none-any.whl",
"has_sig": false,
"md5_digest": "ccb1c19b94b6b618703e4a3aeec78cd1",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.8,<4.0",
"size": 13606,
"upload_time": "2023-06-10T17:09:36",
"upload_time_iso_8601": "2023-06-10T17:09:36.904285Z",
"url": "https://files.pythonhosted.org/packages/55/03/7b5dd28b66a4db9ba02b4bdf2718b5b211e36ba44b76d5bd58c02009a4f5/discord_pretty_help-2.0.7-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "57b0944c1e318af82d2cd387d6570d72a4ea9482c78103f598addb48f460a471",
"md5": "1b541a804d66aef14d13767b42b050b8",
"sha256": "965154e4660be07a5050413d7ee7c3ea62a12d1b8d30b39741d23be2cfe4a748"
},
"downloads": -1,
"filename": "discord_pretty_help-2.0.7.tar.gz",
"has_sig": false,
"md5_digest": "1b541a804d66aef14d13767b42b050b8",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.8,<4.0",
"size": 11423,
"upload_time": "2023-06-10T17:09:38",
"upload_time_iso_8601": "2023-06-10T17:09:38.387462Z",
"url": "https://files.pythonhosted.org/packages/57/b0/944c1e318af82d2cd387d6570d72a4ea9482c78103f598addb48f460a471/discord_pretty_help-2.0.7.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2023-06-10 17:09:38",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "casuallycalm",
"github_project": "discord-pretty-help",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"lcname": "discord-pretty-help"
}