From 99d1b7cab56e432c8822ce4160c1622ad5478849 Mon Sep 17 00:00:00 2001 From: gilcu3 <828241+gilcu3@users.noreply.github.com> Date: Tue, 2 Jul 2024 16:08:00 +0200 Subject: [PATCH 1/5] first release --- CHANGELOG.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index d5fb2e3..c38ae1f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,5 @@ # Changelog -## v0.1.0 (2024/05/20) +## v0.1.0 (2024/07/02) -- Initial fork +- Initial release From 14db66aaa7be8464a095cc95c1131a60edec9b6c Mon Sep 17 00:00:00 2001 From: gilcu3 <828241+gilcu3@users.noreply.github.com> Date: Tue, 23 Jul 2024 09:58:16 +0200 Subject: [PATCH 2/5] upd README --- README.md | 22 ++++++++++++++-------- 1 file changed, 14 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index 2d73bf5..a43361b 100644 --- a/README.md +++ b/README.md @@ -48,9 +48,23 @@ features stated below, while learning `rust` at the same time. - [ ] Add option to play next from queue automatically - [ ] Add history of episode actions - [ ] Avoid repeated elements in queue +- [ ] Fix bug where queue actions are not persistent, hard to reproduce +- [ ] Fix gpodder test, it should use local files ## Installing hullcaster +### Archlinux + +The package is available in the `AUR` [hullcaster-git](https://aur.archlinux.org/packages/hullcaster-git). + +### NixOS / Nix + +With [flakes](https://wiki.nixos.org/wiki/Flakes) enabled, run: + +```bash +nix run github:gilcu3/hullcaster +``` + ### On Linux distributions Currently, the only option is to build from source. @@ -69,14 +83,6 @@ cargo build --release # add or remove any features with --features cp target/release/hullcaster ~/.local/bin ``` -### NixOS / Nix - -With [flakes](https://wiki.nixos.org/wiki/Flakes) enabled, run: - -```bash -nix run github:gilcu3/hullcaster -``` - ## Running hullcaster In your terminal, run: From 402de85d41736a40750f786f83d436dd14f448e8 Mon Sep 17 00:00:00 2001 From: gilcu3 <828241+gilcu3@users.noreply.github.com> Date: Tue, 23 Jul 2024 10:09:01 +0200 Subject: [PATCH 3/5] fix gpodder test when no config is available --- src/gpodder.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/gpodder.rs b/src/gpodder.rs index fe80a0e..4333ad3 100644 --- a/src/gpodder.rs +++ b/src/gpodder.rs @@ -593,6 +593,8 @@ mod tests { } else { None }; - assert!(sync_agent.unwrap().testing().is_some()); + if sync_agent.is_some() { + assert!(sync_agent.unwrap().testing().is_some()); + } } } From ee63d25cbbd018406497bf23e2a8017b9f6c88e4 Mon Sep 17 00:00:00 2001 From: gilcu3 <828241+gilcu3@users.noreply.github.com> Date: Tue, 23 Jul 2024 10:13:42 +0200 Subject: [PATCH 4/5] remove unused code --- config.toml | 1 - src/config.rs | 2 -- 2 files changed, 3 deletions(-) diff --git a/config.toml b/config.toml index 487315e..ebc1a02 100644 --- a/config.toml +++ b/config.toml @@ -134,7 +134,6 @@ download_all = [ "D" ] delete = [ "x" ] delete_all = [ "X" ] remove = [ "r" ] -remove_all = [ "R" ] filter_played = [ "1" ] filter_downloaded = [ "2" ] diff --git a/src/config.rs b/src/config.rs index 27b236c..2a9f575 100644 --- a/src/config.rs +++ b/src/config.rs @@ -109,7 +109,6 @@ pub struct KeybindingsFromToml { pub delete: Option>, pub delete_all: Option>, pub remove: Option>, - pub remove_all: Option>, pub filter_played: Option>, pub filter_downloaded: Option>, pub enqueue: Option>, @@ -178,7 +177,6 @@ impl Config { delete: None, delete_all: None, remove: None, - remove_all: None, filter_played: None, filter_downloaded: None, enqueue: None, From 07bfdf69c3ef80abe5775ea159f14eab576fc308 Mon Sep 17 00:00:00 2001 From: gilcu3 <828241+gilcu3@users.noreply.github.com> Date: Tue, 23 Jul 2024 10:29:22 +0200 Subject: [PATCH 5/5] fix clippy warnings --- src/main_controller.rs | 15 ++++++++------- src/types.rs | 1 + src/ui/details_panel.rs | 4 +--- src/ui/mock_panel.rs | 2 ++ 4 files changed, 12 insertions(+), 10 deletions(-) diff --git a/src/main_controller.rs b/src/main_controller.rs index cb92970..fb7437d 100644 --- a/src/main_controller.rs +++ b/src/main_controller.rs @@ -194,14 +194,15 @@ impl MainController { Message::Dl(DownloadMsg::Complete(ep_data)) => { self.download_complete(ep_data); } - Message::Dl(DownloadMsg::ResponseError(_)) => { - self.notif_to_ui("Error sending download request.".to_string(), true) - } - Message::Dl(DownloadMsg::FileCreateError(_)) => { - self.notif_to_ui("Error creating file.".to_string(), true) + Message::Dl(DownloadMsg::ResponseError(ep)) => self.notif_to_ui( + "Error sending download request. ".to_string() + &ep.url, + true, + ), + Message::Dl(DownloadMsg::FileCreateError(ep)) => { + self.notif_to_ui("Error creating file. ".to_string() + &ep.title, true) } - Message::Dl(DownloadMsg::FileWriteError(_)) => { - self.notif_to_ui("Error downloading episode.".to_string(), true) + Message::Dl(DownloadMsg::FileWriteError(ep)) => { + self.notif_to_ui("Error downloading episode. ".to_string() + &ep.title, true) } Message::Ui(UiMsg::Delete(pod_id, ep_id)) => { diff --git a/src/types.rs b/src/types.rs index f67a8cf..dbd8a78 100644 --- a/src/types.rs +++ b/src/types.rs @@ -28,6 +28,7 @@ pub struct Podcast { pub url: String, pub description: Option, pub author: Option, + #[allow(dead_code)] pub explicit: Option, pub last_checked: DateTime, pub episodes: LockVec, diff --git a/src/ui/details_panel.rs b/src/ui/details_panel.rs index 8f06acf..3c20d2a 100644 --- a/src/ui/details_panel.rs +++ b/src/ui/details_panel.rs @@ -35,8 +35,7 @@ pub struct DetailsPanel { pub panel: Panel, pub details: Option
, pub content: Vec, - pub top_row: u16, // top row of text shown in window - pub total_rows: u16, // the total number of rows the details take up + pub top_row: u16, // top row of text shown in window } impl DetailsPanel { @@ -51,7 +50,6 @@ impl DetailsPanel { details: None, content: Vec::new(), top_row: 0, - total_rows: 0, } } diff --git a/src/ui/mock_panel.rs b/src/ui/mock_panel.rs index b56bf10..5c1b23f 100644 --- a/src/ui/mock_panel.rs +++ b/src/ui/mock_panel.rs @@ -8,8 +8,10 @@ use super::AppColors; #[derive(Debug)] pub struct Panel { pub buffer: Vec, + #[allow(dead_code)] pub screen_pos: usize, pub colors: Rc, + #[allow(dead_code)] pub title: String, pub start_x: u16, pub n_row: u16,