开源软件名称(OpenSource Name):compufox/silence开源软件地址(OpenSource Url):https://github.com/compufox/silence开源编程语言(OpenSource Language):Ruby 100.0%开源软件介绍(OpenSource Introduction):silence"everything is so peaceful without all the gab" ;p installationif you plan on using this script in admin mode (see below for explanation) you won't need to install anything as it uses the gems that your mastodon installation uses. you will need bundler 2+, but you should already have that because you have mastodon installed. if you plan on using the script in user mode (see below for explanation) you'll need to clone (or download) this repo and run
in the folder, assuming you have ruby and bundler installed. usage
the script supports two modes: admin and user mode admin modeadmin mode is meant for server administrators as it creates server level blocks. to run in admin mode, you'll need to pass the option the script assumes the mastodon root folder is the parent folder (as in, this git repo is placed inside the mastodon root folder), however you can specify the relative path to the root folder by using the example usage: example usage setting envvar: note: silence will check if a domain is blocked already and will not attempt to block it if it already is. in mastodon v2.9.1+ subdomains are automatically blocked when the base domain is blocked. so if you notice that the script isnt blocking 'bad.gab.garbage' and you already have a block for 'gab.garbage' thats why! user modeuser mode is meant for typical users and creates domain blocks for that user this is the default mode for the script. on the first run you'll need to pass in an access token and an instance url after this first time the script will save this information so you don't have to re-run with those extra options if you don't know how to get a token, please read the next section example first run usage: example post first run usage: getting an access token
unsolicited advice from me~im just gonna add this script into my crontab, and i personally suggest you do too. if you're using admin mode, it might be easier to add oh! and before you run this in user-mode make sure you're admin isn't already using it. it won't hurt anything, just a bit redundent :p |
2023-10-27
2022-08-15
2022-08-17
2022-09-23
2022-08-13
请发表评论