Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Delete From Only One Channel? #17

Closed
Errora403 opened this issue Jun 8, 2019 · 11 comments
Closed

Delete From Only One Channel? #17

Errora403 opened this issue Jun 8, 2019 · 11 comments
Labels
enhancement New feature or request

Comments

@Errora403
Copy link

How can I use this script to delete messages from one specific server channel only?

@cedws
Copy link
Owner

cedws commented Jun 9, 2019

There's no functionality to do this in the tool, since it would require finding various IDs which wouldn't be user friendly. There is a way you could do this though. If you follow the instructions for a full deletion, but delete the files (from the data archive) which contain messages from other channels, it will delete only the ones you leave behind.
I'm planning to build a browser extension to delete messages, and it will probably include the ability to delete messages from particular channels.

@Errora403
Copy link
Author

Can I find the specific channel folder, ZIP it and refer to it when executing that command?

@Errora403 Errora403 reopened this Jun 9, 2019
@cedws
Copy link
Owner

cedws commented Jun 10, 2019

Sorry, yes, I forgot that it will automatically extract the ZIP. As long as you retain the same structure of files when you ZIP it back up, it will delete from the channels left behind as you want it to.

@Errora403
Copy link
Author

Just to clarify, can I move a specific channel folder to a different location, and ZIP only that one folder? Will that work to delete messages from only that channel?

bilde

bilde

@cedws
Copy link
Owner

cedws commented Jun 10, 2019

You can do that, but you need to retain the original structure of the ZIP file. So you'll need to have a messages directory inside, and then that should contain a numbered folder containing channel.json and messages.csv.

@cedws
Copy link
Owner

cedws commented Jun 10, 2019

Yeah, this is stupid, sorry. I'm going to add basic whitelist/blacklist parameters for this use case.

@cedws
Copy link
Owner

cedws commented Jun 10, 2019

If you get the new version of the script now, you can use -w/--whitelist and specify the ID you've found here. That'll ensure only messages are deleted from that channel. Your command will look something like:
./discord-delete.py full -p [PATH] -w 276837249075773460

@cedws cedws added the enhancement New feature or request label Jun 10, 2019
@Errora403
Copy link
Author

Wow. This is awesome. Thank you.

@ylluminarious
Copy link

@cedws Does this whitelist feature still work in the new Go implementation? I tried to use it, but it says: Error: unknown flag: --whitelist

@cedws
Copy link
Owner

cedws commented Oct 15, 2020

@cedws Does this whitelist feature still work in the new Go implementation? I tried to use it, but it says: Error: unknown flag: --whitelist

Hey. Sorry, the Go version doesn't have this feature. You can still get the Python version from Releases or the PythonImpl branch, not sure if it still works.

@ylluminarious
Copy link

@cedws Okay, thanks for letting me know. I ended up using this tool instead: https://github.com/victornpb/deleteDiscordMessages

It would still be nice to have a CLI version, though. So I hope you'll consider re-adding this feature to the Go implementation 🙂

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants