aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeLines
...
| | | | * | | | | | | | | Fixing formatting for timedelta.Gravatar Shirayuki Nekomata2019-10-21-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Now it will only show the amount of days. - Quality of Life: Also show `day` instead of `days` when it's just 1 day.
| | | | * | | | | | | | | Update defcon.pyGravatar Shirayuki Nekomata2019-10-21-11/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Update docstrings for `build_defcon_msg()` and `send_defcon_log()` - It is now taking in an `Action` directly instead of a string.
| | | | * | | | | | | | | Update defcon.pyGravatar Shirayuki Nekomata2019-10-21-14/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Remove the unneccessary `get_info()` method of Enum `Action`. - Pass Enum `Action` directly to `build_defcon_msg()` and `send_defcon_log()` - Right now, only `_defcon_action()` is using them.
| | | | * | | | | | | | | Update defcon.pyGravatar Shirayuki Nekomata2019-10-21-22/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Renamed `DefconInfoLog` to `Action` - Added `ActionInfo` namedtuple. - Use `Action` consistently for `_defcon_action()` and `send_defcon_log()`
| | | | * | | | | | | | | Update defcon.pyGravatar Shirayuki Nekomata2019-10-19-63/+37
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Further unify defcon actions in `_defcon_action` - Thanks to Mark's suggestions. - Changed from a Dict to an Enum for defcon log info.
| | | | * | | | | | | | | Fix defcon having wrong text when disabling.Gravatar Shirayuki Nekomata2019-10-17-50/+46
| | | | | |_|_|_|_|_|_|/ | | | | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | #### Closes #539 This pull request fixes the issue for wrong status in the embed, as well as unifying certains if else to prevent similar future errors. Most notable code is here: ```python log_msg = f"**Staffer:** {actor} (`{actor.id}`)\n" if change.lower() == "enabled": icon = Icons.defcon_enabled color = Colours.soft_green status_msg = "DEFCON enabled" log_msg += f"**Days:** {self.days.days}\n\n" elif change.lower() == "disabled": icon = Icons.defcon_disabled color = Colours.soft_red status_msg = "DEFCON enabled" elif change.lower() == "updated": icon = Icons.defcon_updated color = Colour.blurple() status_msg = "DEFCON updated" log_msg += f"**Days:** {self.days.days}\n\n" ``` To remedy this issue, the class will now have a private class variable ```py _defcon_log_info: Dict[str, Tuple] = { 'enabled': (Icons.defcon_enabled, Colours.soft_green, "**Days:** {days}\n\n"), 'disabled': (Icons.defcon_disabled, Colours.soft_red, ""), 'updated': (Icons.defcon_updated, Colour.blurple(), "**Days:** {days}\n\n"), } ``` Another big change is the introduction of `_defcon_action` to unify the process all defcon actions has to go through: - Try to do the action. - Log error if there is any. - Send log message.
| | | | | | * | | | | | Modify in_channel_check to accept list of channelsGravatar Atul Mishra2019-10-22-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Update test cases for in_channel_check
| | | | | | * | | | | | Fix typo in channel nameGravatar Atul Mishra2019-10-21-1/+1
| | | | | | | | | | | |
| | | | | | * | | | | | Add #admin-spam channel to moderation channels listGravatar Atul Mishra2019-10-21-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Change doc string for cog_check method
| | | | | | * | | | | | Add missing channels to the configGravatar Atul Mishra2019-10-19-0/+2
| | | | | | | | | | | |
| | | | | | * | | | | | Add moderation channels check to cog_checkGravatar Atul Mishra2019-10-19-2/+11
| | | | | |/ / / / / / | | | | |/| | | | | |
| | | | | | * | | | | Substract one to now calculationGravatar Akarys422019-10-23-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Avoid aving `Your reminder will arrive in 59 minutes and 59 seconds!` instead of `Your reminder will arrive in 1 hour!`
| | | | | | * | | | | Update send_reminder message creationGravatar Akarys422019-10-21-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It is now truly backward compatible and use a more DRY method
| | | | | | * | | | | Merge branch 'master' of https://github.com/python-discord/bot into reminder-upGravatar Akarys422019-10-19-1998/+2072
| | | | | | |\ \ \ \ \ | |_|_|_|_|_|/ / / / / |/| | | | | | | | | |
* | | | | | | | | | | Fix rule alias. (#537)Gravatar scragly2019-10-16-6/+6
|\ \ \ \ \ \ \ \ \ \ \ | |_|_|_|/ / / / / / / |/| | | | | | | | | | Fix rule alias.
| * | | | | | | | | | Merge branch 'master' into rule-numGravatar scragly2019-10-16-45/+61
| |\ \ \ \ \ \ \ \ \ \ | |/ / / / / / / / / / |/| | | | | | | | | |
* | | | | | | | | | | Merge pull request #511 from python-discord/off-topic-checkGravatar Kieran Siek2019-10-15-45/+61
|\ \ \ \ \ \ \ \ \ \ \ | |_|_|_|/ / / / / / / |/| | | | | | | | | | Prevent too similar off-topic channel names
| * | | | | | | | | | Merge branch 'master' into off-topic-checkGravatar Kieran Siek2019-10-15-47/+230
| |\ \ \ \ \ \ \ \ \ \ | |/ / / / / / / / / / |/| | | | | | | | | |
| * | | | | | | | | | Merge branch 'master' into off-topic-checkGravatar kosayoda2019-10-15-1882/+2058
| |\ \ \ \ \ \ \ \ \ \ | | | |_|_|/ / / / / / | | |/| | | | | | | |
| * | | | | | | | | | Utilize __str__ of discord.Member in logging and outputGravatar kosayoda2019-10-12-47/+33
| | | | | | | | | | |
| * | | | | | | | | | Add !otn forceadd command.Gravatar kosayoda2019-10-11-0/+8
| | | | | | | | | | |
| * | | | | | | | | | Add check to !otn add to prevent too similar names.Gravatar kosayoda2019-10-11-2/+24
| | | | | | | | | | |
| | | * | | | | | | | Fix rule alias.Gravatar kosayoda2019-10-15-6/+6
| |_|/ / / / / / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Allow rule alias to take rule numbers, passes them to the `site rules` command. Rules are now 1-indexed to conform with the representation on the website.
| | | | | * | | | | Delete “confirmation echo”Gravatar Matteo Bertucci2019-10-07-1/+1
| | | | | | | | | |
| | | | | * | | | | Turn the jump URL into a clickable linkGravatar Matteo Bertucci2019-10-07-1/+1
| | | | | | | | | |
| | | | | * | | | | Fix my broken EnglishGravatar Matteo Bertucci2019-10-07-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Co-Authored-By: Sebastiaan Zeeff <[email protected]>
| | | | | * | | | | Merge branch 'reminder-up' of https://github.com/akarys42/bot into reminder-upGravatar Akarys422019-10-06-41/+388
| | | | | |\ \ \ \ \
| | | | | | * \ \ \ \ Merge branch 'master' into reminder-upGravatar Matteo Bertucci2019-10-06-41/+388
| | | | | | |\ \ \ \ \
| | | | | * | | | | | | Add line break between the reminder and the jump urlGravatar Akarys422019-10-06-1/+1
| | | | | |/ / / / / /
| | | | | * | | | | | Fix linting errorGravatar Matteo Bertucci2019-10-02-4/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix some liting error Correct error Fix linting (maybe)
| | | | | * | | | | | Merge branch 'master' into reminder-upGravatar Matteo Bertucci2019-09-30-13/+28
| | | | | |\ \ \ \ \ \
| | | | | * | | | | | | Add jump urlGravatar Matteo Bertucci2019-09-30-3/+6
| | | | | | | | | | | |
| | | | | * | | | | | | Add humanized delta and content to confirmation messageGravatar Akarys422019-09-29-1/+4
| | | | | | | | | | | |
| | | | | | | | * | | | Apply suggestions from review, and add correct webhook ID.Gravatar mathsman51332019-10-20-11/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - More informative docstrings for `Reddit.channel` and `get_top_posts` - Add the `amount` parameter, defaulting to 5. - Pin a max of 12 weeks worth of top posts.
| | | | | | | | * | | | Utilise `tasks.loop` and a webhook for reddit postingsGravatar mathsman51332019-10-15-147/+80
| |_|_|_|_|_|_|/ / / / |/| | | | | | | | | |
* | | | | | | | | | | Create the !mention command. (#493)Gravatar scragly2019-10-15-3/+58
|\ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Create the !mention command. Co-authored-by: null <[email protected]>
| * \ \ \ \ \ \ \ \ \ \ Merge branch 'master' into masterGravatar scragly2019-10-15-1948/+1951
| |\ \ \ \ \ \ \ \ \ \ \ | |/ / / / / / / / / / / |/| | | | | | | | | | |
* | | | | | | | | | | | Merge pull request #503 from avayert/masterGravatar Johannes Christ2019-10-14-4/+130
|\ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | Add raw command
| * | | | | | | | | | | | Implement a bypassable cooldown decoratorGravatar Ava2019-10-14-3/+50
| | | | | | | | | | | | |
| * | | | | | | | | | | | Small code review fixesGravatar Ava2019-10-11-3/+2
| | | | | | | | | | | | |
| * | | | | | | | | | | | Fix linting errorsGravatar Ava2019-10-08-7/+8
| | | | | | | | | | | | |
| * | | | | | | | | | | | Fix wrong importGravatar Ava2019-10-08-2/+1
| | | | | | | | | | | | |
| * | | | | | | | | | | | Add raw commandGravatar Ava2019-10-08-3/+83
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Closes #334
* | | | | | | | | | | | | Merge pull request #378 from larswijn/djangoGravatar Johannes Christ2019-10-14-44/+46
|\ \ \ \ \ \ \ \ \ \ \ \ \ | |_|_|_|/ / / / / / / / / |/| | | | | | | | | | | | Change pep command to use `.txt` by default
| * | | | | | | | | | | | Update utils.pyGravatar larswijn2019-10-13-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Switch around trying order (txt first, then rst)
| * | | | | | | | | | | | Completely re-submit fileGravatar larswijn2019-07-01-44/+46
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | to fix the write history of the file
| | | * | | | | | | | | | Use `bot.utils.humanize_delta`, tidy bot response, remove stray f from f-stringGravatar mathsman51332019-10-12-15/+5
| | | | | | | | | | | | |
| | | * | | | | | | | | | Update !mentionGravatar mathsman51332019-10-06-14/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Lock the role if the message wait has timed out - Sleep, lock role and send notification if mention by staff member found. - Lock role and send notification if mention by non-staff member found.
| | | * | | | | | | | | | fix linterGravatar mathsman51332019-10-05-1/+2
| | | | | | | | | | | | |
| | | * | | | | | | | | | properly send message with `asyncio.run`Gravatar mathsman51332019-10-05-3/+7
| | | | | | | | | | | | |