aboutsummaryrefslogtreecommitdiffstats
path: root/wee_slack.py
Commit message (Collapse)AuthorAgeFilesLines
* Support sending reactions with emoji charactersTrygve Aaberge2020-02-011-7/+23
| | | | Fixes #236, fixes #575
* Render emojis as emoji charactersTrygve Aaberge2020-02-011-9/+38
| | | | Fixes #465
* Print error message when reaction couldn't be added/removedTrygve Aaberge2020-01-231-1/+17
|
* Set members correctly in handle_conversationsmembersTrygve Aaberge2020-01-231-3/+2
| | | | | Because this sat channel.members directly instead of calling set_members, the nicklist wasn't updated.
* Set channel.is_member when channel is createdTrygve Aaberge2020-01-221-0/+1
| | | | | | | | | The channel dict sent as kwargs to SlackChannel from handle_rtmstart contains the is_member property. However the one from process_channel_created doesn't. Since you never are a member when the channel is created, we can set it to false (if you create the channel yourself or is invited immediately a channel_joined message will follow the channel_created message).
* Support using a different color for each thread suffix/prefixTrygve Aaberge2020-01-221-8/+20
| | | | Fixes #716
* Fetch members explicitly for SlackPrivateChannelTrygve Aaberge2020-01-221-0/+7
| | | | | | | | | | | Like SlackSharedChannel, SlackPrivateChannel doesn't include members in the result from rtm.start, and we have to use conversations.info for them which doesn't include members either. Therefore, we have to call conconversations.members. I hadn't noticed that the members were missing because I only tested with channels with a short backlog, so the members were filled by the join messages which were still present in the history that were fetched.
* Use GitHub Pages for the OAuth redirect pageTrygve Aaberge2020-01-221-9/+10
| | | | | | This adds a page which shows the OAuth code, and sets the redirect_uri for the OAuth link to this page. This url includes # at the end so the OAuth code is only seen by the browser, and not sent to the server.
* Release v2.4.0v2.4.0Trygve Aaberge2020-01-161-2/+2
|
* Add a command to list the Slack teamsTrygve Aaberge2019-10-161-0/+13
| | | | | This can be used when you want to remove a team, so you know which token to remove.
* Use max of submessages and replies for number_of_repliesTrygve Aaberge2019-10-031-1/+1
| | | | | | | | | When new replies come in over websocket, we don't update the message_json of the parent message with the new replies, we just append the new message to the submessages list. Therefore, the number_of_replies function has to check both of these and take the max. Fixes #722
* Add basic support for private channels converted from publicTrygve Aaberge2019-10-011-11/+51
| | | | | | | | | | | | | | | | | | This is for channels which initially were public, but then are changed to private. They look the same as groups (channels initially created as private) in the official clients, but can only be used with the conversations api. They are listed in the channels list of rtm.start with is_private set to true. There are some remaining issues, which are documented in the readme. I'm not sure if we can support read sync and showing unread on load without changes from Slack to the API. Showing thread messages in the channel is possible to fix, but we would have to send requests to load the thread history for all the messages in the history that has replies. Fixes most of #644
* Print thread broadcast messages in parent channelTrygve Aaberge2019-10-011-3/+8
| | | | Fixes #620
* Print user friendly error in handle_conversationsmembersTrygve Aaberge2019-08-261-2/+7
| | | | Fixes parts of #714
* Fix process_subteam_created after adding is_member to SlackSubteamTrygve Aaberge2019-08-251-2/+3
| | | | | | | | This was broken in commit 6f9339b. I haven't verified that is_member is set to the correct value when a user group is created, because I don't have access to a slack team where I can create user groups right know.
* Show if user is external in /slack usersTrygve Aaberge2019-08-251-2/+9
|
* Don't list dms and mpdms in /slack channelsTrygve Aaberge2019-08-251-1/+2
|
* Add the usergroups you are a member of to highlight wordsTrygve Aaberge2019-08-251-11/+23
| | | | | | Also shows if you are a member or not in the command /slack usergrous. Fixes #272, fixes #367, fixes #542
* Add nicks without @ prefix to nick completionTrygve Aaberge2019-08-251-0/+1
| | | | | This allows you to complete nicks without a leading @ in buffers we don't show the nicklist, i.e. the team buffer and thread buffers.
* Complete all nicks on the team for some commandsTrygve Aaberge2019-08-251-1/+7
|
* Add support for the /invite commandTrygve Aaberge2019-08-251-0/+48
| | | | Fixes #698
* Linkify users in /slack slash commandTrygve Aaberge2019-08-251-3/+4
| | | | | | | | If we don't linkify users, only usernames (which are not shown anymore) are accepted by the chat.command endpoint, not display names. It does accept user links, so we can use that. However, it doesn't seem to accept channel links (at least the invite command, which is what I tested), so we only linkify users.
* Print responses and errors from /slack slash commandTrygve Aaberge2019-08-251-1/+16
| | | | Fixes #369, fixes #374
* Replace weechat with w a few placesTrygve Aaberge2019-08-251-7/+7
| | | | We should always use w, so we go through the WeechatWrapper.
* Match all channel and user prefixes in unfurl_refsTrygve Aaberge2019-08-251-4/+4
| | | | | | I don't know all the possible prefixes, and I don't think it's a problem to just match # and @. The prefixes I've seen for channels are #C, #D and #G, and for users @U and @W.
* Refactor linkify_text to use re.subTrygve Aaberge2019-08-251-27/+20
| | | | | Instead of splitting the message at spaces and checking and replacing each word, use re.sub for the whole message.
* Support @everyone in linkify_textTrygve Aaberge2019-08-251-1/+1
|
* Refactor unfurl_refs to use re.subTrygve Aaberge2019-08-251-36/+31
| | | | | Instead of finding each match and calling replace on the text with that match, use re.sub to replace all the matches.
* Include @channel, @everyone and @here in usergroup completionTrygve Aaberge2019-08-251-2/+3
| | | | | | | | @group isn't mentioned in the documentation[0], and is changed to @channel if you try to complete it in the web client, so it probably shouldn't be used anymore. [0]: https://get.slack.help/hc/en-us/articles/202009646-Notify-a-channel-or-workspace
* Render group notifications with @ instead of !Trygve Aaberge2019-08-251-2/+4
| | | | | | | | | This is for the notifications @channel, @everyone, @group and @here. @group isn't mentioned in the documentation[0], but it is still rendered as a highlight in the web client, so I included it. [0]: https://get.slack.help/hc/en-us/articles/202009646-Notify-a-channel-or-workspace
* Print error in /part command when channel is not foundTrygve Aaberge2019-08-251-0/+2
|
* Include channel prefix in key in get_channel_mapTrygve Aaberge2019-08-251-7/+7
| | | | Fixes #587
* Include @ in subteam handleTrygve Aaberge2019-08-251-17/+15
| | | | Subteams/usergroups should never be used without the @.
* Extract printing user/channel info to a shared functionTrygve Aaberge2019-08-251-22/+22
|
* Show handle when listing usergroup membersTrygve Aaberge2019-08-251-2/+2
|
* Show member status in /slack channels commandTrygve Aaberge2019-08-251-1/+7
|
* Use name instead of slack_name in /slack channels commandTrygve Aaberge2019-08-251-2/+2
| | | | This includes the prefix that shows the channel type.
* Support nicks prefixed with @ in /msg commandTrygve Aaberge2019-08-241-1/+1
|
* Don't add deleted users to tab completionTrygve Aaberge2019-08-071-1/+1
| | | | Fixes #703
* Add option to only use full namesTrygve Aaberge2019-08-071-1/+10
| | | | Fixes #100
* Fallback to full name if display name is not setTrygve Aaberge2019-08-071-1/+1
| | | | | | | The username can't be changed by the users themselves now and is auto generated for new users, so we shouldn't use it. Only use username as a last resort if neither display name nor full name is set (I'm not sure this ever happens, it looks like the full name field is mandatory).
* Fix attachment fields without titlesDavid Vo2019-07-221-1/+1
| | | | | | | | | | | | | | | | | | | | Attachment fields are not guaranteed to have a title at all. This fixes in particular slackbot app approval messages, with an attachment like so: { "callback_id": "whitelist_A11BCGM0E_181389840855", "fields": [ { "short": true, "value": ":white_check_mark: *<@U4RPXA42F|davo> approved this app for the team.*" } ], "fallback": "Approve or deny the application", "id": 4, "color": "#2ab27b" }
* Set localvar_set_server for thread buffersTrygve Aaberge2019-06-201-0/+1
|
* Expose more information in /whois (#700)David Vo2019-06-151-3/+14
| | | Also hide any unset fields.
* Ignore away command run on non-slack buffers without -allTrygve Aaberge2019-06-141-1/+3
| | | | | This prevents printing an error when running /away without -all on buffers other than slack buffers.
* Sort nicks in mpdm name alphabeticallyTrygve Aaberge2019-06-121-2/+2
|
* Don't include own nick in mpdm namesTrygve Aaberge2019-06-121-3/+4
|
* Support topic changes for private channelsTrygve Aaberge2019-06-121-9/+10
| | | | Fixes #697
* Remove log* tags when using no_logTrygve Aaberge2019-06-111-8/+7
| | | | | When including both a log tag and a no_log tag, the message may be logged.
* new_messages should not be set for backlog messages, but for self_msgsTrygve Aaberge2019-06-111-3/+3
| | | | | | | | There are scenarios where last_read isn't set, and only self messages are printed. I experienced it when the only message in the channel was me joining and renaming the channel. In that case, last_read were never set, so we should set new_messages for our own messages so last_read will be set.