gh-slack icon indicating copy to clipboard operation
gh-slack copied to clipboard

Specify if a threaded message should fetch the channel instead

Open mwarkentin opened this issue 2 years ago • 2 comments

Hi, I'm back again. :)

It would be nice if there was a way to fetch the channel history starting with a message which was itself a thread - gh-slack seems to detect that it's a thread and only pull the thread content instead.

Example:

image

It seems like it would make sense to maintain that default functionality but having a way to specify that it should fetch the channel instead (--channel or --fetch-channel) would work?

I also have a bigger related request but I'll add that in a separate issue (#25).

mwarkentin avatar Dec 14 '22 15:12 mwarkentin

Welcome back!

Yes, you're right. The current behaviour is really just a simple method of getting what I wanted at the time. In practice I pretty much always archive threads, but perhaps that just works for me because that's the way we use Slack.

Actually there are some existing problems with the current heuristics, like if you try to fetch a message in a thread that isn't the first one, it isn't detected as being in a thread and then fetches some unrelated messages from around the same time from the channel :facepalm:

Bottom line: I would be completely open to options for fine-tuning the behaviour like you suggest. --channel sounds a bit like you might use it to specify the channel independently of the permalink, but apart from that is good. I like that it is shorter than --fetch-channel. If you want to make a PR I'll help review and get it over the line.

rneatherway avatar Dec 16 '22 14:12 rneatherway

Actually there are some existing problems with the current heuristics, like if you try to fetch a message in a thread that isn't the first one, it isn't detected as being in a thread and then fetches some unrelated messages from around the same time from the channel

This should be fixed now by #60

mwarkentin avatar Mar 15 '24 20:03 mwarkentin