From d7f209aeccab3c2d3ebc2a592df74688f11d7478 Mon Sep 17 00:00:00 2001 From: Paul van Tilburg Date: Fri, 20 May 2022 16:18:13 +0200 Subject: [PATCH] Add README.md and LICENSE file Also link the files from the crate and include `README.md` as the main crate documentation --- Cargo.toml | 2 +- LICENSE | 19 +++++++++++++++++++ README.md | 45 +++++++++++++++++++++++++++++++++++++++++++++ src/lib.rs | 4 ++-- src/main.rs | 4 ++-- 5 files changed, 69 insertions(+), 5 deletions(-) create mode 100644 LICENSE create mode 100644 README.md diff --git a/Cargo.toml b/Cargo.toml index 25a7deb..7f0e601 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" authors = ["Paul van Tilburg "] edition = "2021" description = "Web services to provide an podcast (RSS) interface for Mixcloud" -#readme = "README.md" +readme = "README.md" license = "MIT" [dependencies] diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..e3e706f --- /dev/null +++ b/LICENSE @@ -0,0 +1,19 @@ +The MIT License (MIT) +Copyright (c) 2018 Paul van Tilburg + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/README.md b/README.md new file mode 100644 index 0000000..b6a9318 --- /dev/null +++ b/README.md @@ -0,0 +1,45 @@ +# Podbringer + +Podbringer is a web service that provides podcasts for services that don't +offer them (anymore). It provides a way to get the RSS feed for your podcast +client and it facilites the downloads of the pods (enclosures). + +It currently only supports [Mixcloud](https://mixcloud.com). +Other back-ends might be added in the future. + +## Building & running + +Using Cargo, it is easy to build and run Podbringer, just run: + +```shell +$ cargo run --release +... + Compiling podbringer v0.1.0 (/path/to/podbringer) + Finished release [optimized] target(s) in 9m 26s + Running `/path/to/podbringer/target/release/podbringer` +``` + +(Note that Rocket listens on `127.0.0.1:8000` by default for debug builds, i.e. +builds when you don't add `--release`.) + +### Configuration + +For now, you will need to provide Rocket with configuration to tell it with which URL Podbringer is +reachable. Even if you are not using a reverse proxy, in which case you need to provide it with the +proxied URL. You can also use the configuration to configure a different address and/or port. +Just create a `Rocket.toml` file that contains (or copy `Rocket.toml.example`): + +```toml +[default] +address = "0.0.0.0" +port = 7062 +url = "https://my.domain.tld/podbringer" +``` + +This will work independent of the type of build. For more about Rocket's +configuration, see: . + +## License + +Podbringer is licensed under the MIT license (see the `LICENSE` file or +). diff --git a/src/lib.rs b/src/lib.rs index 22573d0..9ee9892 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -1,11 +1,11 @@ -// #![doc = include_str!("../README.md")] +#![doc = include_str!("../README.md")] #![warn( clippy::all, missing_debug_implementations, rust_2018_idioms, rustdoc::broken_intra_doc_links )] -// #![deny(missing_docs)] +#![deny(missing_docs)] use std::process::Stdio; diff --git a/src/main.rs b/src/main.rs index f495a30..9175b92 100644 --- a/src/main.rs +++ b/src/main.rs @@ -1,11 +1,11 @@ -// #![doc = include_str!("../README.md")] +#![doc = include_str!("../README.md")] #![warn( clippy::all, missing_debug_implementations, rust_2018_idioms, rustdoc::broken_intra_doc_links )] -// #![deny(missing_docs)] +#![deny(missing_docs)] use color_eyre::Result;