Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/devyukine/red_oxide
A CLI helping with uploading to Redacted, inspired by REDBetter
https://github.com/devyukine/red_oxide
cli flac mp3 redacted redbetter seedbox transcode
Last synced: 2 days ago
JSON representation
A CLI helping with uploading to Redacted, inspired by REDBetter
- Host: GitHub
- URL: https://github.com/devyukine/red_oxide
- Owner: DevYukine
- License: mit
- Created: 2023-04-15T18:12:43.000Z (almost 2 years ago)
- Default Branch: master
- Last Pushed: 2024-12-09T11:05:15.000Z (about 2 months ago)
- Last Synced: 2025-01-21T10:05:33.271Z (9 days ago)
- Topics: cli, flac, mp3, redacted, redbetter, seedbox, transcode
- Language: Rust
- Homepage:
- Size: 172 KB
- Stars: 128
- Watchers: 5
- Forks: 29
- Open Issues: 16
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# red_oxide
CLI to help uploading to REDacted, inspired by REDBetter.
## Installing
1. Install [intermodal](https://github.com/casey/intermodal#installation) and add it to your PATH
2. Install lame, sox & flac and add them to your PATH
3. download the latest release from [here](https://github.com/DevYukine/red_oxide/releases)## Usage
### CLI
#### Transcode subcommand (red_oxide transcode)
You have to specify api-key, torrent-directory, content-directory, transcode-directory & spectrogram-directory either via the config file or via the CLI
```
Transcode FLACs to other co-existing formatsUsage: red_oxide transcode [OPTIONS] [URLS]...
Arguments:
[URLS]... The Perma URLs (PL's) of torrents to transcodeOptions:
--debug
If debug logs should be shown
-a, --automatic-upload
If the upload should be done automatically
--concurrency
How many tasks (for transcoding as example) should be run in parallel, defaults to your CPU count
--api-key
The Api key from Redacted to use there API with
--content-directory
The path to the directory where the downloaded torrents are stored
--transcode-directory
The path to the directory where the transcoded torrents should be stored
--torrent-directory
The path to the directory where the torrents should be stored
--spectrogram-directory
The path to the directory where the spectrograms should be stored
-c, --config-file
The path to the config file
-f, --allowed-transcode-formats
List of allowed formats to transcode to, defaults to all formats if omitted [possible values: flac24, flac, mp3320, mp3-v0]
-m, --move-transcode-to-content
If the transcode should be moved to the content directory, useful when you want to start seeding right after you upload
--skip-hash-check
If the hash check of the original torrent should be skipped, defaults to false, not recommended and if enabled done at own risk!
--skip-spectrogram
If the spectrogram check of the original torrent should be skipped, defaults to false, not recommended and if enabled done at own risk!
-d, --dry-run
If this is a dry run, no files will be uploaded to Redacted
-h, --help
Print help```
### Config file
This is useful if you don't want a super long CLI command and your configs do not change often, note that all the options can be specified via the CLI as well and are fully optional in this config file (will be merged with the CLI options if specified)
There are multiple default locations where the config file will be searched for, in this order (once found it will not look for the config file in the other locations):
1. The path specified via the --config-file CLI option
2. `./red_oxide.config.json` (In the same folder as the red_oxide executable)
3. `%APPDATA%/red_oxide/red_oxide.config.json` (only on Windows)
4. `$XDG_CONFIG_HOME/red_oxide/red_oxide.config.json`
5. `HOME/.config/red_oxide/red_oxide.config.json`
6. `HOME/red_oxide.config.json`HOME is determined by these environment variables on Windows in this order:
1. `%HOME%`
2. `%USERPROFILE%`
3. `%HOMEDRIVE%\%HOMEPATH%`HOME is determined by these environment variables on Linux in this order:
1. `$HOME````json
{
"api_key": "YOUR_API_KEY",
"torrent_directory": "FULL_PATH_WHERE_TORRENT_FILES_WILL_BE_STORED",
"content_directory": "FULL_PATH_WHERE_CONTENT_IS_LOCATED",
"transcode_directory": "FULL_PATH_WHERE_TRANSCODED_CONTENT_WILL_BE_PUT",
"spectrogram_directory": "FULL_PATH_WHERE_SPECTROGRAMS_WILL_BE_PUT",
"move_transcode_to_content": true,
"automatic_upload": true,
"skip_hash_check": false,
"skip_spectrogram": false,
"allowed_transcode_formats": ["Flac", "Mp3320", "Mp3V0"],
"concurrency": 16
}```
### Notes for people using sox under windows
if you use the binaries from [here](https://sourceforge.net/projects/sox/files/sox/), and you want utf-8 support for paths (this is needed for Japanese/Chinese/Korean names in paths for example) you have to download the files from [here](https://raw.githubusercontent.com/DevYukine/red_oxide/master/.github/dependency-fixes/sox_windows_fix.zip) and follow the steps below
1. Extract the files from the zip
2. Run the PreferExternalManifest.reg file and let it overwrite the registry entry
3. Copy the sox.exe.manifest file to the folder where sox.exe is located
4. Enjoy sox working with utf-8 paths :)## Built With
- [Rust](https://www.rust-lang.org/) - The language used
- [clap](https://github.com/clap-rs/clap) - CLI Framework
- [tokio](https://tokio.rs/) - Async runtime
- [reqwest](https://github.com/seanmonstar/reqwest) - HTTP client
- [serde](https://serde.rs/) - Serialization/Deserialization
- [intermodal](https://github.com/casey/intermodal) - Used for Torrent Hash checking & creation
- [audiotags](https://docs.rs/audiotags/latest/audiotags/) - Reading/Writing Audio Metadata## Contributing
Please read [CONTRIBUTING.md](CONTRIBUTING.md) for details on our code
of conduct, and the process for submitting pull requests to us.## Versioning
We use [Semantic Versioning](http://semver.org/) for versioning. For the versions
available, see the [tags on this
repository](https://github.com/DevYukine/red_oxide/tags).## Authors
- **[DevYukine](https://github.com/DevYukine)** - *Initial Work*
See also the list of
[contributors](https://github.com/DevYukine/red_oxide/contributors)
who participated in this project.## License
This project is licensed under the [MIT](LICENSE) See the [LICENSE.md](LICENSE) file for details