Skip to content

Terminal interface to find, download, and stream movies, TV shows, and live TV using local media players.

refactor: improve code formatting, sanitize download filenames, and fix return value logic in TUI app.

Samir Hossains2a63abeafa05
diff --git a/Cargo.lock b/Cargo.lock
index 250aa35..de59d7a 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -70,25 +70,8 @@ name = "arbitrary"
version = "1.4.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "c3d036a3c4ab069c7b410a2ce876bd74808d2d0888a82667669f8e783a898bf1"
-
-[[package]]
-name = "arboard"
-version = "3.6.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "0348a1c054491f4bfe6ab86a7b6ab1e44e45d899005de92f58b3df180b36ddaf"
dependencies = [
- "clipboard-win",
- "image",
- "log",
- "objc2",
- "objc2-app-kit",
- "objc2-core-foundation",
- "objc2-core-graphics",
- "objc2-foundation",
- "parking_lot",
- "percent-encoding",
- "windows-sys 0.60.2",
- "x11rb",
+ "derive_arbitrary",
]
[[package]]
@@ -220,6 +203,12 @@ dependencies = [
"vsimd",
]
+[[package]]
+name = "base64ct"
+version = "1.8.3"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "2af50177e190e07a26ab74f8b1efbfe2ef87da2116221318cb1c2e82baf7de06"
+
[[package]]
name = "bit-set"
version = "0.5.3"
@@ -330,6 +319,12 @@ dependencies = [
"syn 2.0.119",
]
+[[package]]
+name = "byteorder"
+version = "1.5.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b"
+
[[package]]
name = "byteorder-lite"
version = "0.1.0"
@@ -399,15 +394,6 @@ dependencies = [
"windows-link",
]
-[[package]]
-name = "clipboard-win"
-version = "5.4.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "bde03770d3df201d4fb868f2c9c59e66a3e4e2bd06692a0fe701e7103c7e84d4"
-dependencies = [
- "error-code",
-]
-
[[package]]
name = "cmake"
version = "0.1.58"
@@ -453,6 +439,24 @@ dependencies = [
"static_assertions",
]
+[[package]]
+name = "console"
+version = "0.16.4"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "4fe5f465a4f6fee88fad41b85d990f84c835335e85b5d9e6e63e0d06d28cba7c"
+dependencies = [
+ "encode_unicode",
+ "libc",
+ "unicode-width",
+ "windows-sys 0.61.2",
+]
+
+[[package]]
+name = "const-oid"
+version = "0.9.6"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "c2459377285ad874054d797f3ccebf984978aa39129f6eafde5cdc8315b612f8"
+
[[package]]
name = "const-oid"
version = "0.10.2"
@@ -652,6 +656,33 @@ dependencies = [
"cmov",
]
+[[package]]
+name = "curve25519-dalek"
+version = "4.1.3"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "97fb8b7c4503de7d6ae7b42ab72a5a59857b4c937ec27a3d4539dba95b5ab2be"
+dependencies = [
+ "cfg-if",
+ "cpufeatures 0.2.17",
+ "curve25519-dalek-derive",
+ "digest 0.10.7",
+ "fiat-crypto",
+ "rustc_version",
+ "subtle",
+ "zeroize",
+]
+
+[[package]]
+name = "curve25519-dalek-derive"
+version = "0.1.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "f46882e17999c6cc590af592290432be3bce0428cb0d5f8b6715e4dc7b383eb3"
+dependencies = [
+ "proc-macro2",
+ "quote",
+ "syn 2.0.119",
+]
+
[[package]]
name = "darling"
version = "0.20.11"
@@ -693,12 +724,43 @@ version = "0.3.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "5729f5117e208430e437df2f4843f5e5952997175992d1414f94c57d61e270b4"
+[[package]]
+name = "der"
+version = "0.7.10"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "e7c1832837b905bbfb5101e07cc24c8deddf52f93225eee6ead5f4d63d53ddcb"
+dependencies = [
+ "const-oid 0.9.6",
+ "zeroize",
+]
+
+[[package]]
+name = "der"
+version = "0.8.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "a69dedd701da44b0536442edf09c81a64b0ab97a7a4a5e3d1971f00027cbc63d"
+dependencies = [
+ "pem-rfc7468",
+ "zeroize",
+]
+
[[package]]
name = "deranged"
version = "0.5.8"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "7cd812cc2bc1d69d4764bd80df88b4317eaef9e773c75226407d9bc0876b211c"
+[[package]]
+name = "derive_arbitrary"
+version = "1.4.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "1e567bd82dcff979e4b03460c307b3cdc9e96fde3d73bed1496d2bc75d9dd62a"
+dependencies = [
+ "proc-macro2",
+ "quote",
+ "syn 2.0.119",
+]
+
[[package]]
name = "derive_more"
version = "2.1.1"
@@ -738,7 +800,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "f1dd6dbb5841937940781866fa1281a1ff7bd3bf827091440879f9994983d5c2"
dependencies = [
"block-buffer 0.12.1",
- "const-oid",
+ "const-oid 0.10.2",
"crypto-common 0.2.2",
"ctutils",
]
@@ -764,16 +826,6 @@ dependencies = [
"windows-sys 0.61.2",
]
-[[package]]
-name = "dispatch2"
-version = "0.3.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "1e0e367e4e7da84520dedcac1901e4da967309406d1e51017ae1abfb97adbd38"
-dependencies = [
- "bitflags 2.13.1",
- "objc2",
-]
-
[[package]]
name = "displaydoc"
version = "0.2.6"
@@ -800,12 +852,43 @@ version = "1.0.5"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "92773504d58c093f6de2459af4af33faa518c13451eb8f2b5698ed3d36e7c813"
+[[package]]
+name = "ed25519"
+version = "2.2.3"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "115531babc129696a58c64a4fef0a8bf9e9698629fb97e9e40767d235cfbcd53"
+dependencies = [
+ "pkcs8",
+ "signature",
+]
+
+[[package]]
+name = "ed25519-dalek"
+version = "2.2.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "70e796c081cee67dc755e1a36a0a172b897fab85fc3f6bc48307991f64e4eca9"
+dependencies = [
+ "curve25519-dalek",
+ "ed25519",
+ "serde",
+ "sha2",
+ "signature",
+ "subtle",
+ "zeroize",
+]
+
[[package]]
name = "either"
version = "1.16.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "91622ff5e7162018101f2fea40d6ebf4a78bbe5a49736a2020649edf9693679e"
+[[package]]
+name = "encode_unicode"
+version = "1.0.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "34aa73646ffb006b8f5147f3dc182bd4bcb190227ce861fc4a4844bf8e3cb2c0"
+
[[package]]
name = "encoding_rs"
version = "0.8.35"
@@ -851,23 +934,6 @@ dependencies = [
"windows-sys 0.61.2",
]
-[[package]]
-name = "error-code"
-version = "3.3.2"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "dea2df4cf52843e0452895c455a1a2cfbb842a1e7329671acf418fdc53ed4c59"
-
-[[package]]
-name = "etcetera"
-version = "0.10.0"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "26c7b13d0780cb82722fd59f6f57f925e143427e4a75313a6c77243bf5326ae6"
-dependencies = [
- "cfg-if",
- "home",
- "windows-sys 0.59.0",
-]
-
[[package]]
name = "euclid"
version = "0.22.14"
@@ -910,6 +976,12 @@ version = "1.0.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "dd2e7510819d6fbf51a5545c8f922716ecfb14df168a3242f7d33e0239efe6a1"
+[[package]]
+name = "fastrand"
+version = "2.5.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "da7c62ceae207dd37ea5b845da6a0696c799f85e97da1ab5b7910be3c1c80223"
+
[[package]]
name = "fax"
version = "0.2.7"
@@ -925,6 +997,12 @@ dependencies = [
"simd-adler32",
]
+[[package]]
+name = "fiat-crypto"
+version = "0.2.9"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "28dea519a9695b9977216879a3ebfddf92f1c08c05d984f8996aecd6ecdc811d"
+
[[package]]
name = "filedescriptor"
version = "0.8.3"
@@ -936,6 +1014,16 @@ dependencies = [
"winapi",
]
+[[package]]
+name = "filetime"
+version = "0.2.29"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "5c287a33c7f0a620c38e641e7f60827713987b3c0f26e8ddc9462cc69cf75759"
+dependencies = [
+ "cfg-if",
+ "libc",
+]
+
[[package]]
name = "find-msvc-tools"
version = "0.1.9"
@@ -976,6 +1064,21 @@ version = "0.2.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "77ce24cb58228fbb8aa041425bb1050850ac19177686ea6e0f41a70416f56fdb"
+[[package]]
+name = "foreign-types"
+version = "0.3.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1"
+dependencies = [
+ "foreign-types-shared",
+]
+
+[[package]]
+name = "foreign-types-shared"
+version = "0.1.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b"
+
[[package]]
name = "form_urlencoded"
version = "1.2.2"
@@ -1056,16 +1159,6 @@ dependencies = [
"version_check",
]
-[[package]]
-name = "gethostname"
-version = "1.1.0"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "1bd49230192a3797a9a4d6abe9b3eed6f7fa4c8a8a4947977c6f80025f92cbd8"
-dependencies = [
- "rustix 1.1.4",
- "windows-link",
-]
-
[[package]]
name = "getrandom"
version = "0.2.17"
@@ -1188,15 +1281,6 @@ dependencies = [
"digest 0.11.3",
]
-[[package]]
-name = "home"
-version = "0.5.11"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "589533453244b0995c858700322199b2becb13b627df2851f64a2775d024abcf"
-dependencies = [
- "windows-sys 0.59.0",
-]
-
[[package]]
name = "http"
version = "1.4.2"
@@ -1279,7 +1363,22 @@ dependencies = [
"tokio",
"tokio-rustls",
"tower-service",
- "webpki-roots",
+]
+
+[[package]]
+name = "hyper-tls"
+version = "0.6.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "70206fc6890eaca9fde8a0bf71caa2ddfc9fe045ac9e5c70df101a7dbde866e0"
+dependencies = [
+ "bytes",
+ "http-body-util",
+ "hyper",
+ "hyper-util",
+ "native-tls",
+ "tokio",
+ "tokio-native-tls",
+ "tower-service",
]
[[package]]
@@ -1319,7 +1418,7 @@ dependencies = [
"js-sys",
"log",
"wasm-bindgen",
- "windows-core",
+ "windows-core 0.62.2",
]
[[package]]
@@ -1499,6 +1598,19 @@ dependencies = [
"hashbrown 0.17.1",
]
+[[package]]
+name = "indicatif"
+version = "0.18.6"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "9433806cd6b4ec1aba79c021c7e4c58fb4c3b9977c085062e611ac929998fb0c"
+dependencies = [
+ "console",
+ "portable-atomic",
+ "unicode-width",
+ "unit-prefix",
+ "web-time",
+]
+
[[package]]
name = "indoc"
version = "2.0.7"
@@ -1538,6 +1650,25 @@ version = "2.12.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "d98f6fed1fde3f8c21bc40a1abb88dd75e67924f9cffc3ef95607bad8017f8e2"
+[[package]]
+name = "is-docker"
+version = "0.2.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "928bae27f42bc99b60d9ac7334e3a21d10ad8f1835a4e12ec3ec0464765ed1b3"
+dependencies = [
+ "once_cell",
+]
+
+[[package]]
+name = "is-wsl"
+version = "0.4.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "173609498df190136aa7dea1a91db051746d339e18476eed5ca40521f02d7aa5"
+dependencies = [
+ "is-docker",
+ "once_cell",
+]
+
[[package]]
name = "itertools"
version = "0.14.0"
@@ -1842,9 +1973,8 @@ dependencies = [
[[package]]
name = "moviebox-tui"
-version = "0.1.4"
+version = "0.1.5"
dependencies = [
- "arboard",
"base64",
"chrono",
"crossterm",
@@ -1853,15 +1983,16 @@ dependencies = [
"image",
"lru",
"md-5",
+ "open",
"rand 0.10.2",
"ratatui",
"ratatui-image",
- "reqwest 0.13.4",
+ "reqwest",
+ "self_update",
"serde",
"serde_json",
"thiserror 2.0.19",
"tokio",
- "update-informer",
"url",
]
@@ -1875,6 +2006,23 @@ dependencies = [
"pxfm",
]
+[[package]]
+name = "native-tls"
+version = "0.2.18"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "465500e14ea162429d264d44189adc38b199b62b1c21eea9f69e4b73cb03bbf2"
+dependencies = [
+ "libc",
+ "log",
+ "openssl",
+ "openssl-probe",
+ "openssl-sys",
+ "schannel",
+ "security-framework",
+ "security-framework-sys",
+ "tempfile",
+]
+
[[package]]
name = "new_debug_unreachable"
version = "1.0.6"
@@ -2005,90 +2153,64 @@ dependencies = [
]
[[package]]
-name = "objc2"
-version = "0.6.4"
+name = "once_cell"
+version = "1.21.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "3a12a8ed07aefc768292f076dc3ac8c48f3781c8f2d5851dd3d98950e8c5a89f"
-dependencies = [
- "objc2-encode",
-]
+checksum = "9f7c3e4beb33f85d45ae3e3a1792185706c8e16d043238c593331cc7cd313b50"
[[package]]
-name = "objc2-app-kit"
-version = "0.3.2"
+name = "open"
+version = "5.4.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "d49e936b501e5c5bf01fda3a9452ff86dc3ea98ad5f283e1455153142d97518c"
+checksum = "a0b3d059e795d52b8a72fef45658620edd4d9c359b338564aa14391ffa511ed5"
dependencies = [
- "bitflags 2.13.1",
- "objc2",
- "objc2-core-graphics",
- "objc2-foundation",
+ "is-wsl",
+ "libc",
]
[[package]]
-name = "objc2-core-foundation"
-version = "0.3.2"
+name = "openssl"
+version = "0.10.81"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "2a180dd8642fa45cdb7dd721cd4c11b1cadd4929ce112ebd8b9f5803cc79d536"
+checksum = "77823a27f0babb03091cb9ed9ef80af3b39dbc82f97e8fa530374b7dafd87a45"
dependencies = [
"bitflags 2.13.1",
- "dispatch2",
- "objc2",
+ "cfg-if",
+ "foreign-types",
+ "libc",
+ "openssl-macros",
+ "openssl-sys",
]
[[package]]
-name = "objc2-core-graphics"
-version = "0.3.2"
+name = "openssl-macros"
+version = "0.1.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "e022c9d066895efa1345f8e33e584b9f958da2fd4cd116792e15e07e4720a807"
+checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c"
dependencies = [
- "bitflags 2.13.1",
- "dispatch2",
- "objc2",
- "objc2-core-foundation",
- "objc2-io-surface",
+ "proc-macro2",
+ "quote",
+ "syn 2.0.119",
]
[[package]]
-name = "objc2-encode"
-version = "4.1.0"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "ef25abbcd74fb2609453eb695bd2f860d389e457f67dc17cafc8b8cbc89d0c33"
-
-[[package]]
-name = "objc2-foundation"
-version = "0.3.2"
+name = "openssl-probe"
+version = "0.2.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "e3e0adef53c21f888deb4fa59fc59f7eb17404926ee8a6f59f5df0fd7f9f3272"
-dependencies = [
- "bitflags 2.13.1",
- "objc2",
- "objc2-core-foundation",
-]
+checksum = "7c87def4c32ab89d880effc9e097653c8da5d6ef28e6b539d313baaacfbafcbe"
[[package]]
-name = "objc2-io-surface"
-version = "0.3.2"
+name = "openssl-sys"
+version = "0.9.117"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "180788110936d59bab6bd83b6060ffdfffb3b922ba1396b312ae795e1de9d81d"
+checksum = "b47e7e6bb2c38cd930d25a23b40fa52e068c10e85f3e03a7f5ba5aaca5713695"
dependencies = [
- "bitflags 2.13.1",
- "objc2",
- "objc2-core-foundation",
+ "cc",
+ "libc",
+ "pkg-config",
+ "vcpkg",
]
-[[package]]
-name = "once_cell"
-version = "1.21.4"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "9f7c3e4beb33f85d45ae3e3a1792185706c8e16d043238c593331cc7cd313b50"
-
-[[package]]
-name = "openssl-probe"
-version = "0.2.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "7c87def4c32ab89d880effc9e097653c8da5d6ef28e6b539d313baaacfbafcbe"
-
[[package]]
name = "option-ext"
version = "0.2.0"
@@ -2179,6 +2301,15 @@ version = "0.1.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "35fb2e5f958ec131621fdd531e9fc186ed768cbe395337403ae56c17a74c68ec"
+[[package]]
+name = "pem-rfc7468"
+version = "1.0.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "a6305423e0e7738146434843d1694d621cce767262b2a86910beab705e4493d9"
+dependencies = [
+ "base64ct",
+]
+
[[package]]
name = "percent-encoding"
version = "2.3.2"
@@ -2285,6 +2416,16 @@ version = "0.2.17"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "a89322df9ebe1c1578d689c92318e070967d1042b512afbe49518723f4e6d5cd"
+[[package]]
+name = "pkcs8"
+version = "0.10.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "f950b2377845cebe5cf8b5165cb3cc1a5e0fa5cfa3e1f7f55707d8fd82e0a7b7"
+dependencies = [
+ "der 0.7.10",
+ "spki",
+]
+
[[package]]
name = "pkg-config"
version = "0.3.33"
@@ -2426,6 +2567,15 @@ version = "2.0.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "a993555f31e5a609f617c12db6250dedcac1b0a85076912c436e6fc9b2c8e6a3"
+[[package]]
+name = "quick-xml"
+version = "0.38.4"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "b66c2058c55a409d601666cffe35f04333cf1013010882cec174a7467cd4e21c"
+dependencies = [
+ "memchr",
+]
+
[[package]]
name = "quinn"
version = "0.11.11"
@@ -2876,46 +3026,6 @@ version = "0.8.11"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "d6f6ff9a378485b298a5286656da665ba74413d36db0979633275d2e708145d4"
-[[package]]
-name = "reqwest"
-version = "0.12.28"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "eddd3ca559203180a307f12d114c268abf583f59b03cb906fd0b3ff8646c1147"
-dependencies = [
- "base64",
- "bytes",
- "futures-channel",
- "futures-core",
- "futures-util",
- "http",
- "http-body",
- "http-body-util",
- "hyper",
- "hyper-rustls",
- "hyper-util",
- "js-sys",
- "log",
- "percent-encoding",
- "pin-project-lite",
- "quinn",
- "rustls",
- "rustls-pki-types",
- "serde",
- "serde_json",
- "serde_urlencoded",
- "sync_wrapper",
- "tokio",
- "tokio-rustls",
- "tower",
- "tower-http",
- "tower-service",
- "url",
- "wasm-bindgen",
- "wasm-bindgen-futures",
- "web-sys",
- "webpki-roots",
-]
-
[[package]]
name = "reqwest"
version = "0.13.4"
@@ -2925,17 +3035,21 @@ dependencies = [
"base64",
"bytes",
"encoding_rs",
+ "futures-channel",
"futures-core",
+ "futures-util",
"h2",
"http",
"http-body",
"http-body-util",
"hyper",
"hyper-rustls",
+ "hyper-tls",
"hyper-util",
"js-sys",
"log",
"mime",
+ "native-tls",
"percent-encoding",
"pin-project-lite",
"quinn",
@@ -2946,6 +3060,7 @@ dependencies = [
"serde_json",
"sync_wrapper",
"tokio",
+ "tokio-native-tls",
"tokio-rustls",
"tower",
"tower-http",
@@ -3024,9 +3139,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "3c54fcab019b409d04215d3a17cb438fd7fbf192ee61461f20f4fe18704bc138"
dependencies = [
"aws-lc-rs",
- "log",
"once_cell",
- "ring",
"rustls-pki-types",
"rustls-webpki",
"subtle",
@@ -3162,12 +3275,47 @@ dependencies = [
"libc",
]
+[[package]]
+name = "self-replace"
+version = "1.5.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "03ec815b5eab420ab893f63393878d89c90fdd94c0bcc44c07abb8ad95552fb7"
+dependencies = [
+ "fastrand",
+ "tempfile",
+ "windows-sys 0.52.0",
+]
+
[[package]]
name = "self_cell"
version = "1.3.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "2ab42ca02749e120097e328d91d415325bdf43b1c72c4c8badf37375fe40a813"
+[[package]]
+name = "self_update"
+version = "0.44.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "2e79722b5a505d4ddc77527455a97244e9e8c4c07533ff44cf4421cce7bb6d17"
+dependencies = [
+ "http",
+ "indicatif",
+ "log",
+ "quick-xml",
+ "regex",
+ "reqwest",
+ "self-replace",
+ "semver",
+ "serde",
+ "serde_json",
+ "tar",
+ "tempfile",
+ "ureq",
+ "urlencoding",
+ "zip",
+ "zipsign-api",
+]
+
[[package]]
name = "semver"
version = "1.0.28"
@@ -3217,18 +3365,6 @@ dependencies = [
"zmij",
]
-[[package]]
-name = "serde_urlencoded"
-version = "0.7.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "d3491c14715ca2294c4d6a88f15e84739788c1d030eed8c110436aafdaa2f3fd"
-dependencies = [
- "form_urlencoded",
- "itoa",
- "ryu",
- "serde",
-]
-
[[package]]
name = "sha2"
version = "0.10.9"
@@ -3277,6 +3413,16 @@ dependencies = [
"libc",
]
+[[package]]
+name = "signature"
+version = "2.2.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "77549399552de45a898a580c1b41d445bf730df867cc44e6c0233bbc4b8329de"
+dependencies = [
+ "digest 0.10.7",
+ "rand_core 0.6.4",
+]
+
[[package]]
name = "simd-adler32"
version = "0.3.10"
@@ -3336,6 +3482,27 @@ dependencies = [
"windows-sys 0.61.2",
]
+[[package]]
+name = "socks"
+version = "0.3.4"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "f0c3dbbd9ae980613c6dd8e28a9407b50509d3803b57624d5dfe8315218cd58b"
+dependencies = [
+ "byteorder",
+ "libc",
+ "winapi",
+]
+
+[[package]]
+name = "spki"
+version = "0.7.3"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "d91ed6c858b01f942cd56b37a94b3e0a1798290327d1236e4d9cf4eaca44d29d"
+dependencies = [
+ "base64ct",
+ "der 0.7.10",
+]
+
[[package]]
name = "stable_deref_trait"
version = "1.2.1"
@@ -3461,6 +3628,30 @@ version = "1.0.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "55937e1799185b12863d447f42597ed69d9928686b8d88a1df17376a097d8369"
+[[package]]
+name = "tar"
+version = "0.4.46"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "3f6221d9a6003c78398e3b239969f352578258df48c8eb051caadae0015bc840"
+dependencies = [
+ "filetime",
+ "libc",
+ "xattr",
+]
+
+[[package]]
+name = "tempfile"
+version = "3.27.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "32497e9a4c7b38532efcdebeef879707aa9f794296a4f0244f6f69e9bc8574bd"
+dependencies = [
+ "fastrand",
+ "getrandom 0.4.3",
+ "once_cell",
+ "rustix 1.1.4",
+ "windows-sys 0.61.2",
+]
+
[[package]]
name = "termina"
version = "0.3.3"
@@ -3676,6 +3867,16 @@ dependencies = [
"syn 2.0.119",
]
+[[package]]
+name = "tokio-native-tls"
+version = "0.3.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "bbae76ab933c85776efabc971569dd6119c580d8f5d448769dec1764bf796ef2"
+dependencies = [
+ "native-tls",
+ "tokio",
+]
+
[[package]]
name = "tokio-rustls"
version = "0.26.4"
@@ -3812,24 +4013,16 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "b4ac048d71ede7ee76d585517add45da530660ef4390e49b098733c6e897f254"
[[package]]
-name = "untrusted"
-version = "0.9.0"
+name = "unit-prefix"
+version = "0.5.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1"
+checksum = "81e544489bf3d8ef66c953931f56617f423cd4b5494be343d9b9d3dda037b9a3"
[[package]]
-name = "update-informer"
-version = "1.3.0"
+name = "untrusted"
+version = "0.9.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "67b27dcf766dc6ad64c2085201626e1a7955dc1983532bfc8406d552903ace2a"
-dependencies = [
- "etcetera",
- "reqwest 0.12.28",
- "semver",
- "serde",
- "serde_json",
- "ureq",
-]
+checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1"
[[package]]
name = "ureq"
@@ -3839,16 +4032,19 @@ checksum = "dea7109cdcd5864d4eeb1b58a1648dc9bf520360d7af16ec26d0a9354bafcfc0"
dependencies = [
"base64",
"cookie_store",
+ "der 0.8.1",
+ "encoding_rs",
"flate2",
"log",
+ "native-tls",
"percent-encoding",
- "rustls",
"rustls-pki-types",
"serde",
"serde_json",
+ "socks",
"ureq-proto",
"utf8-zero",
- "webpki-roots",
+ "webpki-root-certs",
]
[[package]]
@@ -3875,6 +4071,12 @@ dependencies = [
"serde",
]
+[[package]]
+name = "urlencoding"
+version = "2.1.3"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "daf8dba3b7eb870caf1ddeed7bc9d2a049f3cfdfae7cb521b087cc33ae4c49da"
+
[[package]]
name = "utf8-zero"
version = "0.8.1"
@@ -3916,6 +4118,12 @@ dependencies = [
"wasm-bindgen",
]
+[[package]]
+name = "vcpkg"
+version = "0.2.15"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426"
+
[[package]]
name = "version_check"
version = "0.9.5"
@@ -4055,15 +4263,6 @@ dependencies = [
"rustls-pki-types",
]
-[[package]]
-name = "webpki-roots"
-version = "1.0.9"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "7dcd9d09a39985f5344844e66b0c530a33843579125f23e21e9f0f220850f22a"
-dependencies = [
- "rustls-pki-types",
-]
-
[[package]]
name = "weezl"
version = "0.1.12"
@@ -4189,8 +4388,8 @@ version = "0.58.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "dd04d41d93c4992d421894c18c8b43496aa748dd4c081bac0dc93eb0489272b6"
dependencies = [
- "windows-core",
- "windows-targets 0.52.6",
+ "windows-core 0.58.0",
+ "windows-targets",
]
[[package]]
@@ -4199,11 +4398,24 @@ version = "0.58.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "6ba6d44ec8c2591c134257ce647b7ea6b20335bf6379a27dac5f1641fcf59f99"
dependencies = [
- "windows-implement",
- "windows-interface",
+ "windows-implement 0.58.0",
+ "windows-interface 0.58.0",
"windows-result 0.2.0",
"windows-strings 0.1.0",
- "windows-targets 0.52.6",
+ "windows-targets",
+]
+
+[[package]]
+name = "windows-core"
+version = "0.62.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "b8e83a14d34d0623b51dce9581199302a221863196a1dde71a7663a4c2be9deb"
+dependencies = [
+ "windows-implement 0.60.2",
+ "windows-interface 0.59.3",
+ "windows-link",
+ "windows-result 0.4.1",
+ "windows-strings 0.5.1",
]
[[package]]
@@ -4217,6 +4429,17 @@ dependencies = [
"syn 2.0.119",
]
+[[package]]
+name = "windows-implement"
+version = "0.60.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "053e2e040ab57b9dc951b72c264860db7eb3b0200ba345b4e4c3b14f67855ddf"
+dependencies = [
+ "proc-macro2",
+ "quote",
+ "syn 2.0.119",
+]
+
[[package]]
name = "windows-interface"
version = "0.58.0"
@@ -4228,6 +4451,17 @@ dependencies = [
"syn 2.0.119",
]
+[[package]]
+name = "windows-interface"
+version = "0.59.3"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "3f316c4a2570ba26bbec722032c4099d8c8bc095efccdc15688708623367e358"
+dependencies = [
+ "proc-macro2",
+ "quote",
+ "syn 2.0.119",
+]
+
[[package]]
name = "windows-link"
version = "0.2.1"
@@ -4251,7 +4485,7 @@ version = "0.2.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "1d1043d8214f791817bab27572aaa8af63732e11bf84aa21a45a78d6c317ae0e"
dependencies = [
- "windows-targets 0.52.6",
+ "windows-targets",
]
[[package]]
@@ -4270,7 +4504,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "4cd9b125c486025df0eabcb585e62173c6c9eddcec5d117d3b6e8c30e2ee4d10"
dependencies = [
"windows-result 0.2.0",
- "windows-targets 0.52.6",
+ "windows-targets",
]
[[package]]
@@ -4288,7 +4522,7 @@ version = "0.52.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d"
dependencies = [
- "windows-targets 0.52.6",
+ "windows-targets",
]
[[package]]
@@ -4297,16 +4531,7 @@ version = "0.59.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "1e38bc4d79ed67fd075bcc251a1c39b32a1776bbe92e5bef1f0bf1f8c531853b"
dependencies = [
- "windows-targets 0.52.6",
-]
-
-[[package]]
-name = "windows-sys"
-version = "0.60.2"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f2f500e4d28234f72040990ec9d39e3a6b950f9f22d3dba18416c35882612bcb"
-dependencies = [
- "windows-targets 0.53.5",
+ "windows-targets",
]
[[package]]
@@ -4324,31 +4549,14 @@ version = "0.52.6"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "9b724f72796e036ab90c1021d4780d4d3d648aca59e491e6b98e725b84e99973"
dependencies = [
- "windows_aarch64_gnullvm 0.52.6",
- "windows_aarch64_msvc 0.52.6",
- "windows_i686_gnu 0.52.6",
- "windows_i686_gnullvm 0.52.6",
- "windows_i686_msvc 0.52.6",
- "windows_x86_64_gnu 0.52.6",
- "windows_x86_64_gnullvm 0.52.6",
- "windows_x86_64_msvc 0.52.6",
-]
-
-[[package]]
-name = "windows-targets"
-version = "0.53.5"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "4945f9f551b88e0d65f3db0bc25c33b8acea4d9e41163edf90dcd0b19f9069f3"
-dependencies = [
- "windows-link",
- "windows_aarch64_gnullvm 0.53.1",
- "windows_aarch64_msvc 0.53.1",
- "windows_i686_gnu 0.53.1",
- "windows_i686_gnullvm 0.53.1",
- "windows_i686_msvc 0.53.1",
- "windows_x86_64_gnu 0.53.1",
- "windows_x86_64_gnullvm 0.53.1",
- "windows_x86_64_msvc 0.53.1",
+ "windows_aarch64_gnullvm",
+ "windows_aarch64_msvc",
+ "windows_i686_gnu",
+ "windows_i686_gnullvm",
+ "windows_i686_msvc",
+ "windows_x86_64_gnu",
+ "windows_x86_64_gnullvm",
+ "windows_x86_64_msvc",
]
[[package]]
@@ -4357,96 +4565,48 @@ version = "0.52.6"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "32a4622180e7a0ec044bb555404c800bc9fd9ec262ec147edd5989ccd0c02cd3"
-[[package]]
-name = "windows_aarch64_gnullvm"
-version = "0.53.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "a9d8416fa8b42f5c947f8482c43e7d89e73a173cead56d044f6a56104a6d1b53"
-
[[package]]
name = "windows_aarch64_msvc"
version = "0.52.6"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "09ec2a7bb152e2252b53fa7803150007879548bc709c039df7627cabbd05d469"
-[[package]]
-name = "windows_aarch64_msvc"
-version = "0.53.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "b9d782e804c2f632e395708e99a94275910eb9100b2114651e04744e9b125006"
-
[[package]]
name = "windows_i686_gnu"
version = "0.52.6"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "8e9b5ad5ab802e97eb8e295ac6720e509ee4c243f69d781394014ebfe8bbfa0b"
-[[package]]
-name = "windows_i686_gnu"
-version = "0.53.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "960e6da069d81e09becb0ca57a65220ddff016ff2d6af6a223cf372a506593a3"
-
[[package]]
name = "windows_i686_gnullvm"
version = "0.52.6"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "0eee52d38c090b3caa76c563b86c3a4bd71ef1a819287c19d586d7334ae8ed66"
-[[package]]
-name = "windows_i686_gnullvm"
-version = "0.53.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "fa7359d10048f68ab8b09fa71c3daccfb0e9b559aed648a8f95469c27057180c"
-
[[package]]
name = "windows_i686_msvc"
version = "0.52.6"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "240948bc05c5e7c6dabba28bf89d89ffce3e303022809e73deaefe4f6ec56c66"
-[[package]]
-name = "windows_i686_msvc"
-version = "0.53.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "1e7ac75179f18232fe9c285163565a57ef8d3c89254a30685b57d83a38d326c2"
-
[[package]]
name = "windows_x86_64_gnu"
version = "0.52.6"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "147a5c80aabfbf0c7d901cb5895d1de30ef2907eb21fbbab29ca94c5b08b1a78"
-[[package]]
-name = "windows_x86_64_gnu"
-version = "0.53.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "9c3842cdd74a865a8066ab39c8a7a473c0778a3f29370b5fd6b4b9aa7df4a499"
-
[[package]]
name = "windows_x86_64_gnullvm"
version = "0.52.6"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "24d5b23dc417412679681396f2b49f3de8c1473deb516bd34410872eff51ed0d"
-[[package]]
-name = "windows_x86_64_gnullvm"
-version = "0.53.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "0ffa179e2d07eee8ad8f57493436566c7cc30ac536a3379fdf008f47f6bb7ae1"
-
[[package]]
name = "windows_x86_64_msvc"
version = "0.52.6"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec"
-[[package]]
-name = "windows_x86_64_msvc"
-version = "0.53.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "d6bbff5f0aada427a1e5a6da5f1f98158182f26556f345ac9e04d36d0ebed650"
-
[[package]]
name = "wit-bindgen"
version = "0.46.0"
@@ -4469,22 +4629,15 @@ dependencies = [
]
[[package]]
-name = "x11rb"
-version = "0.13.2"
+name = "xattr"
+version = "1.6.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "9993aa5be5a26815fe2c3eacfc1fde061fc1a1f094bf1ad2a18bf9c495dd7414"
+checksum = "32e45ad4206f6d2479085147f02bc2ef834ac85886624a23575ae137c8aa8156"
dependencies = [
- "gethostname",
+ "libc",
"rustix 1.1.4",
- "x11rb-protocol",
]
-[[package]]
-name = "x11rb-protocol"
-version = "0.13.2"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "ea6fc2961e4ef194dcbfe56bb845534d0dc8098940c7e5c012a258bfec6701bd"
-
[[package]]
name = "y4m"
version = "0.8.0"
@@ -4594,6 +4747,30 @@ dependencies = [
"syn 2.0.119",
]
+[[package]]
+name = "zip"
+version = "6.0.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "eb2a05c7c36fde6c09b08576c9f7fb4cda705990f73b58fe011abf7dfb24168b"
+dependencies = [
+ "arbitrary",
+ "crc32fast",
+ "indexmap",
+ "memchr",
+ "time",
+]
+
+[[package]]
+name = "zipsign-api"
+version = "0.1.5"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "dba6063ff82cdbd9a765add16d369abe81e520f836054e997c2db217ceca40c0"
+dependencies = [
+ "base64",
+ "ed25519-dalek",
+ "thiserror 2.0.19",
+]
+
[[package]]
name = "zmij"
version = "1.0.23"
diff --git a/Cargo.toml b/Cargo.toml
index dafaf1a..02ff1e0 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "moviebox-tui"
exclude = ["assets/", ".github/", "scripts/", "install.sh", "install.ps1"]
-version = "0.1.4"
+version = "0.1.5"
edition = "2024"
description = "A terminal client for finding and streaming movies, TV shows, and anime from the MovieBox catalog."
repository = "https://github.com/mesamirh/MovieBox-Tui"
diff --git a/README.md b/README.md
index f9725b5..1960990 100644
--- a/README.md
+++ b/README.md
@@ -63,26 +63,16 @@ A short walkthrough of the app in action:
## What it can do
**Search and discovery**
-- Type-to-search with live, debounced suggestions.
-- Slash commands to browse curated feeds: `/movies`, `/shows`, `/anime`, `/discover`.
-- Each result shows a poster, release year, and (when highlighted) IMDb rating and genres.
+The search bar is always active. Just start typing to get live, debounced suggestions, or use slash commands like `/movies`, `/shows`, `/anime`, `/discover`, and `/home` to browse curated trending feeds. When you hover over a result, you instantly see its full poster, release year, IMDb rating, and genres.
**Playback**
-- Detects `mpv`, `IINA`, and `VLC` at startup. You get a picker for whatever you have installed.
-- Full season and episode browsing for TV series and anime, with per-episode stream resolution.
-- Multiple resolutions (1080p, 720p, 480p, 360p) are fetched in parallel and listed by quality.
-- Attach external subtitle tracks, and switch between available audio dubs before playing.
-- If a stream fails or expires, hit <kbd>R</kbd> to re-resolve it.
+The app automatically detects if you have `mpv`, `IINA`, or `VLC` installed. You get full access to season and episode browsing for TV series and anime. When you pick an episode, it concurrently fetches multiple resolutions (1080p, 720p, 480p) in parallel so you can choose a quality instantly. You can also pick external subtitle tracks and switch between audio dubs before playing. If a stream expires, pressing <kbd>R</kbd> re-resolves it on the fly.
-**Downloading and sharing**
-- Built-in multi-connection downloader. Uses up to 16 parallel connections when the source allows range requests, with live speed, ETA, progress bar, and cancel.
-- Copy any direct stream URL to your clipboard with a single keystroke.
-- Downloads go to your system Downloads folder.
+**Downloading**
+If you want to save a video for later, the built-in downloader uses up to 16 parallel connections to max out your bandwidth. It shows live download speed, an ETA, and a progress bar directly in the interface. Everything saves cleanly to your system's default Downloads folder.
**The interface**
-- Real poster art rendered inline in terminals that support graphics (Kitty, WezTerm, iTerm2, Ghostty, foot, etc.).
-- In-app notification when a newer version is published to crates.io.
-- The details view shows the poster, IMDb rating, year, genres, duration, country, and full description alongside the season, episode, and stream panels.
+If you use a modern terminal like Kitty, WezTerm, iTerm2, Ghostty, or foot, all movie posters are rendered natively as high-resolution images right in your terminal. The details view is packed with metadata, including duration, country of origin, and a full synopsis. The app also silently checks GitHub releases in the background and notifies you if there's a newer version available, which you can manage with `/update` or `/toggle-update`.
---
@@ -145,13 +135,13 @@ A short walkthrough of the app in action:
## Requirements
-You need three things:
+You only need two things to use MovieBox-Tui: a compatible video player and a reasonably sized terminal.
-1. **A video player.** `mpv` is the default and the most reliable. `IINA` (macOS) and `VLC` also work. The app detects whichever you have installed.
-2. **A terminal at least 85×24.** Anything smaller and the app will show a message asking you to enlarge it.
-3. **Rust 1.85 or newer** (edition 2024), only if you want to build from source. See [rustup.rs](https://rustup.rs/). If you install from crates.io, you already have it.
+**Video Player:** The app relies on your system's video players to handle playback. `mpv`, `IINA` (on macOS), and `VLC` are all fully supported. The app will automatically detect whichever players you have installed.
-For inline poster art, you'll want a terminal that speaks a graphics protocol: **Kitty, WezTerm, iTerm2, Ghostty**, or **foot**. Other terminals still work fine, you just get placeholder blocks instead of images.
+**Terminal Size:** Make sure your terminal window is at least 85×24 characters. If you launch the app in a window that's too small, it will pause and ask you to enlarge it. For the best experience with inline poster art, you'll want to use a terminal that speaks a modern graphics protocol like Kitty, WezTerm, iTerm2, Ghostty, or foot. Other terminals still work perfectly fine, but they will gracefully fall back to text placeholders instead of full images.
+
+**(Optional) Rust:** If you prefer to build the app from source or install it via Cargo, you will need Rust 1.85 or newer (edition 2024). However, if you use the automated installation scripts or download a pre-built binary, you don't need Rust installed at all.
<details>
<summary><b>How to install a video player</b></summary>
@@ -229,22 +219,13 @@ cargo install moviebox-tui
## Getting started
-Launch the app:
-
-```bash
-moviebox-tui
-```
+Launch the app by typing `moviebox-tui` in your terminal.
-You'll land on the home screen. From there:
+Once you land on the home screen, you can simply start typing to instantly search for any title, or use a slash command like `/movies` or `/discover` to browse curated trending feeds. Navigate through the results using your arrow keys, and press <kbd>Enter</kbd> to view the full details of any title.
-1. Just start typing. The search bar activates automatically and live suggestions appear as you type.
-2. Or use a discover command: type `/movies`, `/shows`, `/anime`, or `/discover` and press <kbd>Enter</kbd> to browse curated feeds.
-3. Move through results with <kbd>Up</kbd>/<kbd>Down</kbd>. The selected result loads a poster preview with IMDb rating and genres.
-4. Press <kbd>Enter</kbd> to open the details view.
-5. For a TV series, pick a season and episode. If multiple language dubs are available, you'll be asked to pick one.
-6. Choose a stream quality and hit <kbd>Enter</kbd> to play in `mpv`, or <kbd>o</kbd> to pick a different player.
+From the details view, you can browse seasons and episodes. Once you select an episode, pick your preferred stream quality and press <kbd>Enter</kbd> to instantly start playing it in your default video player. If you want to use a different player, press <kbd>o</kbd>.
-Press <kbd>?</kbd> at any time to see all keybindings.
+You can press <kbd>?</kbd> at any time to see the full list of keybindings.
---
@@ -277,9 +258,19 @@ Press <kbd>?</kbd> at any time to see all keybindings.
| <kbd>o</kbd> | Choose a different player (`mpv`, `IINA`, or `VLC`) |
| <kbd>R</kbd> | Refresh streams. Useful when a link expires or fails. |
| <kbd>d</kbd> | Download the selected stream |
-| <kbd>c</kbd> | Copy the direct stream URL to the clipboard |
| <kbd>x</kbd> | Cancel an in-progress download |
+### Slash Commands
+You can type these into the search bar:
+
+| Command | Action |
+| :--- | :--- |
+| `/discover`, `/home` | Browse trending titles |
+| `/movies`, `/shows`, `/anime` | Browse specific categories |
+| `/update` | Check for newer versions manually |
+| `/toggle-update` | Toggle automatic update checking on startup |
+| `/github` | Open the source repository in your browser |
+
---
## How it works
@@ -360,6 +351,14 @@ Direct stream URLs are short-lived and expire after some time. On the details sc
</details>
+<details>
+<summary><b>"Failed to check for updates" on startup</b></summary>
+<br>
+
+The app checks GitHub for the latest release on startup. GitHub limits unauthenticated requests to 60 per hour per IP address. If you open and close the app many times in a short period, you might temporarily hit this limit. You can use the `/toggle-update` slash command to disable startup update checks and bypass this error.
+
+</details>
+
<details>
<summary><b>Downloads are slow or crawl</b></summary>
<br>
diff --git a/src/tui/app.rs b/src/tui/app.rs
index 7ebb649..a9def7a 100644
--- a/src/tui/app.rs
+++ b/src/tui/app.rs
@@ -58,10 +58,15 @@ impl App {
let config_path = config_dir.join("moviebox-tui").join("config.json");
if let Ok(config_str) = std::fs::read_to_string(config_path) {
if let Ok(config_json) = serde_json::from_str::<serde_json::Value>(&config_str) {
- if let Some(auto_update) = config_json.get("auto_update").and_then(|v| v.as_bool()) {
+ if let Some(auto_update) =
+ config_json.get("auto_update").and_then(|v| v.as_bool())
+ {
state.auto_update = auto_update;
}
- if let Some(last_check) = config_json.get("last_update_check").and_then(|v| v.as_u64()) {
+ if let Some(last_check) = config_json
+ .get("last_update_check")
+ .and_then(|v| v.as_u64())
+ {
state.last_update_check = last_check;
}
}
@@ -195,7 +200,11 @@ impl App {
let player_sender = self.action_sender.clone();
tokio::task::spawn_blocking(move || {
let mut players = Vec::new();
- let which_cmd = if cfg!(target_os = "windows") { "where" } else { "which" };
+ let which_cmd = if cfg!(target_os = "windows") {
+ "where"
+ } else {
+ "which"
+ };
let check_player = |cmd: &str| -> bool {
std::process::Command::new(which_cmd)
.arg(cmd)
@@ -206,9 +215,7 @@ impl App {
#[cfg(target_os = "macos")]
{
- if std::path::Path::new("/Applications/IINA.app").exists()
- || check_player("iina")
- {
+ if std::path::Path::new("/Applications/IINA.app").exists() || check_player("iina") {
players.push(crate::tui::state::PlayerKind::Iina);
}
}
@@ -358,7 +365,7 @@ impl App {
&& self.state.download_progress.is_some()
{
self.action_sender.send(Action::CancelDownload).ok();
- return Some(());
+ return None;
}
if key.code == KeyCode::F(1) {
@@ -726,8 +733,16 @@ impl App {
self.state.input_mode = InputMode::Normal;
self.state.toast_message = Some(format!(
"{} Auto Update is now {}",
- if self.state.basic_terminal { "[!]" } else { "!" },
- if self.state.auto_update { "Enabled" } else { "Disabled" }
+ if self.state.basic_terminal {
+ "[!]"
+ } else {
+ "!"
+ },
+ if self.state.auto_update {
+ "Enabled"
+ } else {
+ "Disabled"
+ }
));
self.state.toast_timer = 50;
return None;
@@ -1843,7 +1858,11 @@ impl App {
None => {
self.state.toast_message = Some(format!(
"{} No media player found. Install mpv, IINA, or VLC.",
- if self.state.basic_terminal { "[X]" } else { "✗" }
+ if self.state.basic_terminal {
+ "[X]"
+ } else {
+ "✗"
+ }
));
self.state.toast_timer = 150;
}
@@ -1855,12 +1874,18 @@ impl App {
};
self.state.toast_message = Some(format!(
"{} Launching {}...",
- if self.state.basic_terminal { "[OK]" } else { "✓" },
+ if self.state.basic_terminal {
+ "[OK]"
+ } else {
+ "✓"
+ },
player_name
));
self.state.toast_timer = 40;
- self.action_sender.send(Action::LaunchPlayer(kind, link, subtitle_url)).ok();
+ self.action_sender
+ .send(Action::LaunchPlayer(kind, link, subtitle_url))
+ .ok();
}
}
}
@@ -1879,9 +1904,13 @@ impl App {
.unwrap_or("MovieBox-Tui_Stream")
.to_string();
let ext = "mp4";
+ let mut sanitized_title = title.replace(" ", "_");
+ for c in &['/', '\\', ':', '*', '?', '"', '<', '>', '|'] {
+ sanitized_title = sanitized_title.replace(*c, "_");
+ }
let filename = format!(
"{}_{}.{}",
- title.replace(" ", "_").replace("/", "_"),
+ sanitized_title,
std::time::SystemTime::now()
.duration_since(std::time::UNIX_EPOCH)
.unwrap()
@@ -2723,10 +2752,18 @@ impl App {
let mut cmd = match kind {
crate::tui::state::PlayerKind::Mpv => {
- let mut c = if std::path::Path::new("C:\\Program Files\\mpv\\mpv.exe").exists() {
+ let mut c = if std::path::Path::new("C:\\Program Files\\mpv\\mpv.exe")
+ .exists()
+ {
std::process::Command::new("C:\\Program Files\\mpv\\mpv.exe")
- } else if std::path::Path::new("/Applications/mpv.app/Contents/MacOS/mpv").exists() {
- std::process::Command::new("/Applications/mpv.app/Contents/MacOS/mpv")
+ } else if std::path::Path::new(
+ "/Applications/mpv.app/Contents/MacOS/mpv",
+ )
+ .exists()
+ {
+ std::process::Command::new(
+ "/Applications/mpv.app/Contents/MacOS/mpv",
+ )
} else {
std::process::Command::new("mpv")
};
@@ -2797,7 +2834,7 @@ impl App {
let update_sender = self.action_sender.clone();
tokio::spawn(async move {
let start = std::time::Instant::now();
-
+
let result = tokio::task::spawn_blocking(move || {
let builder = self_update::backends::github::Update::configure()
.repo_owner("mesamirh")
@@ -2806,11 +2843,13 @@ impl App {
.show_download_progress(false)
.current_version(env!("CARGO_PKG_VERSION"))
.build();
-
+
if let Ok(updater) = builder {
if let Ok(release) = updater.get_latest_release() {
let current = self_update::cargo_crate_version!();
- if self_update::version::bump_is_greater(current, &release.version).unwrap_or(false) {
+ if self_update::version::bump_is_greater(current, &release.version)
+ .unwrap_or(false)
+ {
return Some(release.version.clone());
} else {
return Some("none".to_string());
@@ -2818,7 +2857,9 @@ impl App {
}
}
Some("error".to_string())
- }).await.unwrap_or(Some("error".to_string()));
+ })
+ .await
+ .unwrap_or(Some("error".to_string()));
let elapsed = start.elapsed();
if elapsed.as_millis() < 1500 {
@@ -2835,9 +2876,11 @@ impl App {
if self.state.active_screen == Screen::Startup {
self.state.active_screen = Screen::Home;
if version == "none" {
- self.state.toast_message = Some("You are on the latest version!".to_string());
+ self.state.toast_message =
+ Some("You are on the latest version!".to_string());
} else {
- self.state.toast_message = Some("Failed to check for updates.".to_string());
+ self.state.toast_message =
+ Some("Failed to check for updates.".to_string());
}
self.state.toast_timer = 150;
}
@@ -2860,14 +2903,16 @@ impl App {
.bin_name("moviebox-tui")
.show_download_progress(false)
.current_version(env!("CARGO_PKG_VERSION"));
-
+
if let Ok(updater) = builder.build() {
if let Ok(_status) = updater.update() {
update_sender.send(Action::UpdateSuccess).ok();
return;
}
}
- update_sender.send(Action::UpdateFailure("Failed".into())).ok();
+ update_sender
+ .send(Action::UpdateFailure("Failed".into()))
+ .ok();
});
let progress_sender = self.action_sender.clone();
@@ -2876,7 +2921,9 @@ impl App {
loop {
tokio::time::sleep(std::time::Duration::from_millis(150)).await;
p += 0.01;
- if p > 0.98 { p = 0.98; }
+ if p > 0.98 {
+ p = 0.98;
+ }
progress_sender.send(Action::UpdateProgress(p)).ok();
}
});
@@ -2889,10 +2936,10 @@ impl App {
Action::UpdateSuccess => {
self.state.updater_done = true;
self.state.updater_progress = Some(1.0);
-
+
let exe = std::env::current_exe().unwrap();
let _ = std::process::Command::new(exe).spawn();
- return Some(());
+ return Some(());
}
Action::UpdateFailure(_err) => {
self.state.active_screen = Screen::Home;
diff --git a/src/tui/screens/startup.rs b/src/tui/screens/startup.rs
index e8d98da..1875973 100644
--- a/src/tui/screens/startup.rs
+++ b/src/tui/screens/startup.rs
@@ -3,7 +3,7 @@ use ratatui::{
Frame,
layout::{Alignment, Constraint, Direction, Layout, Rect},
text::{Line, Span},
- widgets::{Paragraph},
+ widgets::Paragraph,
};
const QUOTES: &[&str] = &[