Commit Graph

11 Commits

Author SHA1 Message Date
Anna Schumaker f517f8c391 Implement a single fetch_messages() function
Rather than having each thread type define its own fetch history method,
let's instead have them tell us what api call to use to avoid
duplicating work

Signed-off-by: Anna Schumaker <Anna@NoWheyCreamery.com>
2016-11-22 08:47:03 -05:00
Anna Schumaker a88669d5e4 Preserve the last seen timestamp
So that we can mark posts from bots as read.  Otherwise we could end up
sending empty messages until another human posts.

Signed-off-by: Anna Schumaker <Anna@NoWheyCreamery.com>
2016-11-22 08:35:13 -05:00
Anna Schumaker 867b1edb24 Improve slackpost script
I also enable posting to IMs and return any error that we receive when
attempting to post.

Signed-off-by: Anna Schumaker <Anna@NoWheyCreamery.com>
2016-11-17 10:29:39 -05:00
Anna Schumaker 3027ec5ba7 Add support for fetching direct messages
Signed-off-by: Anna Schumaker <Anna@NoWheyCreamery.com>
2016-11-16 15:52:42 -05:00
Anna Schumaker 2779e13692 Add channel url to slack email
This gives us a link directly to the channel to read messages there.

Signed-off-by: Anna Schumaker <Anna@OcarinaProject.net>
2016-11-16 09:39:46 -05:00
Anna Schumaker adbfd6d2d6 Filter out empty messages
It's not enough to check for None, we also need to check that there is
actually text in the message.

Signed-off-by: Anna Schumaker <Anna@OcarinaProject.net>
2016-11-16 09:14:31 -05:00
Anna Schumaker 3c264554d8 Message handling fixes
Don't create a message object for posts without text.  Additionally, use
the accepted character replacements for unicode characters.

Signed-off-by: Anna Schumaker <Anna@OcarinaProject.net>
2015-09-04 14:19:13 -04:00
Anna Schumaker c5e15161bd slackpost: Updates for current email formatting
- Look for thread= lines
- Support posting to both channels and private groups

Signed-off-by: Anna Schumaker <Anna@OcarinaProject.net>
2015-06-16 11:06:03 -04:00
Anna Schumaker ca89d98e3a Add support for reading messages through the Thread class
Signed-off-by: Anna Schumaker <Anna@OcarinaProject.net>
2015-06-09 10:22:58 -04:00
Anna Schumaker 6859f8c3ec Add Group class
And pull more things out of the Channel class and into the Thread class.

Signed-off-by: Anna Schumaker <Anna@OcarinaProject.net>
2015-06-09 09:57:25 -04:00
Anna Schumaker fcd2789c29 Create a new Thread class
I want to create a generic class to represent (public) channels and
(private) groups.

Signed-off-by: Anna Schumaker <Anna@OcarinaProject.net>
2015-06-09 09:34:33 -04:00