From d2a867fa198758843c8ff34affd438315f2f8c66 Mon Sep 17 00:00:00 2001 From: David Skrundz Date: Tue, 8 Sep 2026 20:52:08 -0700 Subject: [PATCH] Fix bug with & in movie names; update catalog --- Cargo.lock | 50 ++++++++++++++++++-------------- Cargo.toml | 14 ++++----- catalog/collections/mu.sh | 5 ++-- catalog/movies/barbie.sh | 27 ++++++++--------- catalog/shows/_shows.sh | 1 + crates/cli-mux/Cargo.toml | 2 +- crates/cli/Cargo.toml | 2 +- crates/cli/src/cli/mod.rs | 4 +++ crates/cli/src/run/tmdb.rs | 3 +- crates/db/Cargo.toml | 2 +- crates/flix/Cargo.toml | 2 +- crates/fs/Cargo.toml | 2 +- crates/fs/src/scanner/generic.rs | 2 +- crates/model/Cargo.toml | 2 +- crates/tmdb/Cargo.toml | 2 +- 15 files changed, 66 insertions(+), 54 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index e7686ac..bd28bd5 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -183,7 +183,7 @@ dependencies = [ "arrow-schema", "arrow-select", "atoi", - "base64", + "base64 0.22.1", "chrono", "half", "lexical-core", @@ -350,6 +350,12 @@ version = "0.22.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6" +[[package]] +name = "base64" +version = "0.23.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ac07cdecf99051d9a5238b80f35af32cdeba5b336e55d957b318b50137e18da5" + [[package]] name = "bigdecimal" version = "0.4.10" @@ -865,7 +871,7 @@ checksum = "3e0f1c7c3a72c66fd80abe965175f7523475c0489a87d3ff9d6e8c87d87a9d2d" [[package]] name = "flix" -version = "0.1.0" +version = "0.1.1" dependencies = [ "flix-db", "flix-fs", @@ -875,7 +881,7 @@ dependencies = [ [[package]] name = "flix-cli" -version = "0.1.0" +version = "0.1.1" dependencies = [ "anyhow", "chrono", @@ -891,7 +897,7 @@ dependencies = [ [[package]] name = "flix-db" -version = "0.1.0" +version = "0.1.1" dependencies = [ "chrono", "flix-model", @@ -904,7 +910,7 @@ dependencies = [ [[package]] name = "flix-fs" -version = "0.1.0" +version = "0.1.1" dependencies = [ "async-stream", "either", @@ -918,7 +924,7 @@ dependencies = [ [[package]] name = "flix-model" -version = "0.1.0" +version = "0.1.1" dependencies = [ "itertools 0.15.0", "seamantic", @@ -928,7 +934,7 @@ dependencies = [ [[package]] name = "flix-mux" -version = "0.1.0" +version = "0.1.1" dependencies = [ "anyhow", "clap", @@ -941,7 +947,7 @@ dependencies = [ [[package]] name = "flix-tmdb" -version = "0.1.0" +version = "0.1.1" dependencies = [ "bytes", "chrono", @@ -1268,9 +1274,9 @@ checksum = "6dbf3de79e51f3d586ab4cb9d5c3e2c14aa28ed23d180cf89b4df0454a69cc87" [[package]] name = "hybrid-array" -version = "0.4.14" +version = "0.4.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "707114b52a152fa7bdb290cd7cd5912d9467273b6d74e21b8d81aca1f8533f6b" +checksum = "27f864f10dfb56725ce5ce5472bc52252c8f93a4ab86327122cebf62c5f59a17" dependencies = [ "typenum", ] @@ -1316,7 +1322,7 @@ version = "0.1.20" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "96547c2556ec9d12fb1578c4eaf448b04993e7fb79cbaad930a656880a6bdfa0" dependencies = [ - "base64", + "base64 0.22.1", "bytes", "futures-channel", "futures-util", @@ -2240,11 +2246,11 @@ checksum = "d6f6ff9a378485b298a5286656da665ba74413d36db0979633275d2e708145d4" [[package]] name = "reqwest" -version = "0.13.4" +version = "0.13.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "219c5811de6525e5416c7d5d53bb656d3afdbc6c5af816e0802bcfa42dbdc1c3" +checksum = "16a1cfa75cc186dd73d5818e510e042e40927bccc9c236b061cea97e1eb08029" dependencies = [ - "base64", + "base64 0.23.1", "bytes", "futures-core", "http", @@ -2857,7 +2863,7 @@ version = "0.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "05b44e85bf579a8eeb4ceaa77a3a523baf2bf0e9bac7e40f405d537b5d2d5ccb" dependencies = [ - "base64", + "base64 0.22.1", "bytes", "cfg-if", "chrono", @@ -2966,7 +2972,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "87a2bdd6e83f6b3ea525ca9fee568030508b58355a43d0b2c1674d5f79dcd65e" dependencies = [ "atoi", - "base64", + "base64 0.22.1", "bitflags", "byteorder", "chrono", @@ -3466,9 +3472,9 @@ dependencies = [ [[package]] name = "url-macro" -version = "0.2.4" +version = "0.2.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a77b65c7a7ab8283571978ef99afd537e1485bb48a3e5341de9bbedb9ca5c57d" +checksum = "eef11d8fb2f916e16b8ee3e71226505a754c457510c443170b3f0e1d8b58507f" dependencies = [ "url", ] @@ -3866,18 +3872,18 @@ dependencies = [ [[package]] name = "zerocopy" -version = "0.8.56" +version = "0.8.57" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "556764e583adb45a9f8d413c2a147fa7e8d821e48e12b14fd560b607998b75eb" +checksum = "d35102a9f36d089ccae9e4c6802bc118be4487b80aaffc0ab4e0cf5ce92d2873" dependencies = [ "zerocopy-derive", ] [[package]] name = "zerocopy-derive" -version = "0.8.56" +version = "0.8.57" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f2ab42fc20575779bd240faa45f94a74256f755c0fa9e89f0ede20d91d0cdfc1" +checksum = "146c01f5ab44258da43cf276c74a2763db2ff3969c9c652c3f2de07041d0b2bc" dependencies = [ "proc-macro2", "quote", diff --git a/Cargo.toml b/Cargo.toml index 79914af..a47b5b1 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -9,13 +9,13 @@ license-file = "LICENSE.md" publish = false [workspace.dependencies] -flix = { path = "crates/flix", version = "=0.1.0", default-features = false } -flix-cli = { path = "crates/cli", version = "=0.1.0", default-features = false } -flix-db = { path = "crates/db", version = "=0.1.0", default-features = false } -flix-fs = { path = "crates/fs", version = "=0.1.0", default-features = false } -flix-model = { path = "crates/model", version = "=0.1.0", default-features = false } -flix-mux = { path = "crates/cli-mux", version = "=0.1.0", default-features = false } -flix-tmdb = { path = "crates/tmdb", version = "=0.1.0", default-features = false } +flix = { path = "crates/flix", version = "=0.1.1", default-features = false } +flix-cli = { path = "crates/cli", version = "=0.1.1", default-features = false } +flix-db = { path = "crates/db", version = "=0.1.1", default-features = false } +flix-fs = { path = "crates/fs", version = "=0.1.1", default-features = false } +flix-model = { path = "crates/model", version = "=0.1.1", default-features = false } +flix-mux = { path = "crates/cli-mux", version = "=0.1.1", default-features = false } +flix-tmdb = { path = "crates/tmdb", version = "=0.1.1", default-features = false } anyhow = { version = "^1.0.87", default-features = false } async-stream = { version = "^0.3.5", default-features = false } diff --git a/catalog/collections/mu.sh b/catalog/collections/mu.sh index ffdce70..4894db3 100644 --- a/catalog/collections/mu.sh +++ b/catalog/collections/mu.sh @@ -46,16 +46,15 @@ run flix add tmdb movie 49538 # X-Men: First Class (2011) run flix add tmdb movie 127585 # X-Men: Days of Future Past (2014) run flix add tmdb movie 246655 # X-Men: Apocalypse (2016) run flix add tmdb movie 320288 # Dark Phoenix (2019) -run flix add tmdb collection 1645434 # X-Anthology -run flix add tmdb movie 26623 # Generation X (1996) -run flix add tmdb movie 340102 # The New Mutants (2020) run flix add tmdb collection 558216 # Venom Collection run flix add tmdb movie 335983 # Venom (2018) run flix add tmdb movie 580489 # Venom: Let There Be Carnage (2021) run flix add tmdb movie 912649 # Venom: The Last Dance (2024) +run flix add tmdb movie 26623 # Generation X (1996) run flix add tmdb movie 1927 # Hulk (2003) +run flix add tmdb movie 340102 # The New Mutants (2020) run flix add tmdb movie 634492 # Madame Web (2024) run flix add \ diff --git a/catalog/movies/barbie.sh b/catalog/movies/barbie.sh index d8c63d3..5b4da05 100644 --- a/catalog/movies/barbie.sh +++ b/catalog/movies/barbie.sh @@ -1,16 +1,7 @@ -run flix add flix collection \ - "Barbie Animated Collection" \ - "Collection of the animated films based on Mattel's Barbie." - -run flix add tmdb collection 411859 # Barbie Fairytopia Collection -run flix add tmdb movie 13284 # Barbie: Fairytopia (2005) -run flix add tmdb movie 13285 # Barbie Fairytopia: Mermaidia (2006) -run flix add tmdb movie 16962 # Barbie Fairytopia: Magic of the Rainbow (2007) - -run flix add tmdb collection 447622 # Barbie Mariposa Collection -run flix add tmdb movie 18198 # Barbie Mariposa (2008) -run flix add tmdb movie 196254 # Barbie Mariposa & the Fairy Princess (2013) - +run flix add \ + --title "Barbie Collection" \ + --overview "Collection of the animated films based on Mattel's Barbie." \ + tmdb collection 1698073 run flix add tmdb movie 15167 # Barbie in the Nutcracker (2001) run flix add tmdb movie 15015 # Barbie as Rapunzel (2002) run flix add tmdb movie 15016 # Barbie of Swan Lake (2003) @@ -22,4 +13,14 @@ run flix add tmdb movie 13004 # Barbie and the Diamond Castle run flix add tmdb movie 13459 # Barbie in 'A Christmas Carol' (2008) run flix add tmdb movie 23566 # Barbie and the Three Musketeers (2009) run flix add tmdb movie 16418 # Barbie Presents: Thumbelina (2009) + +run flix add tmdb collection 411859 # Barbie Fairytopia Collection +run flix add tmdb movie 13284 # Barbie: Fairytopia (2005) +run flix add tmdb movie 13285 # Barbie Fairytopia: Mermaidia (2006) +run flix add tmdb movie 16962 # Barbie Fairytopia: Magic of the Rainbow (2007) + +run flix add tmdb collection 447622 # Barbie Mariposa Collection +run flix add tmdb movie 18198 # Barbie Mariposa (2008) +run flix add tmdb movie 196254 # Barbie Mariposa & the Fairy Princess (2013) + run flix add tmdb movie 21705 # The Barbie Diaries (2006) diff --git a/catalog/shows/_shows.sh b/catalog/shows/_shows.sh index b86144d..fe719cf 100644 --- a/catalog/shows/_shows.sh +++ b/catalog/shows/_shows.sh @@ -46,6 +46,7 @@ run flix add tmdb show 63247 # Westworld (2016) run flix add tmdb show 71912 # The Witcher (2019) # Fixups +run flix add tmdb season 15260 0 # Adventure Time Specials run flix add flix episode \ "brooklyn-nine-nine-2013" 8 10 \ "The Last Day (Part 2)" \ diff --git a/crates/cli-mux/Cargo.toml b/crates/cli-mux/Cargo.toml index c516fae..0394d7e 100644 --- a/crates/cli-mux/Cargo.toml +++ b/crates/cli-mux/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "flix-mux" -version = "0.1.0" +version = "0.1.1" description = "CLI for bulk media muxing" repository = "https://git.skrundz.dev/quantumshade/flix" keywords = ["flix"] diff --git a/crates/cli/Cargo.toml b/crates/cli/Cargo.toml index 1c3626e..67ee3aa 100644 --- a/crates/cli/Cargo.toml +++ b/crates/cli/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "flix-cli" -version = "0.1.0" +version = "0.1.1" description = "CLI for interacting with a flix database" repository = "https://git.skrundz.dev/quantumshade/flix" keywords = ["flix"] diff --git a/crates/cli/src/cli/mod.rs b/crates/cli/src/cli/mod.rs index 3180cdf..2ace80c 100644 --- a/crates/cli/src/cli/mod.rs +++ b/crates/cli/src/cli/mod.rs @@ -93,6 +93,9 @@ pub(crate) struct AddOverrides { /// Override the displayed title. #[arg(long)] pub title: Option, + /// Override the displayed overview. + #[arg(long)] + pub overview: Option, /// Override the title used to sort. #[arg(long)] pub sort_title: Option, @@ -106,6 +109,7 @@ pub(crate) struct AddOverrides { /// Top level cli commands. #[derive(Subcommand)] +#[expect(clippy::large_enum_variant, reason = "not performance critical")] pub(crate) enum Command { /// Initialize a new database. Init, diff --git a/crates/cli/src/run/tmdb.rs b/crates/cli/src/run/tmdb.rs index 42b7594..c572fcd 100644 --- a/crates/cli/src/run/tmdb.rs +++ b/crates/cli/src/run/tmdb.rs @@ -52,6 +52,7 @@ pub(crate) async fn add( .with_context(|| format!("collections().get_details({})", id.into_raw()))?; let title = overrides.title.unwrap_or(collection.title); + let overview = overrides.overview.unwrap_or(collection.overview); let sort_title = overrides .sort_title @@ -81,7 +82,7 @@ pub(crate) async fn add( let flix = entity::info::collections::ActiveModel { id: NotSet, title: Set(title), - overview: Set(collection.overview), + overview: Set(overview), sort_title: Set(sort_title), fs_slug: Set(fs_slug), web_slug: Set(web_slug), diff --git a/crates/db/Cargo.toml b/crates/db/Cargo.toml index 2d6b933..d0c67bd 100644 --- a/crates/db/Cargo.toml +++ b/crates/db/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "flix-db" -version = "0.1.0" +version = "0.1.1" description = "Types for storing persistent data about media" repository = "https://git.skrundz.dev/quantumshade/flix" keywords = ["flix"] diff --git a/crates/flix/Cargo.toml b/crates/flix/Cargo.toml index 6d4421f..a80dde5 100644 --- a/crates/flix/Cargo.toml +++ b/crates/flix/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "flix" -version = "0.1.0" +version = "0.1.1" description = "Mechanisms for interacting with flix media" repository = "https://git.skrundz.dev/quantumshade/flix" keywords = ["flix"] diff --git a/crates/fs/Cargo.toml b/crates/fs/Cargo.toml index 8be2127..e54a146 100644 --- a/crates/fs/Cargo.toml +++ b/crates/fs/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "flix-fs" -version = "0.1.0" +version = "0.1.1" description = "Filesystem scanner for flix media" repository = "https://git.skrundz.dev/quantumshade/flix" keywords = ["flix"] diff --git a/crates/fs/src/scanner/generic.rs b/crates/fs/src/scanner/generic.rs index c7d5451..55580ae 100644 --- a/crates/fs/src/scanner/generic.rs +++ b/crates/fs/src/scanner/generic.rs @@ -110,7 +110,7 @@ impl Scanner { #[expect(clippy::panic, reason = "static regex string")] let media_folder_re = MEDIA_FOLDER_REGEX.get_or_init(|| { - Regex::new(r"^[[[:alnum:]]' -]+ \([[:digit:]]+\)( \[[[:digit:]]+\])?$") + Regex::new(r"^[[[:alnum:]]' &-]+ \([[:digit:]]+\)( \[[[:digit:]]+\])?$") .unwrap_or_else(|err| panic!("regex is invalid: {err}")) }); #[expect(clippy::panic, reason = "static regex string")] diff --git a/crates/model/Cargo.toml b/crates/model/Cargo.toml index c8bfaf0..9b2aaff 100644 --- a/crates/model/Cargo.toml +++ b/crates/model/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "flix-model" -version = "0.1.0" +version = "0.1.1" description = "Core types for flix data" repository = "https://git.skrundz.dev/quantumshade/flix" keywords = ["flix"] diff --git a/crates/tmdb/Cargo.toml b/crates/tmdb/Cargo.toml index a6bd9c4..78be5c6 100644 --- a/crates/tmdb/Cargo.toml +++ b/crates/tmdb/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "flix-tmdb" -version = "0.1.0" +version = "0.1.1" description = "Clients and models for fetching data from TMDB" repository = "https://git.skrundz.dev/quantumshade/flix" keywords = ["flix"]