├── .github └── workflows │ ├── ci.yaml │ └── release.yaml ├── .gitignore ├── Cargo.lock ├── Cargo.toml ├── LICENSE ├── Readme.md ├── Release.md ├── assets └── logo.png └── src ├── app.rs ├── event.rs ├── handler.rs ├── lib.rs ├── main.rs ├── notifications.rs ├── tui.rs └── ui.rs /.github/workflows/ci.yaml: -------------------------------------------------------------------------------- 1 | --- 2 | name: CI 3 | on: 4 | pull_request: 5 | push: 6 | branches: 7 | - "*" 8 | jobs: 9 | test: 10 | runs-on: ubuntu-latest 11 | steps: 12 | - uses: actions/checkout@v4 13 | - uses: dtolnay/rust-toolchain@stable 14 | with: 15 | toolchain: stable 16 | components: clippy rustfmt 17 | 18 | - name: Linting 19 | run: | 20 | cargo clippy --workspace --all-features -- -D warnings 21 | cargo fmt --all -- --check 22 | 23 | - name: Debug builds 24 | run: cargo build 25 | -------------------------------------------------------------------------------- /.github/workflows/release.yaml: -------------------------------------------------------------------------------- 1 | --- 2 | name: Release 3 | on: 4 | push: 5 | tags: 6 | - "*" 7 | jobs: 8 | build: 9 | permissions: 10 | contents: write 11 | continue-on-error: false 12 | runs-on: ubuntu-latest 13 | steps: 14 | - name: Checkout 15 | uses: actions/checkout@v4 16 | 17 | - uses: cargo-bins/cargo-binstall@main 18 | 19 | - name: Install the dependencies 20 | run: | 21 | sudo apt update 22 | sudo apt install -y podman binutils-aarch64-linux-gnu musl-tools 23 | cargo binstall -y cross 24 | 25 | - name: Build for arm64 musl 26 | run: | 27 | CROSS_CONTAINER_ENGINE=podman cross build --target aarch64-unknown-linux-musl --release 28 | cp target/aarch64-unknown-linux-musl/release/lobtui lobtui-aarch64-unknown-linux-musl 29 | 30 | - name: Build for x86_64 musl 31 | run: | 32 | CROSS_CONTAINER_ENGINE=podman cross build --target x86_64-unknown-linux-musl --release 33 | cp target/x86_64-unknown-linux-musl/release/lobtui lobtui-x86_64-unknown-linux-musl 34 | 35 | - name: Upload Binary 36 | uses: softprops/action-gh-release@v2 37 | with: 38 | files: "lobtui*" 39 | body: | 40 | [Release.md](${{ github.server_url }}/${{ github.repository }}/blob/main/Release.md) 41 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | /target 2 | -------------------------------------------------------------------------------- /Cargo.lock: -------------------------------------------------------------------------------- 1 | # This file is automatically @generated by Cargo. 2 | # It is not intended for manual editing. 3 | version = 4 4 | 5 | [[package]] 6 | name = "addr2line" 7 | version = "0.24.2" 8 | source = "registry+https://github.com/rust-lang/crates.io-index" 9 | checksum = "dfbe277e56a376000877090da837660b4427aad530e3028d44e0bffe4f89a1c1" 10 | dependencies = [ 11 | "gimli", 12 | ] 13 | 14 | [[package]] 15 | name = "adler2" 16 | version = "2.0.0" 17 | source = "registry+https://github.com/rust-lang/crates.io-index" 18 | checksum = "512761e0bb2578dd7380c6baaa0f4ce03e84f95e960231d1dec8bf4d7d6e2627" 19 | 20 | [[package]] 21 | name = "allocator-api2" 22 | version = "0.2.21" 23 | source = "registry+https://github.com/rust-lang/crates.io-index" 24 | checksum = "683d7910e743518b0e34f1186f92494becacb047c7b6bf616c96772180fef923" 25 | 26 | [[package]] 27 | name = "anstream" 28 | version = "0.6.18" 29 | source = "registry+https://github.com/rust-lang/crates.io-index" 30 | checksum = "8acc5369981196006228e28809f761875c0327210a891e941f4c683b3a99529b" 31 | dependencies = [ 32 | "anstyle", 33 | "anstyle-parse", 34 | "anstyle-query", 35 | "anstyle-wincon", 36 | "colorchoice", 37 | "is_terminal_polyfill", 38 | "utf8parse", 39 | ] 40 | 41 | [[package]] 42 | name = "anstyle" 43 | version = "1.0.10" 44 | source = "registry+https://github.com/rust-lang/crates.io-index" 45 | checksum = "55cc3b69f167a1ef2e161439aa98aed94e6028e5f9a59be9a6ffb47aef1651f9" 46 | 47 | [[package]] 48 | name = "anstyle-parse" 49 | version = "0.2.6" 50 | source = "registry+https://github.com/rust-lang/crates.io-index" 51 | checksum = "3b2d16507662817a6a20a9ea92df6652ee4f94f914589377d69f3b21bc5798a9" 52 | dependencies = [ 53 | "utf8parse", 54 | ] 55 | 56 | [[package]] 57 | name = "anstyle-query" 58 | version = "1.1.2" 59 | source = "registry+https://github.com/rust-lang/crates.io-index" 60 | checksum = "79947af37f4177cfead1110013d678905c37501914fba0efea834c3fe9a8d60c" 61 | dependencies = [ 62 | "windows-sys 0.59.0", 63 | ] 64 | 65 | [[package]] 66 | name = "anstyle-wincon" 67 | version = "3.0.7" 68 | source = "registry+https://github.com/rust-lang/crates.io-index" 69 | checksum = "ca3534e77181a9cc07539ad51f2141fe32f6c3ffd4df76db8ad92346b003ae4e" 70 | dependencies = [ 71 | "anstyle", 72 | "once_cell", 73 | "windows-sys 0.59.0", 74 | ] 75 | 76 | [[package]] 77 | name = "autocfg" 78 | version = "1.4.0" 79 | source = "registry+https://github.com/rust-lang/crates.io-index" 80 | checksum = "ace50bade8e6234aa140d9a2f552bbee1db4d353f69b8217bc503490fc1a9f26" 81 | 82 | [[package]] 83 | name = "backtrace" 84 | version = "0.3.75" 85 | source = "registry+https://github.com/rust-lang/crates.io-index" 86 | checksum = "6806a6321ec58106fea15becdad98371e28d92ccbc7c8f1b3b6dd724fe8f1002" 87 | dependencies = [ 88 | "addr2line", 89 | "cfg-if", 90 | "libc", 91 | "miniz_oxide", 92 | "object", 93 | "rustc-demangle", 94 | "windows-targets 0.52.6", 95 | ] 96 | 97 | [[package]] 98 | name = "base64" 99 | version = "0.22.1" 100 | source = "registry+https://github.com/rust-lang/crates.io-index" 101 | checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6" 102 | 103 | [[package]] 104 | name = "bitflags" 105 | version = "2.9.1" 106 | source = "registry+https://github.com/rust-lang/crates.io-index" 107 | checksum = "1b8e56985ec62d17e9c1001dc89c88ecd7dc08e47eba5ec7c29c7b5eeecde967" 108 | 109 | [[package]] 110 | name = "bumpalo" 111 | version = "3.17.0" 112 | source = "registry+https://github.com/rust-lang/crates.io-index" 113 | checksum = "1628fb46dfa0b37568d12e5edd512553eccf6a22a78e8bde00bb4aed84d5bdbf" 114 | 115 | [[package]] 116 | name = "byteorder" 117 | version = "1.5.0" 118 | source = "registry+https://github.com/rust-lang/crates.io-index" 119 | checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" 120 | 121 | [[package]] 122 | name = "bytes" 123 | version = "1.10.1" 124 | source = "registry+https://github.com/rust-lang/crates.io-index" 125 | checksum = "d71b6127be86fdcfddb610f7182ac57211d4b18a3e9c82eb2d17662f2227ad6a" 126 | 127 | [[package]] 128 | name = "cassowary" 129 | version = "0.3.0" 130 | source = "registry+https://github.com/rust-lang/crates.io-index" 131 | checksum = "df8670b8c7b9dae1793364eafadf7239c40d669904660c5960d74cfd80b46a53" 132 | 133 | [[package]] 134 | name = "castaway" 135 | version = "0.2.3" 136 | source = "registry+https://github.com/rust-lang/crates.io-index" 137 | checksum = "0abae9be0aaf9ea96a3b1b8b1b55c602ca751eba1b1500220cea4ecbafe7c0d5" 138 | dependencies = [ 139 | "rustversion", 140 | ] 141 | 142 | [[package]] 143 | name = "cc" 144 | version = "1.2.23" 145 | source = "registry+https://github.com/rust-lang/crates.io-index" 146 | checksum = "5f4ac86a9e5bc1e2b3449ab9d7d3a6a405e3d1bb28d7b9be8614f55846ae3766" 147 | dependencies = [ 148 | "shlex", 149 | ] 150 | 151 | [[package]] 152 | name = "cfg-if" 153 | version = "1.0.0" 154 | source = "registry+https://github.com/rust-lang/crates.io-index" 155 | checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" 156 | 157 | [[package]] 158 | name = "cfg_aliases" 159 | version = "0.2.1" 160 | source = "registry+https://github.com/rust-lang/crates.io-index" 161 | checksum = "613afe47fcd5fac7ccf1db93babcb082c5994d996f20b8b159f2ad1658eb5724" 162 | 163 | [[package]] 164 | name = "clap" 165 | version = "4.5.38" 166 | source = "registry+https://github.com/rust-lang/crates.io-index" 167 | checksum = "ed93b9805f8ba930df42c2590f05453d5ec36cbb85d018868a5b24d31f6ac000" 168 | dependencies = [ 169 | "clap_builder", 170 | "clap_derive", 171 | ] 172 | 173 | [[package]] 174 | name = "clap_builder" 175 | version = "4.5.38" 176 | source = "registry+https://github.com/rust-lang/crates.io-index" 177 | checksum = "379026ff283facf611b0ea629334361c4211d1b12ee01024eec1591133b04120" 178 | dependencies = [ 179 | "anstream", 180 | "anstyle", 181 | "clap_lex", 182 | "strsim", 183 | ] 184 | 185 | [[package]] 186 | name = "clap_derive" 187 | version = "4.5.32" 188 | source = "registry+https://github.com/rust-lang/crates.io-index" 189 | checksum = "09176aae279615badda0765c0c0b3f6ed53f4709118af73cf4655d85d1530cd7" 190 | dependencies = [ 191 | "heck", 192 | "proc-macro2", 193 | "quote", 194 | "syn", 195 | ] 196 | 197 | [[package]] 198 | name = "clap_lex" 199 | version = "0.7.4" 200 | source = "registry+https://github.com/rust-lang/crates.io-index" 201 | checksum = "f46ad14479a25103f283c0f10005961cf086d8dc42205bb44c46ac563475dca6" 202 | 203 | [[package]] 204 | name = "color-eyre" 205 | version = "0.6.4" 206 | source = "registry+https://github.com/rust-lang/crates.io-index" 207 | checksum = "e6e1761c0e16f8883bbbb8ce5990867f4f06bf11a0253da6495a04ce4b6ef0ec" 208 | dependencies = [ 209 | "backtrace", 210 | "color-spantrace", 211 | "eyre", 212 | "indenter", 213 | "once_cell", 214 | "owo-colors", 215 | "tracing-error", 216 | ] 217 | 218 | [[package]] 219 | name = "color-spantrace" 220 | version = "0.2.2" 221 | source = "registry+https://github.com/rust-lang/crates.io-index" 222 | checksum = "2ddd8d5bfda1e11a501d0a7303f3bfed9aa632ebdb859be40d0fd70478ed70d5" 223 | dependencies = [ 224 | "once_cell", 225 | "owo-colors", 226 | "tracing-core", 227 | "tracing-error", 228 | ] 229 | 230 | [[package]] 231 | name = "colorchoice" 232 | version = "1.0.3" 233 | source = "registry+https://github.com/rust-lang/crates.io-index" 234 | checksum = "5b63caa9aa9397e2d9480a9b13673856c78d8ac123288526c37d7839f2a86990" 235 | 236 | [[package]] 237 | name = "compact_str" 238 | version = "0.8.1" 239 | source = "registry+https://github.com/rust-lang/crates.io-index" 240 | checksum = "3b79c4069c6cad78e2e0cdfcbd26275770669fb39fd308a752dc110e83b9af32" 241 | dependencies = [ 242 | "castaway", 243 | "cfg-if", 244 | "itoa", 245 | "rustversion", 246 | "ryu", 247 | "static_assertions", 248 | ] 249 | 250 | [[package]] 251 | name = "crossterm" 252 | version = "0.28.1" 253 | source = "registry+https://github.com/rust-lang/crates.io-index" 254 | checksum = "829d955a0bb380ef178a640b91779e3987da38c9aea133b20614cfed8cdea9c6" 255 | dependencies = [ 256 | "bitflags", 257 | "crossterm_winapi", 258 | "futures-core", 259 | "mio", 260 | "parking_lot", 261 | "rustix", 262 | "signal-hook", 263 | "signal-hook-mio", 264 | "winapi", 265 | ] 266 | 267 | [[package]] 268 | name = "crossterm_winapi" 269 | version = "0.9.1" 270 | source = "registry+https://github.com/rust-lang/crates.io-index" 271 | checksum = "acdd7c62a3665c7f6830a51635d9ac9b23ed385797f70a83bb8bafe9c572ab2b" 272 | dependencies = [ 273 | "winapi", 274 | ] 275 | 276 | [[package]] 277 | name = "cssparser" 278 | version = "0.34.0" 279 | source = "registry+https://github.com/rust-lang/crates.io-index" 280 | checksum = "b7c66d1cd8ed61bf80b38432613a7a2f09401ab8d0501110655f8b341484a3e3" 281 | dependencies = [ 282 | "cssparser-macros", 283 | "dtoa-short", 284 | "itoa", 285 | "phf", 286 | "smallvec", 287 | ] 288 | 289 | [[package]] 290 | name = "cssparser-macros" 291 | version = "0.6.1" 292 | source = "registry+https://github.com/rust-lang/crates.io-index" 293 | checksum = "13b588ba4ac1a99f7f2964d24b3d896ddc6bf847ee3855dbd4366f058cfcd331" 294 | dependencies = [ 295 | "quote", 296 | "syn", 297 | ] 298 | 299 | [[package]] 300 | name = "darling" 301 | version = "0.20.11" 302 | source = "registry+https://github.com/rust-lang/crates.io-index" 303 | checksum = "fc7f46116c46ff9ab3eb1597a45688b6715c6e628b5c133e288e709a29bcb4ee" 304 | dependencies = [ 305 | "darling_core", 306 | "darling_macro", 307 | ] 308 | 309 | [[package]] 310 | name = "darling_core" 311 | version = "0.20.11" 312 | source = "registry+https://github.com/rust-lang/crates.io-index" 313 | checksum = "0d00b9596d185e565c2207a0b01f8bd1a135483d02d9b7b0a54b11da8d53412e" 314 | dependencies = [ 315 | "fnv", 316 | "ident_case", 317 | "proc-macro2", 318 | "quote", 319 | "strsim", 320 | "syn", 321 | ] 322 | 323 | [[package]] 324 | name = "darling_macro" 325 | version = "0.20.11" 326 | source = "registry+https://github.com/rust-lang/crates.io-index" 327 | checksum = "fc34b93ccb385b40dc71c6fceac4b2ad23662c7eeb248cf10d529b7e055b6ead" 328 | dependencies = [ 329 | "darling_core", 330 | "quote", 331 | "syn", 332 | ] 333 | 334 | [[package]] 335 | name = "derive_more" 336 | version = "0.99.20" 337 | source = "registry+https://github.com/rust-lang/crates.io-index" 338 | checksum = "6edb4b64a43d977b8e99788fe3a04d483834fba1215a7e02caa415b626497f7f" 339 | dependencies = [ 340 | "proc-macro2", 341 | "quote", 342 | "syn", 343 | ] 344 | 345 | [[package]] 346 | name = "displaydoc" 347 | version = "0.2.5" 348 | source = "registry+https://github.com/rust-lang/crates.io-index" 349 | checksum = "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0" 350 | dependencies = [ 351 | "proc-macro2", 352 | "quote", 353 | "syn", 354 | ] 355 | 356 | [[package]] 357 | name = "dtoa" 358 | version = "1.0.10" 359 | source = "registry+https://github.com/rust-lang/crates.io-index" 360 | checksum = "d6add3b8cff394282be81f3fc1a0605db594ed69890078ca6e2cab1c408bcf04" 361 | 362 | [[package]] 363 | name = "dtoa-short" 364 | version = "0.3.5" 365 | source = "registry+https://github.com/rust-lang/crates.io-index" 366 | checksum = "cd1511a7b6a56299bd043a9c167a6d2bfb37bf84a6dfceaba651168adfb43c87" 367 | dependencies = [ 368 | "dtoa", 369 | ] 370 | 371 | [[package]] 372 | name = "ego-tree" 373 | version = "0.10.0" 374 | source = "registry+https://github.com/rust-lang/crates.io-index" 375 | checksum = "b2972feb8dffe7bc8c5463b1dacda1b0dfbed3710e50f977d965429692d74cd8" 376 | 377 | [[package]] 378 | name = "either" 379 | version = "1.15.0" 380 | source = "registry+https://github.com/rust-lang/crates.io-index" 381 | checksum = "48c757948c5ede0e46177b7add2e67155f70e33c07fea8284df6576da70b3719" 382 | 383 | [[package]] 384 | name = "equivalent" 385 | version = "1.0.2" 386 | source = "registry+https://github.com/rust-lang/crates.io-index" 387 | checksum = "877a4ace8713b0bcf2a4e7eec82529c029f1d0619886d18145fea96c3ffe5c0f" 388 | 389 | [[package]] 390 | name = "errno" 391 | version = "0.3.12" 392 | source = "registry+https://github.com/rust-lang/crates.io-index" 393 | checksum = "cea14ef9355e3beab063703aa9dab15afd25f0667c341310c1e5274bb1d0da18" 394 | dependencies = [ 395 | "libc", 396 | "windows-sys 0.59.0", 397 | ] 398 | 399 | [[package]] 400 | name = "eyre" 401 | version = "0.6.12" 402 | source = "registry+https://github.com/rust-lang/crates.io-index" 403 | checksum = "7cd915d99f24784cdc19fd37ef22b97e3ff0ae756c7e492e9fbfe897d61e2aec" 404 | dependencies = [ 405 | "indenter", 406 | "once_cell", 407 | ] 408 | 409 | [[package]] 410 | name = "fnv" 411 | version = "1.0.7" 412 | source = "registry+https://github.com/rust-lang/crates.io-index" 413 | checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" 414 | 415 | [[package]] 416 | name = "foldhash" 417 | version = "0.1.5" 418 | source = "registry+https://github.com/rust-lang/crates.io-index" 419 | checksum = "d9c4f5dac5e15c24eb999c26181a6ca40b39fe946cbe4c263c7209467bc83af2" 420 | 421 | [[package]] 422 | name = "form_urlencoded" 423 | version = "1.2.1" 424 | source = "registry+https://github.com/rust-lang/crates.io-index" 425 | checksum = "e13624c2627564efccf4934284bdd98cbaa14e79b0b5a141218e507b3a823456" 426 | dependencies = [ 427 | "percent-encoding", 428 | ] 429 | 430 | [[package]] 431 | name = "futf" 432 | version = "0.1.5" 433 | source = "registry+https://github.com/rust-lang/crates.io-index" 434 | checksum = "df420e2e84819663797d1ec6544b13c5be84629e7bb00dc960d6917db2987843" 435 | dependencies = [ 436 | "mac", 437 | "new_debug_unreachable", 438 | ] 439 | 440 | [[package]] 441 | name = "futures" 442 | version = "0.3.31" 443 | source = "registry+https://github.com/rust-lang/crates.io-index" 444 | checksum = "65bc07b1a8bc7c85c5f2e110c476c7389b4554ba72af57d8445ea63a576b0876" 445 | dependencies = [ 446 | "futures-channel", 447 | "futures-core", 448 | "futures-executor", 449 | "futures-io", 450 | "futures-sink", 451 | "futures-task", 452 | "futures-util", 453 | ] 454 | 455 | [[package]] 456 | name = "futures-channel" 457 | version = "0.3.31" 458 | source = "registry+https://github.com/rust-lang/crates.io-index" 459 | checksum = "2dff15bf788c671c1934e366d07e30c1814a8ef514e1af724a602e8a2fbe1b10" 460 | dependencies = [ 461 | "futures-core", 462 | "futures-sink", 463 | ] 464 | 465 | [[package]] 466 | name = "futures-core" 467 | version = "0.3.31" 468 | source = "registry+https://github.com/rust-lang/crates.io-index" 469 | checksum = "05f29059c0c2090612e8d742178b0580d2dc940c837851ad723096f87af6663e" 470 | 471 | [[package]] 472 | name = "futures-executor" 473 | version = "0.3.31" 474 | source = "registry+https://github.com/rust-lang/crates.io-index" 475 | checksum = "1e28d1d997f585e54aebc3f97d39e72338912123a67330d723fdbb564d646c9f" 476 | dependencies = [ 477 | "futures-core", 478 | "futures-task", 479 | "futures-util", 480 | ] 481 | 482 | [[package]] 483 | name = "futures-io" 484 | version = "0.3.31" 485 | source = "registry+https://github.com/rust-lang/crates.io-index" 486 | checksum = "9e5c1b78ca4aae1ac06c48a526a655760685149f0d465d21f37abfe57ce075c6" 487 | 488 | [[package]] 489 | name = "futures-macro" 490 | version = "0.3.31" 491 | source = "registry+https://github.com/rust-lang/crates.io-index" 492 | checksum = "162ee34ebcb7c64a8abebc059ce0fee27c2262618d7b60ed8faf72fef13c3650" 493 | dependencies = [ 494 | "proc-macro2", 495 | "quote", 496 | "syn", 497 | ] 498 | 499 | [[package]] 500 | name = "futures-sink" 501 | version = "0.3.31" 502 | source = "registry+https://github.com/rust-lang/crates.io-index" 503 | checksum = "e575fab7d1e0dcb8d0c7bcf9a63ee213816ab51902e6d244a95819acacf1d4f7" 504 | 505 | [[package]] 506 | name = "futures-task" 507 | version = "0.3.31" 508 | source = "registry+https://github.com/rust-lang/crates.io-index" 509 | checksum = "f90f7dce0722e95104fcb095585910c0977252f286e354b5e3bd38902cd99988" 510 | 511 | [[package]] 512 | name = "futures-util" 513 | version = "0.3.31" 514 | source = "registry+https://github.com/rust-lang/crates.io-index" 515 | checksum = "9fa08315bb612088cc391249efdc3bc77536f16c91f6cf495e6fbe85b20a4a81" 516 | dependencies = [ 517 | "futures-channel", 518 | "futures-core", 519 | "futures-io", 520 | "futures-macro", 521 | "futures-sink", 522 | "futures-task", 523 | "memchr", 524 | "pin-project-lite", 525 | "pin-utils", 526 | "slab", 527 | ] 528 | 529 | [[package]] 530 | name = "fxhash" 531 | version = "0.2.1" 532 | source = "registry+https://github.com/rust-lang/crates.io-index" 533 | checksum = "c31b6d751ae2c7f11320402d34e41349dd1016f8d5d45e48c4312bc8625af50c" 534 | dependencies = [ 535 | "byteorder", 536 | ] 537 | 538 | [[package]] 539 | name = "getopts" 540 | version = "0.2.21" 541 | source = "registry+https://github.com/rust-lang/crates.io-index" 542 | checksum = "14dbbfd5c71d70241ecf9e6f13737f7b5ce823821063188d7e46c41d371eebd5" 543 | dependencies = [ 544 | "unicode-width 0.1.14", 545 | ] 546 | 547 | [[package]] 548 | name = "getrandom" 549 | version = "0.2.16" 550 | source = "registry+https://github.com/rust-lang/crates.io-index" 551 | checksum = "335ff9f135e4384c8150d6f27c6daed433577f86b4750418338c01a1a2528592" 552 | dependencies = [ 553 | "cfg-if", 554 | "js-sys", 555 | "libc", 556 | "wasi 0.11.0+wasi-snapshot-preview1", 557 | "wasm-bindgen", 558 | ] 559 | 560 | [[package]] 561 | name = "getrandom" 562 | version = "0.3.3" 563 | source = "registry+https://github.com/rust-lang/crates.io-index" 564 | checksum = "26145e563e54f2cadc477553f1ec5ee650b00862f0a58bcd12cbdc5f0ea2d2f4" 565 | dependencies = [ 566 | "cfg-if", 567 | "js-sys", 568 | "libc", 569 | "r-efi", 570 | "wasi 0.14.2+wasi-0.2.4", 571 | "wasm-bindgen", 572 | ] 573 | 574 | [[package]] 575 | name = "gimli" 576 | version = "0.31.1" 577 | source = "registry+https://github.com/rust-lang/crates.io-index" 578 | checksum = "07e28edb80900c19c28f1072f2e8aeca7fa06b23cd4169cefe1af5aa3260783f" 579 | 580 | [[package]] 581 | name = "hashbrown" 582 | version = "0.15.3" 583 | source = "registry+https://github.com/rust-lang/crates.io-index" 584 | checksum = "84b26c544d002229e640969970a2e74021aadf6e2f96372b9c58eff97de08eb3" 585 | dependencies = [ 586 | "allocator-api2", 587 | "equivalent", 588 | "foldhash", 589 | ] 590 | 591 | [[package]] 592 | name = "heck" 593 | version = "0.5.0" 594 | source = "registry+https://github.com/rust-lang/crates.io-index" 595 | checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" 596 | 597 | [[package]] 598 | name = "html5ever" 599 | version = "0.29.1" 600 | source = "registry+https://github.com/rust-lang/crates.io-index" 601 | checksum = "3b7410cae13cbc75623c98ac4cbfd1f0bedddf3227afc24f370cf0f50a44a11c" 602 | dependencies = [ 603 | "log", 604 | "mac", 605 | "markup5ever", 606 | "match_token", 607 | ] 608 | 609 | [[package]] 610 | name = "http" 611 | version = "1.3.1" 612 | source = "registry+https://github.com/rust-lang/crates.io-index" 613 | checksum = "f4a85d31aea989eead29a3aaf9e1115a180df8282431156e533de47660892565" 614 | dependencies = [ 615 | "bytes", 616 | "fnv", 617 | "itoa", 618 | ] 619 | 620 | [[package]] 621 | name = "http-body" 622 | version = "1.0.1" 623 | source = "registry+https://github.com/rust-lang/crates.io-index" 624 | checksum = "1efedce1fb8e6913f23e0c92de8e62cd5b772a67e7b3946df930a62566c93184" 625 | dependencies = [ 626 | "bytes", 627 | "http", 628 | ] 629 | 630 | [[package]] 631 | name = "http-body-util" 632 | version = "0.1.3" 633 | source = "registry+https://github.com/rust-lang/crates.io-index" 634 | checksum = "b021d93e26becf5dc7e1b75b1bed1fd93124b374ceb73f43d4d4eafec896a64a" 635 | dependencies = [ 636 | "bytes", 637 | "futures-core", 638 | "http", 639 | "http-body", 640 | "pin-project-lite", 641 | ] 642 | 643 | [[package]] 644 | name = "httparse" 645 | version = "1.10.1" 646 | source = "registry+https://github.com/rust-lang/crates.io-index" 647 | checksum = "6dbf3de79e51f3d586ab4cb9d5c3e2c14aa28ed23d180cf89b4df0454a69cc87" 648 | 649 | [[package]] 650 | name = "hyper" 651 | version = "1.6.0" 652 | source = "registry+https://github.com/rust-lang/crates.io-index" 653 | checksum = "cc2b571658e38e0c01b1fdca3bbbe93c00d3d71693ff2770043f8c29bc7d6f80" 654 | dependencies = [ 655 | "bytes", 656 | "futures-channel", 657 | "futures-util", 658 | "http", 659 | "http-body", 660 | "httparse", 661 | "itoa", 662 | "pin-project-lite", 663 | "smallvec", 664 | "tokio", 665 | "want", 666 | ] 667 | 668 | [[package]] 669 | name = "hyper-rustls" 670 | version = "0.27.5" 671 | source = "registry+https://github.com/rust-lang/crates.io-index" 672 | checksum = "2d191583f3da1305256f22463b9bb0471acad48a4e534a5218b9963e9c1f59b2" 673 | dependencies = [ 674 | "futures-util", 675 | "http", 676 | "hyper", 677 | "hyper-util", 678 | "rustls", 679 | "rustls-pki-types", 680 | "tokio", 681 | "tokio-rustls", 682 | "tower-service", 683 | "webpki-roots 0.26.11", 684 | ] 685 | 686 | [[package]] 687 | name = "hyper-util" 688 | version = "0.1.11" 689 | source = "registry+https://github.com/rust-lang/crates.io-index" 690 | checksum = "497bbc33a26fdd4af9ed9c70d63f61cf56a938375fbb32df34db9b1cd6d643f2" 691 | dependencies = [ 692 | "bytes", 693 | "futures-channel", 694 | "futures-util", 695 | "http", 696 | "http-body", 697 | "hyper", 698 | "libc", 699 | "pin-project-lite", 700 | "socket2", 701 | "tokio", 702 | "tower-service", 703 | "tracing", 704 | ] 705 | 706 | [[package]] 707 | name = "icu_collections" 708 | version = "2.0.0" 709 | source = "registry+https://github.com/rust-lang/crates.io-index" 710 | checksum = "200072f5d0e3614556f94a9930d5dc3e0662a652823904c3a75dc3b0af7fee47" 711 | dependencies = [ 712 | "displaydoc", 713 | "potential_utf", 714 | "yoke", 715 | "zerofrom", 716 | "zerovec", 717 | ] 718 | 719 | [[package]] 720 | name = "icu_locale_core" 721 | version = "2.0.0" 722 | source = "registry+https://github.com/rust-lang/crates.io-index" 723 | checksum = "0cde2700ccaed3872079a65fb1a78f6c0a36c91570f28755dda67bc8f7d9f00a" 724 | dependencies = [ 725 | "displaydoc", 726 | "litemap", 727 | "tinystr", 728 | "writeable", 729 | "zerovec", 730 | ] 731 | 732 | [[package]] 733 | name = "icu_normalizer" 734 | version = "2.0.0" 735 | source = "registry+https://github.com/rust-lang/crates.io-index" 736 | checksum = "436880e8e18df4d7bbc06d58432329d6458cc84531f7ac5f024e93deadb37979" 737 | dependencies = [ 738 | "displaydoc", 739 | "icu_collections", 740 | "icu_normalizer_data", 741 | "icu_properties", 742 | "icu_provider", 743 | "smallvec", 744 | "zerovec", 745 | ] 746 | 747 | [[package]] 748 | name = "icu_normalizer_data" 749 | version = "2.0.0" 750 | source = "registry+https://github.com/rust-lang/crates.io-index" 751 | checksum = "00210d6893afc98edb752b664b8890f0ef174c8adbb8d0be9710fa66fbbf72d3" 752 | 753 | [[package]] 754 | name = "icu_properties" 755 | version = "2.0.0" 756 | source = "registry+https://github.com/rust-lang/crates.io-index" 757 | checksum = "2549ca8c7241c82f59c80ba2a6f415d931c5b58d24fb8412caa1a1f02c49139a" 758 | dependencies = [ 759 | "displaydoc", 760 | "icu_collections", 761 | "icu_locale_core", 762 | "icu_properties_data", 763 | "icu_provider", 764 | "potential_utf", 765 | "zerotrie", 766 | "zerovec", 767 | ] 768 | 769 | [[package]] 770 | name = "icu_properties_data" 771 | version = "2.0.0" 772 | source = "registry+https://github.com/rust-lang/crates.io-index" 773 | checksum = "8197e866e47b68f8f7d95249e172903bec06004b18b2937f1095d40a0c57de04" 774 | 775 | [[package]] 776 | name = "icu_provider" 777 | version = "2.0.0" 778 | source = "registry+https://github.com/rust-lang/crates.io-index" 779 | checksum = "03c80da27b5f4187909049ee2d72f276f0d9f99a42c306bd0131ecfe04d8e5af" 780 | dependencies = [ 781 | "displaydoc", 782 | "icu_locale_core", 783 | "stable_deref_trait", 784 | "tinystr", 785 | "writeable", 786 | "yoke", 787 | "zerofrom", 788 | "zerotrie", 789 | "zerovec", 790 | ] 791 | 792 | [[package]] 793 | name = "ident_case" 794 | version = "1.0.1" 795 | source = "registry+https://github.com/rust-lang/crates.io-index" 796 | checksum = "b9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39" 797 | 798 | [[package]] 799 | name = "idna" 800 | version = "1.0.3" 801 | source = "registry+https://github.com/rust-lang/crates.io-index" 802 | checksum = "686f825264d630750a544639377bae737628043f20d38bbc029e8f29ea968a7e" 803 | dependencies = [ 804 | "idna_adapter", 805 | "smallvec", 806 | "utf8_iter", 807 | ] 808 | 809 | [[package]] 810 | name = "idna_adapter" 811 | version = "1.2.1" 812 | source = "registry+https://github.com/rust-lang/crates.io-index" 813 | checksum = "3acae9609540aa318d1bc588455225fb2085b9ed0c4f6bd0d9d5bcd86f1a0344" 814 | dependencies = [ 815 | "icu_normalizer", 816 | "icu_properties", 817 | ] 818 | 819 | [[package]] 820 | name = "indenter" 821 | version = "0.3.3" 822 | source = "registry+https://github.com/rust-lang/crates.io-index" 823 | checksum = "ce23b50ad8242c51a442f3ff322d56b02f08852c77e4c0b4d3fd684abc89c683" 824 | 825 | [[package]] 826 | name = "indoc" 827 | version = "2.0.6" 828 | source = "registry+https://github.com/rust-lang/crates.io-index" 829 | checksum = "f4c7245a08504955605670dbf141fceab975f15ca21570696aebe9d2e71576bd" 830 | 831 | [[package]] 832 | name = "instability" 833 | version = "0.3.7" 834 | source = "registry+https://github.com/rust-lang/crates.io-index" 835 | checksum = "0bf9fed6d91cfb734e7476a06bde8300a1b94e217e1b523b6f0cd1a01998c71d" 836 | dependencies = [ 837 | "darling", 838 | "indoc", 839 | "proc-macro2", 840 | "quote", 841 | "syn", 842 | ] 843 | 844 | [[package]] 845 | name = "ipnet" 846 | version = "2.11.0" 847 | source = "registry+https://github.com/rust-lang/crates.io-index" 848 | checksum = "469fb0b9cefa57e3ef31275ee7cacb78f2fdca44e4765491884a2b119d4eb130" 849 | 850 | [[package]] 851 | name = "is-docker" 852 | version = "0.2.0" 853 | source = "registry+https://github.com/rust-lang/crates.io-index" 854 | checksum = "928bae27f42bc99b60d9ac7334e3a21d10ad8f1835a4e12ec3ec0464765ed1b3" 855 | dependencies = [ 856 | "once_cell", 857 | ] 858 | 859 | [[package]] 860 | name = "is-wsl" 861 | version = "0.4.0" 862 | source = "registry+https://github.com/rust-lang/crates.io-index" 863 | checksum = "173609498df190136aa7dea1a91db051746d339e18476eed5ca40521f02d7aa5" 864 | dependencies = [ 865 | "is-docker", 866 | "once_cell", 867 | ] 868 | 869 | [[package]] 870 | name = "is_terminal_polyfill" 871 | version = "1.70.1" 872 | source = "registry+https://github.com/rust-lang/crates.io-index" 873 | checksum = "7943c866cc5cd64cbc25b2e01621d07fa8eb2a1a23160ee81ce38704e97b8ecf" 874 | 875 | [[package]] 876 | name = "itertools" 877 | version = "0.13.0" 878 | source = "registry+https://github.com/rust-lang/crates.io-index" 879 | checksum = "413ee7dfc52ee1a4949ceeb7dbc8a33f2d6c088194d9f922fb8318faf1f01186" 880 | dependencies = [ 881 | "either", 882 | ] 883 | 884 | [[package]] 885 | name = "itoa" 886 | version = "1.0.15" 887 | source = "registry+https://github.com/rust-lang/crates.io-index" 888 | checksum = "4a5f13b858c8d314ee3e8f639011f7ccefe71f97f96e50151fb991f267928e2c" 889 | 890 | [[package]] 891 | name = "js-sys" 892 | version = "0.3.77" 893 | source = "registry+https://github.com/rust-lang/crates.io-index" 894 | checksum = "1cfaf33c695fc6e08064efbc1f72ec937429614f25eef83af942d0e227c3a28f" 895 | dependencies = [ 896 | "once_cell", 897 | "wasm-bindgen", 898 | ] 899 | 900 | [[package]] 901 | name = "lazy_static" 902 | version = "1.5.0" 903 | source = "registry+https://github.com/rust-lang/crates.io-index" 904 | checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" 905 | 906 | [[package]] 907 | name = "libc" 908 | version = "0.2.172" 909 | source = "registry+https://github.com/rust-lang/crates.io-index" 910 | checksum = "d750af042f7ef4f724306de029d18836c26c1765a54a6a3f094cbd23a7267ffa" 911 | 912 | [[package]] 913 | name = "linux-raw-sys" 914 | version = "0.4.15" 915 | source = "registry+https://github.com/rust-lang/crates.io-index" 916 | checksum = "d26c52dbd32dccf2d10cac7725f8eae5296885fb5703b261f7d0a0739ec807ab" 917 | 918 | [[package]] 919 | name = "litemap" 920 | version = "0.8.0" 921 | source = "registry+https://github.com/rust-lang/crates.io-index" 922 | checksum = "241eaef5fd12c88705a01fc1066c48c4b36e0dd4377dcdc7ec3942cea7a69956" 923 | 924 | [[package]] 925 | name = "lobtui" 926 | version = "0.3.1" 927 | dependencies = [ 928 | "clap", 929 | "color-eyre", 930 | "crossterm", 931 | "futures", 932 | "open", 933 | "ratatui", 934 | "reqwest", 935 | "scraper", 936 | "tokio", 937 | ] 938 | 939 | [[package]] 940 | name = "lock_api" 941 | version = "0.4.12" 942 | source = "registry+https://github.com/rust-lang/crates.io-index" 943 | checksum = "07af8b9cdd281b7915f413fa73f29ebd5d55d0d3f0155584dade1ff18cea1b17" 944 | dependencies = [ 945 | "autocfg", 946 | "scopeguard", 947 | ] 948 | 949 | [[package]] 950 | name = "log" 951 | version = "0.4.27" 952 | source = "registry+https://github.com/rust-lang/crates.io-index" 953 | checksum = "13dc2df351e3202783a1fe0d44375f7295ffb4049267b0f3018346dc122a1d94" 954 | 955 | [[package]] 956 | name = "lru" 957 | version = "0.12.5" 958 | source = "registry+https://github.com/rust-lang/crates.io-index" 959 | checksum = "234cf4f4a04dc1f57e24b96cc0cd600cf2af460d4161ac5ecdd0af8e1f3b2a38" 960 | dependencies = [ 961 | "hashbrown", 962 | ] 963 | 964 | [[package]] 965 | name = "lru-slab" 966 | version = "0.1.2" 967 | source = "registry+https://github.com/rust-lang/crates.io-index" 968 | checksum = "112b39cec0b298b6c1999fee3e31427f74f676e4cb9879ed1a121b43661a4154" 969 | 970 | [[package]] 971 | name = "mac" 972 | version = "0.1.1" 973 | source = "registry+https://github.com/rust-lang/crates.io-index" 974 | checksum = "c41e0c4fef86961ac6d6f8a82609f55f31b05e4fce149ac5710e439df7619ba4" 975 | 976 | [[package]] 977 | name = "markup5ever" 978 | version = "0.14.1" 979 | source = "registry+https://github.com/rust-lang/crates.io-index" 980 | checksum = "c7a7213d12e1864c0f002f52c2923d4556935a43dec5e71355c2760e0f6e7a18" 981 | dependencies = [ 982 | "log", 983 | "phf", 984 | "phf_codegen", 985 | "string_cache", 986 | "string_cache_codegen", 987 | "tendril", 988 | ] 989 | 990 | [[package]] 991 | name = "match_token" 992 | version = "0.1.0" 993 | source = "registry+https://github.com/rust-lang/crates.io-index" 994 | checksum = "88a9689d8d44bf9964484516275f5cd4c9b59457a6940c1d5d0ecbb94510a36b" 995 | dependencies = [ 996 | "proc-macro2", 997 | "quote", 998 | "syn", 999 | ] 1000 | 1001 | [[package]] 1002 | name = "memchr" 1003 | version = "2.7.4" 1004 | source = "registry+https://github.com/rust-lang/crates.io-index" 1005 | checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" 1006 | 1007 | [[package]] 1008 | name = "mime" 1009 | version = "0.3.17" 1010 | source = "registry+https://github.com/rust-lang/crates.io-index" 1011 | checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" 1012 | 1013 | [[package]] 1014 | name = "miniz_oxide" 1015 | version = "0.8.8" 1016 | source = "registry+https://github.com/rust-lang/crates.io-index" 1017 | checksum = "3be647b768db090acb35d5ec5db2b0e1f1de11133ca123b9eacf5137868f892a" 1018 | dependencies = [ 1019 | "adler2", 1020 | ] 1021 | 1022 | [[package]] 1023 | name = "mio" 1024 | version = "1.0.3" 1025 | source = "registry+https://github.com/rust-lang/crates.io-index" 1026 | checksum = "2886843bf800fba2e3377cff24abf6379b4c4d5c6681eaf9ea5b0d15090450bd" 1027 | dependencies = [ 1028 | "libc", 1029 | "log", 1030 | "wasi 0.11.0+wasi-snapshot-preview1", 1031 | "windows-sys 0.52.0", 1032 | ] 1033 | 1034 | [[package]] 1035 | name = "new_debug_unreachable" 1036 | version = "1.0.6" 1037 | source = "registry+https://github.com/rust-lang/crates.io-index" 1038 | checksum = "650eef8c711430f1a879fdd01d4745a7deea475becfb90269c06775983bbf086" 1039 | 1040 | [[package]] 1041 | name = "object" 1042 | version = "0.36.7" 1043 | source = "registry+https://github.com/rust-lang/crates.io-index" 1044 | checksum = "62948e14d923ea95ea2c7c86c71013138b66525b86bdc08d2dcc262bdb497b87" 1045 | dependencies = [ 1046 | "memchr", 1047 | ] 1048 | 1049 | [[package]] 1050 | name = "once_cell" 1051 | version = "1.21.3" 1052 | source = "registry+https://github.com/rust-lang/crates.io-index" 1053 | checksum = "42f5e15c9953c5e4ccceeb2e7382a716482c34515315f7b03532b8b4e8393d2d" 1054 | 1055 | [[package]] 1056 | name = "open" 1057 | version = "5.3.2" 1058 | source = "registry+https://github.com/rust-lang/crates.io-index" 1059 | checksum = "e2483562e62ea94312f3576a7aca397306df7990b8d89033e18766744377ef95" 1060 | dependencies = [ 1061 | "is-wsl", 1062 | "libc", 1063 | "pathdiff", 1064 | ] 1065 | 1066 | [[package]] 1067 | name = "owo-colors" 1068 | version = "4.2.1" 1069 | source = "registry+https://github.com/rust-lang/crates.io-index" 1070 | checksum = "26995317201fa17f3656c36716aed4a7c81743a9634ac4c99c0eeda495db0cec" 1071 | 1072 | [[package]] 1073 | name = "parking_lot" 1074 | version = "0.12.3" 1075 | source = "registry+https://github.com/rust-lang/crates.io-index" 1076 | checksum = "f1bf18183cf54e8d6059647fc3063646a1801cf30896933ec2311622cc4b9a27" 1077 | dependencies = [ 1078 | "lock_api", 1079 | "parking_lot_core", 1080 | ] 1081 | 1082 | [[package]] 1083 | name = "parking_lot_core" 1084 | version = "0.9.10" 1085 | source = "registry+https://github.com/rust-lang/crates.io-index" 1086 | checksum = "1e401f977ab385c9e4e3ab30627d6f26d00e2c73eef317493c4ec6d468726cf8" 1087 | dependencies = [ 1088 | "cfg-if", 1089 | "libc", 1090 | "redox_syscall", 1091 | "smallvec", 1092 | "windows-targets 0.52.6", 1093 | ] 1094 | 1095 | [[package]] 1096 | name = "paste" 1097 | version = "1.0.15" 1098 | source = "registry+https://github.com/rust-lang/crates.io-index" 1099 | checksum = "57c0d7b74b563b49d38dae00a0c37d4d6de9b432382b2892f0574ddcae73fd0a" 1100 | 1101 | [[package]] 1102 | name = "pathdiff" 1103 | version = "0.2.3" 1104 | source = "registry+https://github.com/rust-lang/crates.io-index" 1105 | checksum = "df94ce210e5bc13cb6651479fa48d14f601d9858cfe0467f43ae157023b938d3" 1106 | 1107 | [[package]] 1108 | name = "percent-encoding" 1109 | version = "2.3.1" 1110 | source = "registry+https://github.com/rust-lang/crates.io-index" 1111 | checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" 1112 | 1113 | [[package]] 1114 | name = "phf" 1115 | version = "0.11.3" 1116 | source = "registry+https://github.com/rust-lang/crates.io-index" 1117 | checksum = "1fd6780a80ae0c52cc120a26a1a42c1ae51b247a253e4e06113d23d2c2edd078" 1118 | dependencies = [ 1119 | "phf_macros", 1120 | "phf_shared", 1121 | ] 1122 | 1123 | [[package]] 1124 | name = "phf_codegen" 1125 | version = "0.11.3" 1126 | source = "registry+https://github.com/rust-lang/crates.io-index" 1127 | checksum = "aef8048c789fa5e851558d709946d6d79a8ff88c0440c587967f8e94bfb1216a" 1128 | dependencies = [ 1129 | "phf_generator", 1130 | "phf_shared", 1131 | ] 1132 | 1133 | [[package]] 1134 | name = "phf_generator" 1135 | version = "0.11.3" 1136 | source = "registry+https://github.com/rust-lang/crates.io-index" 1137 | checksum = "3c80231409c20246a13fddb31776fb942c38553c51e871f8cbd687a4cfb5843d" 1138 | dependencies = [ 1139 | "phf_shared", 1140 | "rand 0.8.5", 1141 | ] 1142 | 1143 | [[package]] 1144 | name = "phf_macros" 1145 | version = "0.11.3" 1146 | source = "registry+https://github.com/rust-lang/crates.io-index" 1147 | checksum = "f84ac04429c13a7ff43785d75ad27569f2951ce0ffd30a3321230db2fc727216" 1148 | dependencies = [ 1149 | "phf_generator", 1150 | "phf_shared", 1151 | "proc-macro2", 1152 | "quote", 1153 | "syn", 1154 | ] 1155 | 1156 | [[package]] 1157 | name = "phf_shared" 1158 | version = "0.11.3" 1159 | source = "registry+https://github.com/rust-lang/crates.io-index" 1160 | checksum = "67eabc2ef2a60eb7faa00097bd1ffdb5bd28e62bf39990626a582201b7a754e5" 1161 | dependencies = [ 1162 | "siphasher", 1163 | ] 1164 | 1165 | [[package]] 1166 | name = "pin-project-lite" 1167 | version = "0.2.16" 1168 | source = "registry+https://github.com/rust-lang/crates.io-index" 1169 | checksum = "3b3cff922bd51709b605d9ead9aa71031d81447142d828eb4a6eba76fe619f9b" 1170 | 1171 | [[package]] 1172 | name = "pin-utils" 1173 | version = "0.1.0" 1174 | source = "registry+https://github.com/rust-lang/crates.io-index" 1175 | checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" 1176 | 1177 | [[package]] 1178 | name = "potential_utf" 1179 | version = "0.1.2" 1180 | source = "registry+https://github.com/rust-lang/crates.io-index" 1181 | checksum = "e5a7c30837279ca13e7c867e9e40053bc68740f988cb07f7ca6df43cc734b585" 1182 | dependencies = [ 1183 | "zerovec", 1184 | ] 1185 | 1186 | [[package]] 1187 | name = "ppv-lite86" 1188 | version = "0.2.21" 1189 | source = "registry+https://github.com/rust-lang/crates.io-index" 1190 | checksum = "85eae3c4ed2f50dcfe72643da4befc30deadb458a9b590d720cde2f2b1e97da9" 1191 | dependencies = [ 1192 | "zerocopy", 1193 | ] 1194 | 1195 | [[package]] 1196 | name = "precomputed-hash" 1197 | version = "0.1.1" 1198 | source = "registry+https://github.com/rust-lang/crates.io-index" 1199 | checksum = "925383efa346730478fb4838dbe9137d2a47675ad789c546d150a6e1dd4ab31c" 1200 | 1201 | [[package]] 1202 | name = "proc-macro2" 1203 | version = "1.0.95" 1204 | source = "registry+https://github.com/rust-lang/crates.io-index" 1205 | checksum = "02b3e5e68a3a1a02aad3ec490a98007cbc13c37cbe84a3cd7b8e406d76e7f778" 1206 | dependencies = [ 1207 | "unicode-ident", 1208 | ] 1209 | 1210 | [[package]] 1211 | name = "quinn" 1212 | version = "0.11.8" 1213 | source = "registry+https://github.com/rust-lang/crates.io-index" 1214 | checksum = "626214629cda6781b6dc1d316ba307189c85ba657213ce642d9c77670f8202c8" 1215 | dependencies = [ 1216 | "bytes", 1217 | "cfg_aliases", 1218 | "pin-project-lite", 1219 | "quinn-proto", 1220 | "quinn-udp", 1221 | "rustc-hash", 1222 | "rustls", 1223 | "socket2", 1224 | "thiserror", 1225 | "tokio", 1226 | "tracing", 1227 | "web-time", 1228 | ] 1229 | 1230 | [[package]] 1231 | name = "quinn-proto" 1232 | version = "0.11.12" 1233 | source = "registry+https://github.com/rust-lang/crates.io-index" 1234 | checksum = "49df843a9161c85bb8aae55f101bc0bac8bcafd637a620d9122fd7e0b2f7422e" 1235 | dependencies = [ 1236 | "bytes", 1237 | "getrandom 0.3.3", 1238 | "lru-slab", 1239 | "rand 0.9.1", 1240 | "ring", 1241 | "rustc-hash", 1242 | "rustls", 1243 | "rustls-pki-types", 1244 | "slab", 1245 | "thiserror", 1246 | "tinyvec", 1247 | "tracing", 1248 | "web-time", 1249 | ] 1250 | 1251 | [[package]] 1252 | name = "quinn-udp" 1253 | version = "0.5.12" 1254 | source = "registry+https://github.com/rust-lang/crates.io-index" 1255 | checksum = "ee4e529991f949c5e25755532370b8af5d114acae52326361d68d47af64aa842" 1256 | dependencies = [ 1257 | "cfg_aliases", 1258 | "libc", 1259 | "once_cell", 1260 | "socket2", 1261 | "tracing", 1262 | "windows-sys 0.59.0", 1263 | ] 1264 | 1265 | [[package]] 1266 | name = "quote" 1267 | version = "1.0.40" 1268 | source = "registry+https://github.com/rust-lang/crates.io-index" 1269 | checksum = "1885c039570dc00dcb4ff087a89e185fd56bae234ddc7f056a945bf36467248d" 1270 | dependencies = [ 1271 | "proc-macro2", 1272 | ] 1273 | 1274 | [[package]] 1275 | name = "r-efi" 1276 | version = "5.2.0" 1277 | source = "registry+https://github.com/rust-lang/crates.io-index" 1278 | checksum = "74765f6d916ee2faa39bc8e68e4f3ed8949b48cccdac59983d287a7cb71ce9c5" 1279 | 1280 | [[package]] 1281 | name = "rand" 1282 | version = "0.8.5" 1283 | source = "registry+https://github.com/rust-lang/crates.io-index" 1284 | checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" 1285 | dependencies = [ 1286 | "rand_core 0.6.4", 1287 | ] 1288 | 1289 | [[package]] 1290 | name = "rand" 1291 | version = "0.9.1" 1292 | source = "registry+https://github.com/rust-lang/crates.io-index" 1293 | checksum = "9fbfd9d094a40bf3ae768db9361049ace4c0e04a4fd6b359518bd7b73a73dd97" 1294 | dependencies = [ 1295 | "rand_chacha", 1296 | "rand_core 0.9.3", 1297 | ] 1298 | 1299 | [[package]] 1300 | name = "rand_chacha" 1301 | version = "0.9.0" 1302 | source = "registry+https://github.com/rust-lang/crates.io-index" 1303 | checksum = "d3022b5f1df60f26e1ffddd6c66e8aa15de382ae63b3a0c1bfc0e4d3e3f325cb" 1304 | dependencies = [ 1305 | "ppv-lite86", 1306 | "rand_core 0.9.3", 1307 | ] 1308 | 1309 | [[package]] 1310 | name = "rand_core" 1311 | version = "0.6.4" 1312 | source = "registry+https://github.com/rust-lang/crates.io-index" 1313 | checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" 1314 | 1315 | [[package]] 1316 | name = "rand_core" 1317 | version = "0.9.3" 1318 | source = "registry+https://github.com/rust-lang/crates.io-index" 1319 | checksum = "99d9a13982dcf210057a8a78572b2217b667c3beacbf3a0d8b454f6f82837d38" 1320 | dependencies = [ 1321 | "getrandom 0.3.3", 1322 | ] 1323 | 1324 | [[package]] 1325 | name = "ratatui" 1326 | version = "0.29.0" 1327 | source = "registry+https://github.com/rust-lang/crates.io-index" 1328 | checksum = "eabd94c2f37801c20583fc49dd5cd6b0ba68c716787c2dd6ed18571e1e63117b" 1329 | dependencies = [ 1330 | "bitflags", 1331 | "cassowary", 1332 | "compact_str", 1333 | "crossterm", 1334 | "indoc", 1335 | "instability", 1336 | "itertools", 1337 | "lru", 1338 | "paste", 1339 | "strum", 1340 | "unicode-segmentation", 1341 | "unicode-truncate", 1342 | "unicode-width 0.2.0", 1343 | ] 1344 | 1345 | [[package]] 1346 | name = "redox_syscall" 1347 | version = "0.5.12" 1348 | source = "registry+https://github.com/rust-lang/crates.io-index" 1349 | checksum = "928fca9cf2aa042393a8325b9ead81d2f0df4cb12e1e24cef072922ccd99c5af" 1350 | dependencies = [ 1351 | "bitflags", 1352 | ] 1353 | 1354 | [[package]] 1355 | name = "reqwest" 1356 | version = "0.12.15" 1357 | source = "registry+https://github.com/rust-lang/crates.io-index" 1358 | checksum = "d19c46a6fdd48bc4dab94b6103fccc55d34c67cc0ad04653aad4ea2a07cd7bbb" 1359 | dependencies = [ 1360 | "base64", 1361 | "bytes", 1362 | "futures-core", 1363 | "futures-util", 1364 | "http", 1365 | "http-body", 1366 | "http-body-util", 1367 | "hyper", 1368 | "hyper-rustls", 1369 | "hyper-util", 1370 | "ipnet", 1371 | "js-sys", 1372 | "log", 1373 | "mime", 1374 | "once_cell", 1375 | "percent-encoding", 1376 | "pin-project-lite", 1377 | "quinn", 1378 | "rustls", 1379 | "rustls-pemfile", 1380 | "rustls-pki-types", 1381 | "serde", 1382 | "serde_json", 1383 | "serde_urlencoded", 1384 | "sync_wrapper", 1385 | "tokio", 1386 | "tokio-rustls", 1387 | "tower", 1388 | "tower-service", 1389 | "url", 1390 | "wasm-bindgen", 1391 | "wasm-bindgen-futures", 1392 | "web-sys", 1393 | "webpki-roots 0.26.11", 1394 | "windows-registry", 1395 | ] 1396 | 1397 | [[package]] 1398 | name = "ring" 1399 | version = "0.17.14" 1400 | source = "registry+https://github.com/rust-lang/crates.io-index" 1401 | checksum = "a4689e6c2294d81e88dc6261c768b63bc4fcdb852be6d1352498b114f61383b7" 1402 | dependencies = [ 1403 | "cc", 1404 | "cfg-if", 1405 | "getrandom 0.2.16", 1406 | "libc", 1407 | "untrusted", 1408 | "windows-sys 0.52.0", 1409 | ] 1410 | 1411 | [[package]] 1412 | name = "rustc-demangle" 1413 | version = "0.1.24" 1414 | source = "registry+https://github.com/rust-lang/crates.io-index" 1415 | checksum = "719b953e2095829ee67db738b3bfa9fa368c94900df327b3f07fe6e794d2fe1f" 1416 | 1417 | [[package]] 1418 | name = "rustc-hash" 1419 | version = "2.1.1" 1420 | source = "registry+https://github.com/rust-lang/crates.io-index" 1421 | checksum = "357703d41365b4b27c590e3ed91eabb1b663f07c4c084095e60cbed4362dff0d" 1422 | 1423 | [[package]] 1424 | name = "rustix" 1425 | version = "0.38.44" 1426 | source = "registry+https://github.com/rust-lang/crates.io-index" 1427 | checksum = "fdb5bc1ae2baa591800df16c9ca78619bf65c0488b41b96ccec5d11220d8c154" 1428 | dependencies = [ 1429 | "bitflags", 1430 | "errno", 1431 | "libc", 1432 | "linux-raw-sys", 1433 | "windows-sys 0.59.0", 1434 | ] 1435 | 1436 | [[package]] 1437 | name = "rustls" 1438 | version = "0.23.27" 1439 | source = "registry+https://github.com/rust-lang/crates.io-index" 1440 | checksum = "730944ca083c1c233a75c09f199e973ca499344a2b7ba9e755c457e86fb4a321" 1441 | dependencies = [ 1442 | "once_cell", 1443 | "ring", 1444 | "rustls-pki-types", 1445 | "rustls-webpki", 1446 | "subtle", 1447 | "zeroize", 1448 | ] 1449 | 1450 | [[package]] 1451 | name = "rustls-pemfile" 1452 | version = "2.2.0" 1453 | source = "registry+https://github.com/rust-lang/crates.io-index" 1454 | checksum = "dce314e5fee3f39953d46bb63bb8a46d40c2f8fb7cc5a3b6cab2bde9721d6e50" 1455 | dependencies = [ 1456 | "rustls-pki-types", 1457 | ] 1458 | 1459 | [[package]] 1460 | name = "rustls-pki-types" 1461 | version = "1.12.0" 1462 | source = "registry+https://github.com/rust-lang/crates.io-index" 1463 | checksum = "229a4a4c221013e7e1f1a043678c5cc39fe5171437c88fb47151a21e6f5b5c79" 1464 | dependencies = [ 1465 | "web-time", 1466 | "zeroize", 1467 | ] 1468 | 1469 | [[package]] 1470 | name = "rustls-webpki" 1471 | version = "0.103.3" 1472 | source = "registry+https://github.com/rust-lang/crates.io-index" 1473 | checksum = "e4a72fe2bcf7a6ac6fd7d0b9e5cb68aeb7d4c0a0271730218b3e92d43b4eb435" 1474 | dependencies = [ 1475 | "ring", 1476 | "rustls-pki-types", 1477 | "untrusted", 1478 | ] 1479 | 1480 | [[package]] 1481 | name = "rustversion" 1482 | version = "1.0.20" 1483 | source = "registry+https://github.com/rust-lang/crates.io-index" 1484 | checksum = "eded382c5f5f786b989652c49544c4877d9f015cc22e145a5ea8ea66c2921cd2" 1485 | 1486 | [[package]] 1487 | name = "ryu" 1488 | version = "1.0.20" 1489 | source = "registry+https://github.com/rust-lang/crates.io-index" 1490 | checksum = "28d3b2b1366ec20994f1fd18c3c594f05c5dd4bc44d8bb0c1c632c8d6829481f" 1491 | 1492 | [[package]] 1493 | name = "scopeguard" 1494 | version = "1.2.0" 1495 | source = "registry+https://github.com/rust-lang/crates.io-index" 1496 | checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" 1497 | 1498 | [[package]] 1499 | name = "scraper" 1500 | version = "0.23.1" 1501 | source = "registry+https://github.com/rust-lang/crates.io-index" 1502 | checksum = "527e65d9d888567588db4c12da1087598d0f6f8b346cc2c5abc91f05fc2dffe2" 1503 | dependencies = [ 1504 | "cssparser", 1505 | "ego-tree", 1506 | "getopts", 1507 | "html5ever", 1508 | "precomputed-hash", 1509 | "selectors", 1510 | "tendril", 1511 | ] 1512 | 1513 | [[package]] 1514 | name = "selectors" 1515 | version = "0.26.0" 1516 | source = "registry+https://github.com/rust-lang/crates.io-index" 1517 | checksum = "fd568a4c9bb598e291a08244a5c1f5a8a6650bee243b5b0f8dbb3d9cc1d87fe8" 1518 | dependencies = [ 1519 | "bitflags", 1520 | "cssparser", 1521 | "derive_more", 1522 | "fxhash", 1523 | "log", 1524 | "new_debug_unreachable", 1525 | "phf", 1526 | "phf_codegen", 1527 | "precomputed-hash", 1528 | "servo_arc", 1529 | "smallvec", 1530 | ] 1531 | 1532 | [[package]] 1533 | name = "serde" 1534 | version = "1.0.219" 1535 | source = "registry+https://github.com/rust-lang/crates.io-index" 1536 | checksum = "5f0e2c6ed6606019b4e29e69dbaba95b11854410e5347d525002456dbbb786b6" 1537 | dependencies = [ 1538 | "serde_derive", 1539 | ] 1540 | 1541 | [[package]] 1542 | name = "serde_derive" 1543 | version = "1.0.219" 1544 | source = "registry+https://github.com/rust-lang/crates.io-index" 1545 | checksum = "5b0276cf7f2c73365f7157c8123c21cd9a50fbbd844757af28ca1f5925fc2a00" 1546 | dependencies = [ 1547 | "proc-macro2", 1548 | "quote", 1549 | "syn", 1550 | ] 1551 | 1552 | [[package]] 1553 | name = "serde_json" 1554 | version = "1.0.140" 1555 | source = "registry+https://github.com/rust-lang/crates.io-index" 1556 | checksum = "20068b6e96dc6c9bd23e01df8827e6c7e1f2fddd43c21810382803c136b99373" 1557 | dependencies = [ 1558 | "itoa", 1559 | "memchr", 1560 | "ryu", 1561 | "serde", 1562 | ] 1563 | 1564 | [[package]] 1565 | name = "serde_urlencoded" 1566 | version = "0.7.1" 1567 | source = "registry+https://github.com/rust-lang/crates.io-index" 1568 | checksum = "d3491c14715ca2294c4d6a88f15e84739788c1d030eed8c110436aafdaa2f3fd" 1569 | dependencies = [ 1570 | "form_urlencoded", 1571 | "itoa", 1572 | "ryu", 1573 | "serde", 1574 | ] 1575 | 1576 | [[package]] 1577 | name = "servo_arc" 1578 | version = "0.4.0" 1579 | source = "registry+https://github.com/rust-lang/crates.io-index" 1580 | checksum = "ae65c4249478a2647db249fb43e23cec56a2c8974a427e7bd8cb5a1d0964921a" 1581 | dependencies = [ 1582 | "stable_deref_trait", 1583 | ] 1584 | 1585 | [[package]] 1586 | name = "sharded-slab" 1587 | version = "0.1.7" 1588 | source = "registry+https://github.com/rust-lang/crates.io-index" 1589 | checksum = "f40ca3c46823713e0d4209592e8d6e826aa57e928f09752619fc696c499637f6" 1590 | dependencies = [ 1591 | "lazy_static", 1592 | ] 1593 | 1594 | [[package]] 1595 | name = "shlex" 1596 | version = "1.3.0" 1597 | source = "registry+https://github.com/rust-lang/crates.io-index" 1598 | checksum = "0fda2ff0d084019ba4d7c6f371c95d8fd75ce3524c3cb8fb653a3023f6323e64" 1599 | 1600 | [[package]] 1601 | name = "signal-hook" 1602 | version = "0.3.18" 1603 | source = "registry+https://github.com/rust-lang/crates.io-index" 1604 | checksum = "d881a16cf4426aa584979d30bd82cb33429027e42122b169753d6ef1085ed6e2" 1605 | dependencies = [ 1606 | "libc", 1607 | "signal-hook-registry", 1608 | ] 1609 | 1610 | [[package]] 1611 | name = "signal-hook-mio" 1612 | version = "0.2.4" 1613 | source = "registry+https://github.com/rust-lang/crates.io-index" 1614 | checksum = "34db1a06d485c9142248b7a054f034b349b212551f3dfd19c94d45a754a217cd" 1615 | dependencies = [ 1616 | "libc", 1617 | "mio", 1618 | "signal-hook", 1619 | ] 1620 | 1621 | [[package]] 1622 | name = "signal-hook-registry" 1623 | version = "1.4.5" 1624 | source = "registry+https://github.com/rust-lang/crates.io-index" 1625 | checksum = "9203b8055f63a2a00e2f593bb0510367fe707d7ff1e5c872de2f537b339e5410" 1626 | dependencies = [ 1627 | "libc", 1628 | ] 1629 | 1630 | [[package]] 1631 | name = "siphasher" 1632 | version = "1.0.1" 1633 | source = "registry+https://github.com/rust-lang/crates.io-index" 1634 | checksum = "56199f7ddabf13fe5074ce809e7d3f42b42ae711800501b5b16ea82ad029c39d" 1635 | 1636 | [[package]] 1637 | name = "slab" 1638 | version = "0.4.9" 1639 | source = "registry+https://github.com/rust-lang/crates.io-index" 1640 | checksum = "8f92a496fb766b417c996b9c5e57daf2f7ad3b0bebe1ccfca4856390e3d3bb67" 1641 | dependencies = [ 1642 | "autocfg", 1643 | ] 1644 | 1645 | [[package]] 1646 | name = "smallvec" 1647 | version = "1.15.0" 1648 | source = "registry+https://github.com/rust-lang/crates.io-index" 1649 | checksum = "8917285742e9f3e1683f0a9c4e6b57960b7314d0b08d30d1ecd426713ee2eee9" 1650 | 1651 | [[package]] 1652 | name = "socket2" 1653 | version = "0.5.9" 1654 | source = "registry+https://github.com/rust-lang/crates.io-index" 1655 | checksum = "4f5fd57c80058a56cf5c777ab8a126398ece8e442983605d280a44ce79d0edef" 1656 | dependencies = [ 1657 | "libc", 1658 | "windows-sys 0.52.0", 1659 | ] 1660 | 1661 | [[package]] 1662 | name = "stable_deref_trait" 1663 | version = "1.2.0" 1664 | source = "registry+https://github.com/rust-lang/crates.io-index" 1665 | checksum = "a8f112729512f8e442d81f95a8a7ddf2b7c6b8a1a6f509a95864142b30cab2d3" 1666 | 1667 | [[package]] 1668 | name = "static_assertions" 1669 | version = "1.1.0" 1670 | source = "registry+https://github.com/rust-lang/crates.io-index" 1671 | checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f" 1672 | 1673 | [[package]] 1674 | name = "string_cache" 1675 | version = "0.8.9" 1676 | source = "registry+https://github.com/rust-lang/crates.io-index" 1677 | checksum = "bf776ba3fa74f83bf4b63c3dcbbf82173db2632ed8452cb2d891d33f459de70f" 1678 | dependencies = [ 1679 | "new_debug_unreachable", 1680 | "parking_lot", 1681 | "phf_shared", 1682 | "precomputed-hash", 1683 | "serde", 1684 | ] 1685 | 1686 | [[package]] 1687 | name = "string_cache_codegen" 1688 | version = "0.5.4" 1689 | source = "registry+https://github.com/rust-lang/crates.io-index" 1690 | checksum = "c711928715f1fe0fe509c53b43e993a9a557babc2d0a3567d0a3006f1ac931a0" 1691 | dependencies = [ 1692 | "phf_generator", 1693 | "phf_shared", 1694 | "proc-macro2", 1695 | "quote", 1696 | ] 1697 | 1698 | [[package]] 1699 | name = "strsim" 1700 | version = "0.11.1" 1701 | source = "registry+https://github.com/rust-lang/crates.io-index" 1702 | checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" 1703 | 1704 | [[package]] 1705 | name = "strum" 1706 | version = "0.26.3" 1707 | source = "registry+https://github.com/rust-lang/crates.io-index" 1708 | checksum = "8fec0f0aef304996cf250b31b5a10dee7980c85da9d759361292b8bca5a18f06" 1709 | dependencies = [ 1710 | "strum_macros", 1711 | ] 1712 | 1713 | [[package]] 1714 | name = "strum_macros" 1715 | version = "0.26.4" 1716 | source = "registry+https://github.com/rust-lang/crates.io-index" 1717 | checksum = "4c6bee85a5a24955dc440386795aa378cd9cf82acd5f764469152d2270e581be" 1718 | dependencies = [ 1719 | "heck", 1720 | "proc-macro2", 1721 | "quote", 1722 | "rustversion", 1723 | "syn", 1724 | ] 1725 | 1726 | [[package]] 1727 | name = "subtle" 1728 | version = "2.6.1" 1729 | source = "registry+https://github.com/rust-lang/crates.io-index" 1730 | checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292" 1731 | 1732 | [[package]] 1733 | name = "syn" 1734 | version = "2.0.101" 1735 | source = "registry+https://github.com/rust-lang/crates.io-index" 1736 | checksum = "8ce2b7fc941b3a24138a0a7cf8e858bfc6a992e7978a068a5c760deb0ed43caf" 1737 | dependencies = [ 1738 | "proc-macro2", 1739 | "quote", 1740 | "unicode-ident", 1741 | ] 1742 | 1743 | [[package]] 1744 | name = "sync_wrapper" 1745 | version = "1.0.2" 1746 | source = "registry+https://github.com/rust-lang/crates.io-index" 1747 | checksum = "0bf256ce5efdfa370213c1dabab5935a12e49f2c58d15e9eac2870d3b4f27263" 1748 | dependencies = [ 1749 | "futures-core", 1750 | ] 1751 | 1752 | [[package]] 1753 | name = "synstructure" 1754 | version = "0.13.2" 1755 | source = "registry+https://github.com/rust-lang/crates.io-index" 1756 | checksum = "728a70f3dbaf5bab7f0c4b1ac8d7ae5ea60a4b5549c8a5914361c99147a709d2" 1757 | dependencies = [ 1758 | "proc-macro2", 1759 | "quote", 1760 | "syn", 1761 | ] 1762 | 1763 | [[package]] 1764 | name = "tendril" 1765 | version = "0.4.3" 1766 | source = "registry+https://github.com/rust-lang/crates.io-index" 1767 | checksum = "d24a120c5fc464a3458240ee02c299ebcb9d67b5249c8848b09d639dca8d7bb0" 1768 | dependencies = [ 1769 | "futf", 1770 | "mac", 1771 | "utf-8", 1772 | ] 1773 | 1774 | [[package]] 1775 | name = "thiserror" 1776 | version = "2.0.12" 1777 | source = "registry+https://github.com/rust-lang/crates.io-index" 1778 | checksum = "567b8a2dae586314f7be2a752ec7474332959c6460e02bde30d702a66d488708" 1779 | dependencies = [ 1780 | "thiserror-impl", 1781 | ] 1782 | 1783 | [[package]] 1784 | name = "thiserror-impl" 1785 | version = "2.0.12" 1786 | source = "registry+https://github.com/rust-lang/crates.io-index" 1787 | checksum = "7f7cf42b4507d8ea322120659672cf1b9dbb93f8f2d4ecfd6e51350ff5b17a1d" 1788 | dependencies = [ 1789 | "proc-macro2", 1790 | "quote", 1791 | "syn", 1792 | ] 1793 | 1794 | [[package]] 1795 | name = "thread_local" 1796 | version = "1.1.8" 1797 | source = "registry+https://github.com/rust-lang/crates.io-index" 1798 | checksum = "8b9ef9bad013ada3808854ceac7b46812a6465ba368859a37e2100283d2d719c" 1799 | dependencies = [ 1800 | "cfg-if", 1801 | "once_cell", 1802 | ] 1803 | 1804 | [[package]] 1805 | name = "tinystr" 1806 | version = "0.8.1" 1807 | source = "registry+https://github.com/rust-lang/crates.io-index" 1808 | checksum = "5d4f6d1145dcb577acf783d4e601bc1d76a13337bb54e6233add580b07344c8b" 1809 | dependencies = [ 1810 | "displaydoc", 1811 | "zerovec", 1812 | ] 1813 | 1814 | [[package]] 1815 | name = "tinyvec" 1816 | version = "1.9.0" 1817 | source = "registry+https://github.com/rust-lang/crates.io-index" 1818 | checksum = "09b3661f17e86524eccd4371ab0429194e0d7c008abb45f7a7495b1719463c71" 1819 | dependencies = [ 1820 | "tinyvec_macros", 1821 | ] 1822 | 1823 | [[package]] 1824 | name = "tinyvec_macros" 1825 | version = "0.1.1" 1826 | source = "registry+https://github.com/rust-lang/crates.io-index" 1827 | checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" 1828 | 1829 | [[package]] 1830 | name = "tokio" 1831 | version = "1.45.0" 1832 | source = "registry+https://github.com/rust-lang/crates.io-index" 1833 | checksum = "2513ca694ef9ede0fb23fe71a4ee4107cb102b9dc1930f6d0fd77aae068ae165" 1834 | dependencies = [ 1835 | "backtrace", 1836 | "bytes", 1837 | "libc", 1838 | "mio", 1839 | "parking_lot", 1840 | "pin-project-lite", 1841 | "signal-hook-registry", 1842 | "socket2", 1843 | "tokio-macros", 1844 | "windows-sys 0.52.0", 1845 | ] 1846 | 1847 | [[package]] 1848 | name = "tokio-macros" 1849 | version = "2.5.0" 1850 | source = "registry+https://github.com/rust-lang/crates.io-index" 1851 | checksum = "6e06d43f1345a3bcd39f6a56dbb7dcab2ba47e68e8ac134855e7e2bdbaf8cab8" 1852 | dependencies = [ 1853 | "proc-macro2", 1854 | "quote", 1855 | "syn", 1856 | ] 1857 | 1858 | [[package]] 1859 | name = "tokio-rustls" 1860 | version = "0.26.2" 1861 | source = "registry+https://github.com/rust-lang/crates.io-index" 1862 | checksum = "8e727b36a1a0e8b74c376ac2211e40c2c8af09fb4013c60d910495810f008e9b" 1863 | dependencies = [ 1864 | "rustls", 1865 | "tokio", 1866 | ] 1867 | 1868 | [[package]] 1869 | name = "tower" 1870 | version = "0.5.2" 1871 | source = "registry+https://github.com/rust-lang/crates.io-index" 1872 | checksum = "d039ad9159c98b70ecfd540b2573b97f7f52c3e8d9f8ad57a24b916a536975f9" 1873 | dependencies = [ 1874 | "futures-core", 1875 | "futures-util", 1876 | "pin-project-lite", 1877 | "sync_wrapper", 1878 | "tokio", 1879 | "tower-layer", 1880 | "tower-service", 1881 | ] 1882 | 1883 | [[package]] 1884 | name = "tower-layer" 1885 | version = "0.3.3" 1886 | source = "registry+https://github.com/rust-lang/crates.io-index" 1887 | checksum = "121c2a6cda46980bb0fcd1647ffaf6cd3fc79a013de288782836f6df9c48780e" 1888 | 1889 | [[package]] 1890 | name = "tower-service" 1891 | version = "0.3.3" 1892 | source = "registry+https://github.com/rust-lang/crates.io-index" 1893 | checksum = "8df9b6e13f2d32c91b9bd719c00d1958837bc7dec474d94952798cc8e69eeec3" 1894 | 1895 | [[package]] 1896 | name = "tracing" 1897 | version = "0.1.41" 1898 | source = "registry+https://github.com/rust-lang/crates.io-index" 1899 | checksum = "784e0ac535deb450455cbfa28a6f0df145ea1bb7ae51b821cf5e7927fdcfbdd0" 1900 | dependencies = [ 1901 | "pin-project-lite", 1902 | "tracing-core", 1903 | ] 1904 | 1905 | [[package]] 1906 | name = "tracing-core" 1907 | version = "0.1.33" 1908 | source = "registry+https://github.com/rust-lang/crates.io-index" 1909 | checksum = "e672c95779cf947c5311f83787af4fa8fffd12fb27e4993211a84bdfd9610f9c" 1910 | dependencies = [ 1911 | "once_cell", 1912 | "valuable", 1913 | ] 1914 | 1915 | [[package]] 1916 | name = "tracing-error" 1917 | version = "0.2.1" 1918 | source = "registry+https://github.com/rust-lang/crates.io-index" 1919 | checksum = "8b1581020d7a273442f5b45074a6a57d5757ad0a47dac0e9f0bd57b81936f3db" 1920 | dependencies = [ 1921 | "tracing", 1922 | "tracing-subscriber", 1923 | ] 1924 | 1925 | [[package]] 1926 | name = "tracing-subscriber" 1927 | version = "0.3.19" 1928 | source = "registry+https://github.com/rust-lang/crates.io-index" 1929 | checksum = "e8189decb5ac0fa7bc8b96b7cb9b2701d60d48805aca84a238004d665fcc4008" 1930 | dependencies = [ 1931 | "sharded-slab", 1932 | "thread_local", 1933 | "tracing-core", 1934 | ] 1935 | 1936 | [[package]] 1937 | name = "try-lock" 1938 | version = "0.2.5" 1939 | source = "registry+https://github.com/rust-lang/crates.io-index" 1940 | checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b" 1941 | 1942 | [[package]] 1943 | name = "unicode-ident" 1944 | version = "1.0.18" 1945 | source = "registry+https://github.com/rust-lang/crates.io-index" 1946 | checksum = "5a5f39404a5da50712a4c1eecf25e90dd62b613502b7e925fd4e4d19b5c96512" 1947 | 1948 | [[package]] 1949 | name = "unicode-segmentation" 1950 | version = "1.12.0" 1951 | source = "registry+https://github.com/rust-lang/crates.io-index" 1952 | checksum = "f6ccf251212114b54433ec949fd6a7841275f9ada20dddd2f29e9ceea4501493" 1953 | 1954 | [[package]] 1955 | name = "unicode-truncate" 1956 | version = "1.1.0" 1957 | source = "registry+https://github.com/rust-lang/crates.io-index" 1958 | checksum = "b3644627a5af5fa321c95b9b235a72fd24cd29c648c2c379431e6628655627bf" 1959 | dependencies = [ 1960 | "itertools", 1961 | "unicode-segmentation", 1962 | "unicode-width 0.1.14", 1963 | ] 1964 | 1965 | [[package]] 1966 | name = "unicode-width" 1967 | version = "0.1.14" 1968 | source = "registry+https://github.com/rust-lang/crates.io-index" 1969 | checksum = "7dd6e30e90baa6f72411720665d41d89b9a3d039dc45b8faea1ddd07f617f6af" 1970 | 1971 | [[package]] 1972 | name = "unicode-width" 1973 | version = "0.2.0" 1974 | source = "registry+https://github.com/rust-lang/crates.io-index" 1975 | checksum = "1fc81956842c57dac11422a97c3b8195a1ff727f06e85c84ed2e8aa277c9a0fd" 1976 | 1977 | [[package]] 1978 | name = "untrusted" 1979 | version = "0.9.0" 1980 | source = "registry+https://github.com/rust-lang/crates.io-index" 1981 | checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" 1982 | 1983 | [[package]] 1984 | name = "url" 1985 | version = "2.5.4" 1986 | source = "registry+https://github.com/rust-lang/crates.io-index" 1987 | checksum = "32f8b686cadd1473f4bd0117a5d28d36b1ade384ea9b5069a1c40aefed7fda60" 1988 | dependencies = [ 1989 | "form_urlencoded", 1990 | "idna", 1991 | "percent-encoding", 1992 | ] 1993 | 1994 | [[package]] 1995 | name = "utf-8" 1996 | version = "0.7.6" 1997 | source = "registry+https://github.com/rust-lang/crates.io-index" 1998 | checksum = "09cc8ee72d2a9becf2f2febe0205bbed8fc6615b7cb429ad062dc7b7ddd036a9" 1999 | 2000 | [[package]] 2001 | name = "utf8_iter" 2002 | version = "1.0.4" 2003 | source = "registry+https://github.com/rust-lang/crates.io-index" 2004 | checksum = "b6c140620e7ffbb22c2dee59cafe6084a59b5ffc27a8859a5f0d494b5d52b6be" 2005 | 2006 | [[package]] 2007 | name = "utf8parse" 2008 | version = "0.2.2" 2009 | source = "registry+https://github.com/rust-lang/crates.io-index" 2010 | checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" 2011 | 2012 | [[package]] 2013 | name = "valuable" 2014 | version = "0.1.1" 2015 | source = "registry+https://github.com/rust-lang/crates.io-index" 2016 | checksum = "ba73ea9cf16a25df0c8caa16c51acb937d5712a8429db78a3ee29d5dcacd3a65" 2017 | 2018 | [[package]] 2019 | name = "want" 2020 | version = "0.3.1" 2021 | source = "registry+https://github.com/rust-lang/crates.io-index" 2022 | checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e" 2023 | dependencies = [ 2024 | "try-lock", 2025 | ] 2026 | 2027 | [[package]] 2028 | name = "wasi" 2029 | version = "0.11.0+wasi-snapshot-preview1" 2030 | source = "registry+https://github.com/rust-lang/crates.io-index" 2031 | checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" 2032 | 2033 | [[package]] 2034 | name = "wasi" 2035 | version = "0.14.2+wasi-0.2.4" 2036 | source = "registry+https://github.com/rust-lang/crates.io-index" 2037 | checksum = "9683f9a5a998d873c0d21fcbe3c083009670149a8fab228644b8bd36b2c48cb3" 2038 | dependencies = [ 2039 | "wit-bindgen-rt", 2040 | ] 2041 | 2042 | [[package]] 2043 | name = "wasm-bindgen" 2044 | version = "0.2.100" 2045 | source = "registry+https://github.com/rust-lang/crates.io-index" 2046 | checksum = "1edc8929d7499fc4e8f0be2262a241556cfc54a0bea223790e71446f2aab1ef5" 2047 | dependencies = [ 2048 | "cfg-if", 2049 | "once_cell", 2050 | "rustversion", 2051 | "wasm-bindgen-macro", 2052 | ] 2053 | 2054 | [[package]] 2055 | name = "wasm-bindgen-backend" 2056 | version = "0.2.100" 2057 | source = "registry+https://github.com/rust-lang/crates.io-index" 2058 | checksum = "2f0a0651a5c2bc21487bde11ee802ccaf4c51935d0d3d42a6101f98161700bc6" 2059 | dependencies = [ 2060 | "bumpalo", 2061 | "log", 2062 | "proc-macro2", 2063 | "quote", 2064 | "syn", 2065 | "wasm-bindgen-shared", 2066 | ] 2067 | 2068 | [[package]] 2069 | name = "wasm-bindgen-futures" 2070 | version = "0.4.50" 2071 | source = "registry+https://github.com/rust-lang/crates.io-index" 2072 | checksum = "555d470ec0bc3bb57890405e5d4322cc9ea83cebb085523ced7be4144dac1e61" 2073 | dependencies = [ 2074 | "cfg-if", 2075 | "js-sys", 2076 | "once_cell", 2077 | "wasm-bindgen", 2078 | "web-sys", 2079 | ] 2080 | 2081 | [[package]] 2082 | name = "wasm-bindgen-macro" 2083 | version = "0.2.100" 2084 | source = "registry+https://github.com/rust-lang/crates.io-index" 2085 | checksum = "7fe63fc6d09ed3792bd0897b314f53de8e16568c2b3f7982f468c0bf9bd0b407" 2086 | dependencies = [ 2087 | "quote", 2088 | "wasm-bindgen-macro-support", 2089 | ] 2090 | 2091 | [[package]] 2092 | name = "wasm-bindgen-macro-support" 2093 | version = "0.2.100" 2094 | source = "registry+https://github.com/rust-lang/crates.io-index" 2095 | checksum = "8ae87ea40c9f689fc23f209965b6fb8a99ad69aeeb0231408be24920604395de" 2096 | dependencies = [ 2097 | "proc-macro2", 2098 | "quote", 2099 | "syn", 2100 | "wasm-bindgen-backend", 2101 | "wasm-bindgen-shared", 2102 | ] 2103 | 2104 | [[package]] 2105 | name = "wasm-bindgen-shared" 2106 | version = "0.2.100" 2107 | source = "registry+https://github.com/rust-lang/crates.io-index" 2108 | checksum = "1a05d73b933a847d6cccdda8f838a22ff101ad9bf93e33684f39c1f5f0eece3d" 2109 | dependencies = [ 2110 | "unicode-ident", 2111 | ] 2112 | 2113 | [[package]] 2114 | name = "web-sys" 2115 | version = "0.3.77" 2116 | source = "registry+https://github.com/rust-lang/crates.io-index" 2117 | checksum = "33b6dd2ef9186f1f2072e409e99cd22a975331a6b3591b12c764e0e55c60d5d2" 2118 | dependencies = [ 2119 | "js-sys", 2120 | "wasm-bindgen", 2121 | ] 2122 | 2123 | [[package]] 2124 | name = "web-time" 2125 | version = "1.1.0" 2126 | source = "registry+https://github.com/rust-lang/crates.io-index" 2127 | checksum = "5a6580f308b1fad9207618087a65c04e7a10bc77e02c8e84e9b00dd4b12fa0bb" 2128 | dependencies = [ 2129 | "js-sys", 2130 | "wasm-bindgen", 2131 | ] 2132 | 2133 | [[package]] 2134 | name = "webpki-roots" 2135 | version = "0.26.11" 2136 | source = "registry+https://github.com/rust-lang/crates.io-index" 2137 | checksum = "521bc38abb08001b01866da9f51eb7c5d647a19260e00054a8c7fd5f9e57f7a9" 2138 | dependencies = [ 2139 | "webpki-roots 1.0.0", 2140 | ] 2141 | 2142 | [[package]] 2143 | name = "webpki-roots" 2144 | version = "1.0.0" 2145 | source = "registry+https://github.com/rust-lang/crates.io-index" 2146 | checksum = "2853738d1cc4f2da3a225c18ec6c3721abb31961096e9dbf5ab35fa88b19cfdb" 2147 | dependencies = [ 2148 | "rustls-pki-types", 2149 | ] 2150 | 2151 | [[package]] 2152 | name = "winapi" 2153 | version = "0.3.9" 2154 | source = "registry+https://github.com/rust-lang/crates.io-index" 2155 | checksum = "5c839a674fcd7a98952e593242ea400abe93992746761e38641405d28b00f419" 2156 | dependencies = [ 2157 | "winapi-i686-pc-windows-gnu", 2158 | "winapi-x86_64-pc-windows-gnu", 2159 | ] 2160 | 2161 | [[package]] 2162 | name = "winapi-i686-pc-windows-gnu" 2163 | version = "0.4.0" 2164 | source = "registry+https://github.com/rust-lang/crates.io-index" 2165 | checksum = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6" 2166 | 2167 | [[package]] 2168 | name = "winapi-x86_64-pc-windows-gnu" 2169 | version = "0.4.0" 2170 | source = "registry+https://github.com/rust-lang/crates.io-index" 2171 | checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" 2172 | 2173 | [[package]] 2174 | name = "windows-link" 2175 | version = "0.1.1" 2176 | source = "registry+https://github.com/rust-lang/crates.io-index" 2177 | checksum = "76840935b766e1b0a05c0066835fb9ec80071d4c09a16f6bd5f7e655e3c14c38" 2178 | 2179 | [[package]] 2180 | name = "windows-registry" 2181 | version = "0.4.0" 2182 | source = "registry+https://github.com/rust-lang/crates.io-index" 2183 | checksum = "4286ad90ddb45071efd1a66dfa43eb02dd0dfbae1545ad6cc3c51cf34d7e8ba3" 2184 | dependencies = [ 2185 | "windows-result", 2186 | "windows-strings", 2187 | "windows-targets 0.53.0", 2188 | ] 2189 | 2190 | [[package]] 2191 | name = "windows-result" 2192 | version = "0.3.3" 2193 | source = "registry+https://github.com/rust-lang/crates.io-index" 2194 | checksum = "4b895b5356fc36103d0f64dd1e94dfa7ac5633f1c9dd6e80fe9ec4adef69e09d" 2195 | dependencies = [ 2196 | "windows-link", 2197 | ] 2198 | 2199 | [[package]] 2200 | name = "windows-strings" 2201 | version = "0.3.1" 2202 | source = "registry+https://github.com/rust-lang/crates.io-index" 2203 | checksum = "87fa48cc5d406560701792be122a10132491cff9d0aeb23583cc2dcafc847319" 2204 | dependencies = [ 2205 | "windows-link", 2206 | ] 2207 | 2208 | [[package]] 2209 | name = "windows-sys" 2210 | version = "0.52.0" 2211 | source = "registry+https://github.com/rust-lang/crates.io-index" 2212 | checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" 2213 | dependencies = [ 2214 | "windows-targets 0.52.6", 2215 | ] 2216 | 2217 | [[package]] 2218 | name = "windows-sys" 2219 | version = "0.59.0" 2220 | source = "registry+https://github.com/rust-lang/crates.io-index" 2221 | checksum = "1e38bc4d79ed67fd075bcc251a1c39b32a1776bbe92e5bef1f0bf1f8c531853b" 2222 | dependencies = [ 2223 | "windows-targets 0.52.6", 2224 | ] 2225 | 2226 | [[package]] 2227 | name = "windows-targets" 2228 | version = "0.52.6" 2229 | source = "registry+https://github.com/rust-lang/crates.io-index" 2230 | checksum = "9b724f72796e036ab90c1021d4780d4d3d648aca59e491e6b98e725b84e99973" 2231 | dependencies = [ 2232 | "windows_aarch64_gnullvm 0.52.6", 2233 | "windows_aarch64_msvc 0.52.6", 2234 | "windows_i686_gnu 0.52.6", 2235 | "windows_i686_gnullvm 0.52.6", 2236 | "windows_i686_msvc 0.52.6", 2237 | "windows_x86_64_gnu 0.52.6", 2238 | "windows_x86_64_gnullvm 0.52.6", 2239 | "windows_x86_64_msvc 0.52.6", 2240 | ] 2241 | 2242 | [[package]] 2243 | name = "windows-targets" 2244 | version = "0.53.0" 2245 | source = "registry+https://github.com/rust-lang/crates.io-index" 2246 | checksum = "b1e4c7e8ceaaf9cb7d7507c974735728ab453b67ef8f18febdd7c11fe59dca8b" 2247 | dependencies = [ 2248 | "windows_aarch64_gnullvm 0.53.0", 2249 | "windows_aarch64_msvc 0.53.0", 2250 | "windows_i686_gnu 0.53.0", 2251 | "windows_i686_gnullvm 0.53.0", 2252 | "windows_i686_msvc 0.53.0", 2253 | "windows_x86_64_gnu 0.53.0", 2254 | "windows_x86_64_gnullvm 0.53.0", 2255 | "windows_x86_64_msvc 0.53.0", 2256 | ] 2257 | 2258 | [[package]] 2259 | name = "windows_aarch64_gnullvm" 2260 | version = "0.52.6" 2261 | source = "registry+https://github.com/rust-lang/crates.io-index" 2262 | checksum = "32a4622180e7a0ec044bb555404c800bc9fd9ec262ec147edd5989ccd0c02cd3" 2263 | 2264 | [[package]] 2265 | name = "windows_aarch64_gnullvm" 2266 | version = "0.53.0" 2267 | source = "registry+https://github.com/rust-lang/crates.io-index" 2268 | checksum = "86b8d5f90ddd19cb4a147a5fa63ca848db3df085e25fee3cc10b39b6eebae764" 2269 | 2270 | [[package]] 2271 | name = "windows_aarch64_msvc" 2272 | version = "0.52.6" 2273 | source = "registry+https://github.com/rust-lang/crates.io-index" 2274 | checksum = "09ec2a7bb152e2252b53fa7803150007879548bc709c039df7627cabbd05d469" 2275 | 2276 | [[package]] 2277 | name = "windows_aarch64_msvc" 2278 | version = "0.53.0" 2279 | source = "registry+https://github.com/rust-lang/crates.io-index" 2280 | checksum = "c7651a1f62a11b8cbd5e0d42526e55f2c99886c77e007179efff86c2b137e66c" 2281 | 2282 | [[package]] 2283 | name = "windows_i686_gnu" 2284 | version = "0.52.6" 2285 | source = "registry+https://github.com/rust-lang/crates.io-index" 2286 | checksum = "8e9b5ad5ab802e97eb8e295ac6720e509ee4c243f69d781394014ebfe8bbfa0b" 2287 | 2288 | [[package]] 2289 | name = "windows_i686_gnu" 2290 | version = "0.53.0" 2291 | source = "registry+https://github.com/rust-lang/crates.io-index" 2292 | checksum = "c1dc67659d35f387f5f6c479dc4e28f1d4bb90ddd1a5d3da2e5d97b42d6272c3" 2293 | 2294 | [[package]] 2295 | name = "windows_i686_gnullvm" 2296 | version = "0.52.6" 2297 | source = "registry+https://github.com/rust-lang/crates.io-index" 2298 | checksum = "0eee52d38c090b3caa76c563b86c3a4bd71ef1a819287c19d586d7334ae8ed66" 2299 | 2300 | [[package]] 2301 | name = "windows_i686_gnullvm" 2302 | version = "0.53.0" 2303 | source = "registry+https://github.com/rust-lang/crates.io-index" 2304 | checksum = "9ce6ccbdedbf6d6354471319e781c0dfef054c81fbc7cf83f338a4296c0cae11" 2305 | 2306 | [[package]] 2307 | name = "windows_i686_msvc" 2308 | version = "0.52.6" 2309 | source = "registry+https://github.com/rust-lang/crates.io-index" 2310 | checksum = "240948bc05c5e7c6dabba28bf89d89ffce3e303022809e73deaefe4f6ec56c66" 2311 | 2312 | [[package]] 2313 | name = "windows_i686_msvc" 2314 | version = "0.53.0" 2315 | source = "registry+https://github.com/rust-lang/crates.io-index" 2316 | checksum = "581fee95406bb13382d2f65cd4a908ca7b1e4c2f1917f143ba16efe98a589b5d" 2317 | 2318 | [[package]] 2319 | name = "windows_x86_64_gnu" 2320 | version = "0.52.6" 2321 | source = "registry+https://github.com/rust-lang/crates.io-index" 2322 | checksum = "147a5c80aabfbf0c7d901cb5895d1de30ef2907eb21fbbab29ca94c5b08b1a78" 2323 | 2324 | [[package]] 2325 | name = "windows_x86_64_gnu" 2326 | version = "0.53.0" 2327 | source = "registry+https://github.com/rust-lang/crates.io-index" 2328 | checksum = "2e55b5ac9ea33f2fc1716d1742db15574fd6fc8dadc51caab1c16a3d3b4190ba" 2329 | 2330 | [[package]] 2331 | name = "windows_x86_64_gnullvm" 2332 | version = "0.52.6" 2333 | source = "registry+https://github.com/rust-lang/crates.io-index" 2334 | checksum = "24d5b23dc417412679681396f2b49f3de8c1473deb516bd34410872eff51ed0d" 2335 | 2336 | [[package]] 2337 | name = "windows_x86_64_gnullvm" 2338 | version = "0.53.0" 2339 | source = "registry+https://github.com/rust-lang/crates.io-index" 2340 | checksum = "0a6e035dd0599267ce1ee132e51c27dd29437f63325753051e71dd9e42406c57" 2341 | 2342 | [[package]] 2343 | name = "windows_x86_64_msvc" 2344 | version = "0.52.6" 2345 | source = "registry+https://github.com/rust-lang/crates.io-index" 2346 | checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec" 2347 | 2348 | [[package]] 2349 | name = "windows_x86_64_msvc" 2350 | version = "0.53.0" 2351 | source = "registry+https://github.com/rust-lang/crates.io-index" 2352 | checksum = "271414315aff87387382ec3d271b52d7ae78726f5d44ac98b4f4030c91880486" 2353 | 2354 | [[package]] 2355 | name = "wit-bindgen-rt" 2356 | version = "0.39.0" 2357 | source = "registry+https://github.com/rust-lang/crates.io-index" 2358 | checksum = "6f42320e61fe2cfd34354ecb597f86f413484a798ba44a8ca1165c58d42da6c1" 2359 | dependencies = [ 2360 | "bitflags", 2361 | ] 2362 | 2363 | [[package]] 2364 | name = "writeable" 2365 | version = "0.6.1" 2366 | source = "registry+https://github.com/rust-lang/crates.io-index" 2367 | checksum = "ea2f10b9bb0928dfb1b42b65e1f9e36f7f54dbdf08457afefb38afcdec4fa2bb" 2368 | 2369 | [[package]] 2370 | name = "yoke" 2371 | version = "0.8.0" 2372 | source = "registry+https://github.com/rust-lang/crates.io-index" 2373 | checksum = "5f41bb01b8226ef4bfd589436a297c53d118f65921786300e427be8d487695cc" 2374 | dependencies = [ 2375 | "serde", 2376 | "stable_deref_trait", 2377 | "yoke-derive", 2378 | "zerofrom", 2379 | ] 2380 | 2381 | [[package]] 2382 | name = "yoke-derive" 2383 | version = "0.8.0" 2384 | source = "registry+https://github.com/rust-lang/crates.io-index" 2385 | checksum = "38da3c9736e16c5d3c8c597a9aaa5d1fa565d0532ae05e27c24aa62fb32c0ab6" 2386 | dependencies = [ 2387 | "proc-macro2", 2388 | "quote", 2389 | "syn", 2390 | "synstructure", 2391 | ] 2392 | 2393 | [[package]] 2394 | name = "zerocopy" 2395 | version = "0.8.25" 2396 | source = "registry+https://github.com/rust-lang/crates.io-index" 2397 | checksum = "a1702d9583232ddb9174e01bb7c15a2ab8fb1bc6f227aa1233858c351a3ba0cb" 2398 | dependencies = [ 2399 | "zerocopy-derive", 2400 | ] 2401 | 2402 | [[package]] 2403 | name = "zerocopy-derive" 2404 | version = "0.8.25" 2405 | source = "registry+https://github.com/rust-lang/crates.io-index" 2406 | checksum = "28a6e20d751156648aa063f3800b706ee209a32c0b4d9f24be3d980b01be55ef" 2407 | dependencies = [ 2408 | "proc-macro2", 2409 | "quote", 2410 | "syn", 2411 | ] 2412 | 2413 | [[package]] 2414 | name = "zerofrom" 2415 | version = "0.1.6" 2416 | source = "registry+https://github.com/rust-lang/crates.io-index" 2417 | checksum = "50cc42e0333e05660c3587f3bf9d0478688e15d870fab3346451ce7f8c9fbea5" 2418 | dependencies = [ 2419 | "zerofrom-derive", 2420 | ] 2421 | 2422 | [[package]] 2423 | name = "zerofrom-derive" 2424 | version = "0.1.6" 2425 | source = "registry+https://github.com/rust-lang/crates.io-index" 2426 | checksum = "d71e5d6e06ab090c67b5e44993ec16b72dcbaabc526db883a360057678b48502" 2427 | dependencies = [ 2428 | "proc-macro2", 2429 | "quote", 2430 | "syn", 2431 | "synstructure", 2432 | ] 2433 | 2434 | [[package]] 2435 | name = "zeroize" 2436 | version = "1.8.1" 2437 | source = "registry+https://github.com/rust-lang/crates.io-index" 2438 | checksum = "ced3678a2879b30306d323f4542626697a464a97c0a07c9aebf7ebca65cd4dde" 2439 | 2440 | [[package]] 2441 | name = "zerotrie" 2442 | version = "0.2.2" 2443 | source = "registry+https://github.com/rust-lang/crates.io-index" 2444 | checksum = "36f0bbd478583f79edad978b407914f61b2972f5af6fa089686016be8f9af595" 2445 | dependencies = [ 2446 | "displaydoc", 2447 | "yoke", 2448 | "zerofrom", 2449 | ] 2450 | 2451 | [[package]] 2452 | name = "zerovec" 2453 | version = "0.11.2" 2454 | source = "registry+https://github.com/rust-lang/crates.io-index" 2455 | checksum = "4a05eb080e015ba39cc9e23bbe5e7fb04d5fb040350f99f34e338d5fdd294428" 2456 | dependencies = [ 2457 | "yoke", 2458 | "zerofrom", 2459 | "zerovec-derive", 2460 | ] 2461 | 2462 | [[package]] 2463 | name = "zerovec-derive" 2464 | version = "0.11.1" 2465 | source = "registry+https://github.com/rust-lang/crates.io-index" 2466 | checksum = "5b96237efa0c878c64bd89c436f661be4e46b2f3eff1ebb976f7ef2321d2f58f" 2467 | dependencies = [ 2468 | "proc-macro2", 2469 | "quote", 2470 | "syn", 2471 | ] 2472 | -------------------------------------------------------------------------------- /Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "lobtui" 3 | version = "0.3.1" 4 | authors = ["Badr Badri "] 5 | license = "GPL-3.0" 6 | description = "TUI for lobste.rs website" 7 | edition = "2024" 8 | readme = "Readme.md" 9 | homepage = "https://github.com/pythops/lobtui" 10 | repository = "https://github.com/pythops/lobtui" 11 | 12 | [dependencies] 13 | crossterm = { version = "0.28", features = ["event-stream"] } 14 | futures = "0.3" 15 | ratatui = "0.29" 16 | tokio = { version = "1", features = ["full"] } 17 | scraper = "0.23" 18 | reqwest = { version = "0.12", default-features = false, features = [ 19 | "rustls-tls", 20 | ] } 21 | open = "5" 22 | color-eyre = "0.6" 23 | clap = { version = "4", features = ["derive", "cargo"] } 24 | 25 | [profile.release] 26 | lto = "fat" 27 | strip = true 28 | codegen-units = 1 29 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | GNU GENERAL PUBLIC LICENSE 2 | Version 3, 29 June 2007 3 | 4 | Copyright (C) 2007 Free Software Foundation, Inc. 5 | Everyone is permitted to copy and distribute verbatim copies 6 | of this license document, but changing it is not allowed. 7 | 8 | Preamble 9 | 10 | The GNU General Public License is a free, copyleft license for 11 | software and other kinds of works. 12 | 13 | The licenses for most software and other practical works are designed 14 | to take away your freedom to share and change the works. By contrast, 15 | the GNU General Public License is intended to guarantee your freedom to 16 | share and change all versions of a program--to make sure it remains free 17 | software for all its users. We, the Free Software Foundation, use the 18 | GNU General Public License for most of our software; it applies also to 19 | any other work released this way by its authors. You can apply it to 20 | your programs, too. 21 | 22 | When we speak of free software, we are referring to freedom, not 23 | price. Our General Public Licenses are designed to make sure that you 24 | have the freedom to distribute copies of free software (and charge for 25 | them if you wish), that you receive source code or can get it if you 26 | want it, that you can change the software or use pieces of it in new 27 | free programs, and that you know you can do these things. 28 | 29 | To protect your rights, we need to prevent others from denying you 30 | these rights or asking you to surrender the rights. Therefore, you have 31 | certain responsibilities if you distribute copies of the software, or if 32 | you modify it: responsibilities to respect the freedom of others. 33 | 34 | For example, if you distribute copies of such a program, whether 35 | gratis or for a fee, you must pass on to the recipients the same 36 | freedoms that you received. You must make sure that they, too, receive 37 | or can get the source code. And you must show them these terms so they 38 | know their rights. 39 | 40 | Developers that use the GNU GPL protect your rights with two steps: 41 | (1) assert copyright on the software, and (2) offer you this License 42 | giving you legal permission to copy, distribute and/or modify it. 43 | 44 | For the developers' and authors' protection, the GPL clearly explains 45 | that there is no warranty for this free software. For both users' and 46 | authors' sake, the GPL requires that modified versions be marked as 47 | changed, so that their problems will not be attributed erroneously to 48 | authors of previous versions. 49 | 50 | Some devices are designed to deny users access to install or run 51 | modified versions of the software inside them, although the manufacturer 52 | can do so. This is fundamentally incompatible with the aim of 53 | protecting users' freedom to change the software. The systematic 54 | pattern of such abuse occurs in the area of products for individuals to 55 | use, which is precisely where it is most unacceptable. Therefore, we 56 | have designed this version of the GPL to prohibit the practice for those 57 | products. If such problems arise substantially in other domains, we 58 | stand ready to extend this provision to those domains in future versions 59 | of the GPL, as needed to protect the freedom of users. 60 | 61 | Finally, every program is threatened constantly by software patents. 62 | States should not allow patents to restrict development and use of 63 | software on general-purpose computers, but in those that do, we wish to 64 | avoid the special danger that patents applied to a free program could 65 | make it effectively proprietary. To prevent this, the GPL assures that 66 | patents cannot be used to render the program non-free. 67 | 68 | The precise terms and conditions for copying, distribution and 69 | modification follow. 70 | 71 | TERMS AND CONDITIONS 72 | 73 | 0. Definitions. 74 | 75 | "This License" refers to version 3 of the GNU General Public License. 76 | 77 | "Copyright" also means copyright-like laws that apply to other kinds of 78 | works, such as semiconductor masks. 79 | 80 | "The Program" refers to any copyrightable work licensed under this 81 | License. Each licensee is addressed as "you". "Licensees" and 82 | "recipients" may be individuals or organizations. 83 | 84 | To "modify" a work means to copy from or adapt all or part of the work 85 | in a fashion requiring copyright permission, other than the making of an 86 | exact copy. The resulting work is called a "modified version" of the 87 | earlier work or a work "based on" the earlier work. 88 | 89 | A "covered work" means either the unmodified Program or a work based 90 | on the Program. 91 | 92 | To "propagate" a work means to do anything with it that, without 93 | permission, would make you directly or secondarily liable for 94 | infringement under applicable copyright law, except executing it on a 95 | computer or modifying a private copy. Propagation includes copying, 96 | distribution (with or without modification), making available to the 97 | public, and in some countries other activities as well. 98 | 99 | To "convey" a work means any kind of propagation that enables other 100 | parties to make or receive copies. Mere interaction with a user through 101 | a computer network, with no transfer of a copy, is not conveying. 102 | 103 | An interactive user interface displays "Appropriate Legal Notices" 104 | to the extent that it includes a convenient and prominently visible 105 | feature that (1) displays an appropriate copyright notice, and (2) 106 | tells the user that there is no warranty for the work (except to the 107 | extent that warranties are provided), that licensees may convey the 108 | work under this License, and how to view a copy of this License. If 109 | the interface presents a list of user commands or options, such as a 110 | menu, a prominent item in the list meets this criterion. 111 | 112 | 1. Source Code. 113 | 114 | The "source code" for a work means the preferred form of the work 115 | for making modifications to it. "Object code" means any non-source 116 | form of a work. 117 | 118 | A "Standard Interface" means an interface that either is an official 119 | standard defined by a recognized standards body, or, in the case of 120 | interfaces specified for a particular programming language, one that 121 | is widely used among developers working in that language. 122 | 123 | The "System Libraries" of an executable work include anything, other 124 | than the work as a whole, that (a) is included in the normal form of 125 | packaging a Major Component, but which is not part of that Major 126 | Component, and (b) serves only to enable use of the work with that 127 | Major Component, or to implement a Standard Interface for which an 128 | implementation is available to the public in source code form. A 129 | "Major Component", in this context, means a major essential component 130 | (kernel, window system, and so on) of the specific operating system 131 | (if any) on which the executable work runs, or a compiler used to 132 | produce the work, or an object code interpreter used to run it. 133 | 134 | The "Corresponding Source" for a work in object code form means all 135 | the source code needed to generate, install, and (for an executable 136 | work) run the object code and to modify the work, including scripts to 137 | control those activities. However, it does not include the work's 138 | System Libraries, or general-purpose tools or generally available free 139 | programs which are used unmodified in performing those activities but 140 | which are not part of the work. For example, Corresponding Source 141 | includes interface definition files associated with source files for 142 | the work, and the source code for shared libraries and dynamically 143 | linked subprograms that the work is specifically designed to require, 144 | such as by intimate data communication or control flow between those 145 | subprograms and other parts of the work. 146 | 147 | The Corresponding Source need not include anything that users 148 | can regenerate automatically from other parts of the Corresponding 149 | Source. 150 | 151 | The Corresponding Source for a work in source code form is that 152 | same work. 153 | 154 | 2. Basic Permissions. 155 | 156 | All rights granted under this License are granted for the term of 157 | copyright on the Program, and are irrevocable provided the stated 158 | conditions are met. This License explicitly affirms your unlimited 159 | permission to run the unmodified Program. The output from running a 160 | covered work is covered by this License only if the output, given its 161 | content, constitutes a covered work. This License acknowledges your 162 | rights of fair use or other equivalent, as provided by copyright law. 163 | 164 | You may make, run and propagate covered works that you do not 165 | convey, without conditions so long as your license otherwise remains 166 | in force. You may convey covered works to others for the sole purpose 167 | of having them make modifications exclusively for you, or provide you 168 | with facilities for running those works, provided that you comply with 169 | the terms of this License in conveying all material for which you do 170 | not control copyright. Those thus making or running the covered works 171 | for you must do so exclusively on your behalf, under your direction 172 | and control, on terms that prohibit them from making any copies of 173 | your copyrighted material outside their relationship with you. 174 | 175 | Conveying under any other circumstances is permitted solely under 176 | the conditions stated below. Sublicensing is not allowed; section 10 177 | makes it unnecessary. 178 | 179 | 3. Protecting Users' Legal Rights From Anti-Circumvention Law. 180 | 181 | No covered work shall be deemed part of an effective technological 182 | measure under any applicable law fulfilling obligations under article 183 | 11 of the WIPO copyright treaty adopted on 20 December 1996, or 184 | similar laws prohibiting or restricting circumvention of such 185 | measures. 186 | 187 | When you convey a covered work, you waive any legal power to forbid 188 | circumvention of technological measures to the extent such circumvention 189 | is effected by exercising rights under this License with respect to 190 | the covered work, and you disclaim any intention to limit operation or 191 | modification of the work as a means of enforcing, against the work's 192 | users, your or third parties' legal rights to forbid circumvention of 193 | technological measures. 194 | 195 | 4. Conveying Verbatim Copies. 196 | 197 | You may convey verbatim copies of the Program's source code as you 198 | receive it, in any medium, provided that you conspicuously and 199 | appropriately publish on each copy an appropriate copyright notice; 200 | keep intact all notices stating that this License and any 201 | non-permissive terms added in accord with section 7 apply to the code; 202 | keep intact all notices of the absence of any warranty; and give all 203 | recipients a copy of this License along with the Program. 204 | 205 | You may charge any price or no price for each copy that you convey, 206 | and you may offer support or warranty protection for a fee. 207 | 208 | 5. Conveying Modified Source Versions. 209 | 210 | You may convey a work based on the Program, or the modifications to 211 | produce it from the Program, in the form of source code under the 212 | terms of section 4, provided that you also meet all of these conditions: 213 | 214 | a) The work must carry prominent notices stating that you modified 215 | it, and giving a relevant date. 216 | 217 | b) The work must carry prominent notices stating that it is 218 | released under this License and any conditions added under section 219 | 7. This requirement modifies the requirement in section 4 to 220 | "keep intact all notices". 221 | 222 | c) You must license the entire work, as a whole, under this 223 | License to anyone who comes into possession of a copy. This 224 | License will therefore apply, along with any applicable section 7 225 | additional terms, to the whole of the work, and all its parts, 226 | regardless of how they are packaged. This License gives no 227 | permission to license the work in any other way, but it does not 228 | invalidate such permission if you have separately received it. 229 | 230 | d) If the work has interactive user interfaces, each must display 231 | Appropriate Legal Notices; however, if the Program has interactive 232 | interfaces that do not display Appropriate Legal Notices, your 233 | work need not make them do so. 234 | 235 | A compilation of a covered work with other separate and independent 236 | works, which are not by their nature extensions of the covered work, 237 | and which are not combined with it such as to form a larger program, 238 | in or on a volume of a storage or distribution medium, is called an 239 | "aggregate" if the compilation and its resulting copyright are not 240 | used to limit the access or legal rights of the compilation's users 241 | beyond what the individual works permit. Inclusion of a covered work 242 | in an aggregate does not cause this License to apply to the other 243 | parts of the aggregate. 244 | 245 | 6. Conveying Non-Source Forms. 246 | 247 | You may convey a covered work in object code form under the terms 248 | of sections 4 and 5, provided that you also convey the 249 | machine-readable Corresponding Source under the terms of this License, 250 | in one of these ways: 251 | 252 | a) Convey the object code in, or embodied in, a physical product 253 | (including a physical distribution medium), accompanied by the 254 | Corresponding Source fixed on a durable physical medium 255 | customarily used for software interchange. 256 | 257 | b) Convey the object code in, or embodied in, a physical product 258 | (including a physical distribution medium), accompanied by a 259 | written offer, valid for at least three years and valid for as 260 | long as you offer spare parts or customer support for that product 261 | model, to give anyone who possesses the object code either (1) a 262 | copy of the Corresponding Source for all the software in the 263 | product that is covered by this License, on a durable physical 264 | medium customarily used for software interchange, for a price no 265 | more than your reasonable cost of physically performing this 266 | conveying of source, or (2) access to copy the 267 | Corresponding Source from a network server at no charge. 268 | 269 | c) Convey individual copies of the object code with a copy of the 270 | written offer to provide the Corresponding Source. This 271 | alternative is allowed only occasionally and noncommercially, and 272 | only if you received the object code with such an offer, in accord 273 | with subsection 6b. 274 | 275 | d) Convey the object code by offering access from a designated 276 | place (gratis or for a charge), and offer equivalent access to the 277 | Corresponding Source in the same way through the same place at no 278 | further charge. You need not require recipients to copy the 279 | Corresponding Source along with the object code. If the place to 280 | copy the object code is a network server, the Corresponding Source 281 | may be on a different server (operated by you or a third party) 282 | that supports equivalent copying facilities, provided you maintain 283 | clear directions next to the object code saying where to find the 284 | Corresponding Source. Regardless of what server hosts the 285 | Corresponding Source, you remain obligated to ensure that it is 286 | available for as long as needed to satisfy these requirements. 287 | 288 | e) Convey the object code using peer-to-peer transmission, provided 289 | you inform other peers where the object code and Corresponding 290 | Source of the work are being offered to the general public at no 291 | charge under subsection 6d. 292 | 293 | A separable portion of the object code, whose source code is excluded 294 | from the Corresponding Source as a System Library, need not be 295 | included in conveying the object code work. 296 | 297 | A "User Product" is either (1) a "consumer product", which means any 298 | tangible personal property which is normally used for personal, family, 299 | or household purposes, or (2) anything designed or sold for incorporation 300 | into a dwelling. In determining whether a product is a consumer product, 301 | doubtful cases shall be resolved in favor of coverage. For a particular 302 | product received by a particular user, "normally used" refers to a 303 | typical or common use of that class of product, regardless of the status 304 | of the particular user or of the way in which the particular user 305 | actually uses, or expects or is expected to use, the product. A product 306 | is a consumer product regardless of whether the product has substantial 307 | commercial, industrial or non-consumer uses, unless such uses represent 308 | the only significant mode of use of the product. 309 | 310 | "Installation Information" for a User Product means any methods, 311 | procedures, authorization keys, or other information required to install 312 | and execute modified versions of a covered work in that User Product from 313 | a modified version of its Corresponding Source. The information must 314 | suffice to ensure that the continued functioning of the modified object 315 | code is in no case prevented or interfered with solely because 316 | modification has been made. 317 | 318 | If you convey an object code work under this section in, or with, or 319 | specifically for use in, a User Product, and the conveying occurs as 320 | part of a transaction in which the right of possession and use of the 321 | User Product is transferred to the recipient in perpetuity or for a 322 | fixed term (regardless of how the transaction is characterized), the 323 | Corresponding Source conveyed under this section must be accompanied 324 | by the Installation Information. But this requirement does not apply 325 | if neither you nor any third party retains the ability to install 326 | modified object code on the User Product (for example, the work has 327 | been installed in ROM). 328 | 329 | The requirement to provide Installation Information does not include a 330 | requirement to continue to provide support service, warranty, or updates 331 | for a work that has been modified or installed by the recipient, or for 332 | the User Product in which it has been modified or installed. Access to a 333 | network may be denied when the modification itself materially and 334 | adversely affects the operation of the network or violates the rules and 335 | protocols for communication across the network. 336 | 337 | Corresponding Source conveyed, and Installation Information provided, 338 | in accord with this section must be in a format that is publicly 339 | documented (and with an implementation available to the public in 340 | source code form), and must require no special password or key for 341 | unpacking, reading or copying. 342 | 343 | 7. Additional Terms. 344 | 345 | "Additional permissions" are terms that supplement the terms of this 346 | License by making exceptions from one or more of its conditions. 347 | Additional permissions that are applicable to the entire Program shall 348 | be treated as though they were included in this License, to the extent 349 | that they are valid under applicable law. If additional permissions 350 | apply only to part of the Program, that part may be used separately 351 | under those permissions, but the entire Program remains governed by 352 | this License without regard to the additional permissions. 353 | 354 | When you convey a copy of a covered work, you may at your option 355 | remove any additional permissions from that copy, or from any part of 356 | it. (Additional permissions may be written to require their own 357 | removal in certain cases when you modify the work.) You may place 358 | additional permissions on material, added by you to a covered work, 359 | for which you have or can give appropriate copyright permission. 360 | 361 | Notwithstanding any other provision of this License, for material you 362 | add to a covered work, you may (if authorized by the copyright holders of 363 | that material) supplement the terms of this License with terms: 364 | 365 | a) Disclaiming warranty or limiting liability differently from the 366 | terms of sections 15 and 16 of this License; or 367 | 368 | b) Requiring preservation of specified reasonable legal notices or 369 | author attributions in that material or in the Appropriate Legal 370 | Notices displayed by works containing it; or 371 | 372 | c) Prohibiting misrepresentation of the origin of that material, or 373 | requiring that modified versions of such material be marked in 374 | reasonable ways as different from the original version; or 375 | 376 | d) Limiting the use for publicity purposes of names of licensors or 377 | authors of the material; or 378 | 379 | e) Declining to grant rights under trademark law for use of some 380 | trade names, trademarks, or service marks; or 381 | 382 | f) Requiring indemnification of licensors and authors of that 383 | material by anyone who conveys the material (or modified versions of 384 | it) with contractual assumptions of liability to the recipient, for 385 | any liability that these contractual assumptions directly impose on 386 | those licensors and authors. 387 | 388 | All other non-permissive additional terms are considered "further 389 | restrictions" within the meaning of section 10. If the Program as you 390 | received it, or any part of it, contains a notice stating that it is 391 | governed by this License along with a term that is a further 392 | restriction, you may remove that term. If a license document contains 393 | a further restriction but permits relicensing or conveying under this 394 | License, you may add to a covered work material governed by the terms 395 | of that license document, provided that the further restriction does 396 | not survive such relicensing or conveying. 397 | 398 | If you add terms to a covered work in accord with this section, you 399 | must place, in the relevant source files, a statement of the 400 | additional terms that apply to those files, or a notice indicating 401 | where to find the applicable terms. 402 | 403 | Additional terms, permissive or non-permissive, may be stated in the 404 | form of a separately written license, or stated as exceptions; 405 | the above requirements apply either way. 406 | 407 | 8. Termination. 408 | 409 | You may not propagate or modify a covered work except as expressly 410 | provided under this License. Any attempt otherwise to propagate or 411 | modify it is void, and will automatically terminate your rights under 412 | this License (including any patent licenses granted under the third 413 | paragraph of section 11). 414 | 415 | However, if you cease all violation of this License, then your 416 | license from a particular copyright holder is reinstated (a) 417 | provisionally, unless and until the copyright holder explicitly and 418 | finally terminates your license, and (b) permanently, if the copyright 419 | holder fails to notify you of the violation by some reasonable means 420 | prior to 60 days after the cessation. 421 | 422 | Moreover, your license from a particular copyright holder is 423 | reinstated permanently if the copyright holder notifies you of the 424 | violation by some reasonable means, this is the first time you have 425 | received notice of violation of this License (for any work) from that 426 | copyright holder, and you cure the violation prior to 30 days after 427 | your receipt of the notice. 428 | 429 | Termination of your rights under this section does not terminate the 430 | licenses of parties who have received copies or rights from you under 431 | this License. If your rights have been terminated and not permanently 432 | reinstated, you do not qualify to receive new licenses for the same 433 | material under section 10. 434 | 435 | 9. Acceptance Not Required for Having Copies. 436 | 437 | You are not required to accept this License in order to receive or 438 | run a copy of the Program. Ancillary propagation of a covered work 439 | occurring solely as a consequence of using peer-to-peer transmission 440 | to receive a copy likewise does not require acceptance. However, 441 | nothing other than this License grants you permission to propagate or 442 | modify any covered work. These actions infringe copyright if you do 443 | not accept this License. Therefore, by modifying or propagating a 444 | covered work, you indicate your acceptance of this License to do so. 445 | 446 | 10. Automatic Licensing of Downstream Recipients. 447 | 448 | Each time you convey a covered work, the recipient automatically 449 | receives a license from the original licensors, to run, modify and 450 | propagate that work, subject to this License. You are not responsible 451 | for enforcing compliance by third parties with this License. 452 | 453 | An "entity transaction" is a transaction transferring control of an 454 | organization, or substantially all assets of one, or subdividing an 455 | organization, or merging organizations. If propagation of a covered 456 | work results from an entity transaction, each party to that 457 | transaction who receives a copy of the work also receives whatever 458 | licenses to the work the party's predecessor in interest had or could 459 | give under the previous paragraph, plus a right to possession of the 460 | Corresponding Source of the work from the predecessor in interest, if 461 | the predecessor has it or can get it with reasonable efforts. 462 | 463 | You may not impose any further restrictions on the exercise of the 464 | rights granted or affirmed under this License. For example, you may 465 | not impose a license fee, royalty, or other charge for exercise of 466 | rights granted under this License, and you may not initiate litigation 467 | (including a cross-claim or counterclaim in a lawsuit) alleging that 468 | any patent claim is infringed by making, using, selling, offering for 469 | sale, or importing the Program or any portion of it. 470 | 471 | 11. Patents. 472 | 473 | A "contributor" is a copyright holder who authorizes use under this 474 | License of the Program or a work on which the Program is based. The 475 | work thus licensed is called the contributor's "contributor version". 476 | 477 | A contributor's "essential patent claims" are all patent claims 478 | owned or controlled by the contributor, whether already acquired or 479 | hereafter acquired, that would be infringed by some manner, permitted 480 | by this License, of making, using, or selling its contributor version, 481 | but do not include claims that would be infringed only as a 482 | consequence of further modification of the contributor version. For 483 | purposes of this definition, "control" includes the right to grant 484 | patent sublicenses in a manner consistent with the requirements of 485 | this License. 486 | 487 | Each contributor grants you a non-exclusive, worldwide, royalty-free 488 | patent license under the contributor's essential patent claims, to 489 | make, use, sell, offer for sale, import and otherwise run, modify and 490 | propagate the contents of its contributor version. 491 | 492 | In the following three paragraphs, a "patent license" is any express 493 | agreement or commitment, however denominated, not to enforce a patent 494 | (such as an express permission to practice a patent or covenant not to 495 | sue for patent infringement). To "grant" such a patent license to a 496 | party means to make such an agreement or commitment not to enforce a 497 | patent against the party. 498 | 499 | If you convey a covered work, knowingly relying on a patent license, 500 | and the Corresponding Source of the work is not available for anyone 501 | to copy, free of charge and under the terms of this License, through a 502 | publicly available network server or other readily accessible means, 503 | then you must either (1) cause the Corresponding Source to be so 504 | available, or (2) arrange to deprive yourself of the benefit of the 505 | patent license for this particular work, or (3) arrange, in a manner 506 | consistent with the requirements of this License, to extend the patent 507 | license to downstream recipients. "Knowingly relying" means you have 508 | actual knowledge that, but for the patent license, your conveying the 509 | covered work in a country, or your recipient's use of the covered work 510 | in a country, would infringe one or more identifiable patents in that 511 | country that you have reason to believe are valid. 512 | 513 | If, pursuant to or in connection with a single transaction or 514 | arrangement, you convey, or propagate by procuring conveyance of, a 515 | covered work, and grant a patent license to some of the parties 516 | receiving the covered work authorizing them to use, propagate, modify 517 | or convey a specific copy of the covered work, then the patent license 518 | you grant is automatically extended to all recipients of the covered 519 | work and works based on it. 520 | 521 | A patent license is "discriminatory" if it does not include within 522 | the scope of its coverage, prohibits the exercise of, or is 523 | conditioned on the non-exercise of one or more of the rights that are 524 | specifically granted under this License. You may not convey a covered 525 | work if you are a party to an arrangement with a third party that is 526 | in the business of distributing software, under which you make payment 527 | to the third party based on the extent of your activity of conveying 528 | the work, and under which the third party grants, to any of the 529 | parties who would receive the covered work from you, a discriminatory 530 | patent license (a) in connection with copies of the covered work 531 | conveyed by you (or copies made from those copies), or (b) primarily 532 | for and in connection with specific products or compilations that 533 | contain the covered work, unless you entered into that arrangement, 534 | or that patent license was granted, prior to 28 March 2007. 535 | 536 | Nothing in this License shall be construed as excluding or limiting 537 | any implied license or other defenses to infringement that may 538 | otherwise be available to you under applicable patent law. 539 | 540 | 12. No Surrender of Others' Freedom. 541 | 542 | If conditions are imposed on you (whether by court order, agreement or 543 | otherwise) that contradict the conditions of this License, they do not 544 | excuse you from the conditions of this License. If you cannot convey a 545 | covered work so as to satisfy simultaneously your obligations under this 546 | License and any other pertinent obligations, then as a consequence you may 547 | not convey it at all. For example, if you agree to terms that obligate you 548 | to collect a royalty for further conveying from those to whom you convey 549 | the Program, the only way you could satisfy both those terms and this 550 | License would be to refrain entirely from conveying the Program. 551 | 552 | 13. Use with the GNU Affero General Public License. 553 | 554 | Notwithstanding any other provision of this License, you have 555 | permission to link or combine any covered work with a work licensed 556 | under version 3 of the GNU Affero General Public License into a single 557 | combined work, and to convey the resulting work. The terms of this 558 | License will continue to apply to the part which is the covered work, 559 | but the special requirements of the GNU Affero General Public License, 560 | section 13, concerning interaction through a network will apply to the 561 | combination as such. 562 | 563 | 14. Revised Versions of this License. 564 | 565 | The Free Software Foundation may publish revised and/or new versions of 566 | the GNU General Public License from time to time. Such new versions will 567 | be similar in spirit to the present version, but may differ in detail to 568 | address new problems or concerns. 569 | 570 | Each version is given a distinguishing version number. If the 571 | Program specifies that a certain numbered version of the GNU General 572 | Public License "or any later version" applies to it, you have the 573 | option of following the terms and conditions either of that numbered 574 | version or of any later version published by the Free Software 575 | Foundation. If the Program does not specify a version number of the 576 | GNU General Public License, you may choose any version ever published 577 | by the Free Software Foundation. 578 | 579 | If the Program specifies that a proxy can decide which future 580 | versions of the GNU General Public License can be used, that proxy's 581 | public statement of acceptance of a version permanently authorizes you 582 | to choose that version for the Program. 583 | 584 | Later license versions may give you additional or different 585 | permissions. However, no additional obligations are imposed on any 586 | author or copyright holder as a result of your choosing to follow a 587 | later version. 588 | 589 | 15. Disclaimer of Warranty. 590 | 591 | THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY 592 | APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT 593 | HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY 594 | OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, 595 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 596 | PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM 597 | IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF 598 | ALL NECESSARY SERVICING, REPAIR OR CORRECTION. 599 | 600 | 16. Limitation of Liability. 601 | 602 | IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING 603 | WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS 604 | THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY 605 | GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE 606 | USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF 607 | DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD 608 | PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), 609 | EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF 610 | SUCH DAMAGES. 611 | 612 | 17. Interpretation of Sections 15 and 16. 613 | 614 | If the disclaimer of warranty and limitation of liability provided 615 | above cannot be given local legal effect according to their terms, 616 | reviewing courts shall apply local law that most closely approximates 617 | an absolute waiver of all civil liability in connection with the 618 | Program, unless a warranty or assumption of liability accompanies a 619 | copy of the Program in return for a fee. 620 | 621 | END OF TERMS AND CONDITIONS 622 | 623 | How to Apply These Terms to Your New Programs 624 | 625 | If you develop a new program, and you want it to be of the greatest 626 | possible use to the public, the best way to achieve this is to make it 627 | free software which everyone can redistribute and change under these terms. 628 | 629 | To do so, attach the following notices to the program. It is safest 630 | to attach them to the start of each source file to most effectively 631 | state the exclusion of warranty; and each file should have at least 632 | the "copyright" line and a pointer to where the full notice is found. 633 | 634 | 635 | Copyright (C) 636 | 637 | This program is free software: you can redistribute it and/or modify 638 | it under the terms of the GNU General Public License as published by 639 | the Free Software Foundation, either version 3 of the License, or 640 | (at your option) any later version. 641 | 642 | This program is distributed in the hope that it will be useful, 643 | but WITHOUT ANY WARRANTY; without even the implied warranty of 644 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 645 | GNU General Public License for more details. 646 | 647 | You should have received a copy of the GNU General Public License 648 | along with this program. If not, see . 649 | 650 | Also add information on how to contact you by electronic and paper mail. 651 | 652 | If the program does terminal interaction, make it output a short 653 | notice like this when it starts in an interactive mode: 654 | 655 | Copyright (C) 656 | This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. 657 | This is free software, and you are welcome to redistribute it 658 | under certain conditions; type `show c' for details. 659 | 660 | The hypothetical commands `show w' and `show c' should show the appropriate 661 | parts of the General Public License. Of course, your program's commands 662 | might be different; for a GUI interface, you would use an "about box". 663 | 664 | You should also get your employer (if you work as a programmer) or school, 665 | if any, to sign a "copyright disclaimer" for the program, if necessary. 666 | For more information on this, and how to apply and follow the GNU GPL, see 667 | . 668 | 669 | The GNU General Public License does not permit incorporating your program 670 | into proprietary programs. If your program is a subroutine library, you 671 | may consider it more useful to permit linking proprietary applications with 672 | the library. If this is what you want to do, use the GNU Lesser General 673 | Public License instead of this License. But first, please read 674 | . 675 | -------------------------------------------------------------------------------- /Readme.md: -------------------------------------------------------------------------------- 1 |
2 | 3 |

TUI for lobste.rs website

4 | 5 |
6 | 7 | ## 🚀 Installation 8 | 9 | ### 📥 Binary release 10 | 11 | You can download the pre-built binaries from the release page [release page](https://github.com/pythops/lobtui/releases) 12 | 13 | ### 📦 crates.io 14 | 15 | You can install `lobtui` from [crates.io](https://crates.io/crates/lobtui) 16 | 17 | ```shell 18 | cargo install lobtui 19 | ``` 20 | 21 | ## 🐧 Arch Linux 22 | 23 | You can install [`lobtui`](https://aur.archlinux.org/packages/lobtui) from the AUR using your favorite [AUR helper](https://wiki.archlinux.org/title/AUR_helpers). For example: 24 | 25 | ```shell 26 | paru -S lobtui 27 | ``` 28 | 29 | ## 🚩 NetBSD 30 | 31 | You can install [`lobtui`](https://pkgsrc.se/news/lobtui) from the official repositories. 32 | 33 | ```shell 34 | pkgin install lobtui 35 | ``` 36 | 37 | ### ⚒️ Build from source 38 | 39 | Run the following command: 40 | 41 | ```shell 42 | git clone https://github.com/pythops/lobtui 43 | cd lobtui 44 | cargo build --release 45 | ``` 46 | 47 | Then run `strip` to reduce the size of the binary 48 | 49 | ```shell 50 | strip target/release/lobtui 51 | ``` 52 | 53 | This will produce an executable file at `target/release/lobtui` that you can copy to a directory in your `$PATH`. 54 | 55 | ## 🪄 Usage 56 | 57 | `j` or `Down` : scroll down. 58 | 59 | `k` or `Up`: scroll up. 60 | 61 | `gg`: go to the top of the page. 62 | 63 | `G`: go the bottom of the page. 64 | 65 | `n`: next page. 66 | 67 | `p`: previous page. 68 | 69 | `r`: reload the current page. 70 | 71 | `o`: open the highlighted story in the browser. 72 | 73 | ## ⚖️ License 74 | 75 | GPLv3 76 | -------------------------------------------------------------------------------- /Release.md: -------------------------------------------------------------------------------- 1 | ## v0.3.1 - 2025-05-16 2 | 3 | - Fix broken vote selector 4 | 5 | ## v0.3 - 2024-09-04 6 | 7 | - Bump ratatui version 8 | - Better scrolling 9 | - Add colors 10 | 11 | ## v0.2 - 20/02/2024 12 | 13 | ### Added 14 | 15 | - Add `gg` and `G` keybindings 16 | - Reset the scroll position when changing pages 17 | 18 | ## v0.1 - 17/01/2024 19 | 20 | First release 🎉 21 | -------------------------------------------------------------------------------- /assets/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/pythops/lobtui/a532914df7c1b2e6d06b4ce29f3087b0fb0f272a/assets/logo.png -------------------------------------------------------------------------------- /src/app.rs: -------------------------------------------------------------------------------- 1 | use color_eyre::eyre::Result; 2 | use crossterm::event::KeyCode; 3 | use ratatui::{style::Stylize, text::Text, widgets::ListState}; 4 | use reqwest::Client; 5 | use std::error; 6 | 7 | use scraper::{Html, Selector, error::SelectorErrorKind}; 8 | 9 | use crate::notifications::Notification; 10 | 11 | use ratatui::{ 12 | Frame, 13 | layout::{Alignment, Constraint, Direction, Layout}, 14 | style::{Color, Modifier, Style}, 15 | text::{Line, Span}, 16 | widgets::{Block, List, ListItem, Paragraph, Wrap}, 17 | }; 18 | 19 | pub type AppResult = Result>; 20 | 21 | #[derive(Debug)] 22 | pub struct App { 23 | pub running: bool, 24 | pub client: Client, 25 | pub previous_key: KeyCode, 26 | pub stories: Vec, 27 | pub page: usize, 28 | pub notifications: Vec, 29 | pub state: ListState, 30 | pub window_height: usize, 31 | } 32 | 33 | #[derive(Debug)] 34 | pub struct Story { 35 | pub title: String, 36 | pub link: String, 37 | pub author: String, 38 | pub tags: Vec, 39 | pub votes: usize, 40 | pub comment_count: String, 41 | pub comment_link: String, 42 | } 43 | 44 | impl App { 45 | pub async fn new() -> Result { 46 | static APP_USER_AGENT: &str = 47 | concat!(env!("CARGO_PKG_NAME"), "/", env!("CARGO_PKG_VERSION"),); 48 | 49 | let client = reqwest::Client::builder() 50 | .user_agent(APP_USER_AGENT) 51 | .build()?; 52 | 53 | let response = client 54 | .get("https://lobste.rs/") 55 | .send() 56 | .await? 57 | .text() 58 | .await?; 59 | 60 | let stories = App::parse(response).unwrap(); 61 | 62 | let mut state = ListState::default(); 63 | 64 | if !stories.is_empty() { 65 | state.select(Some(0)); 66 | } 67 | 68 | Ok(Self { 69 | running: true, 70 | client, 71 | previous_key: KeyCode::Null, 72 | stories, 73 | page: 1, 74 | notifications: Vec::new(), 75 | state, 76 | window_height: 0, 77 | }) 78 | } 79 | 80 | pub fn parse(page: String) -> Result, SelectorErrorKind<'static>> { 81 | let mut stories: Vec = Vec::new(); 82 | 83 | let html = Html::parse_fragment(&page); 84 | let story_selector = Selector::parse(r#"div[class="story_liner h-entry"]"#)?; 85 | let title_selector = Selector::parse(r#"a[class="u-url"]"#)?; 86 | let tags_selector = Selector::parse(r#"span[class="tags"]"#)?; 87 | let author_selector = Selector::parse("a.u-author")?; 88 | let votes_selector = Selector::parse("a.upvoter")?; 89 | let comments_selector = Selector::parse(r#"span[class="comments_label"]"#)?; 90 | 91 | for story in html.select(&story_selector) { 92 | let story_html = Html::parse_fragment(&story.html()); 93 | 94 | let title_span = story_html.select(&title_selector).next().unwrap(); 95 | 96 | let title: String = title_span.text().collect(); 97 | 98 | let link: Option<&str> = title_span.value().attr("href"); 99 | 100 | let tags: Vec = story_html 101 | .select(&tags_selector) 102 | .next() 103 | .unwrap() 104 | .text() 105 | .filter(|t| t.trim() != "") 106 | .map(|t| t.to_string()) 107 | .collect(); 108 | 109 | let author: String = story_html 110 | .select(&author_selector) 111 | .next() 112 | .unwrap() 113 | .text() 114 | .collect(); 115 | 116 | let votes: String = story_html 117 | .select(&votes_selector) 118 | .next() 119 | .unwrap() 120 | .text() 121 | .collect(); 122 | 123 | let comment_span = 124 | Html::parse_fragment(&story_html.select(&comments_selector).next().unwrap().html()); 125 | 126 | let comment_span = comment_span 127 | .select(&Selector::parse("a").unwrap()) 128 | .next() 129 | .unwrap(); 130 | 131 | let comment_count = comment_span.text().collect::(); 132 | let comment_count = comment_count 133 | .split_whitespace() 134 | .next() 135 | .unwrap() 136 | .parse::() 137 | .unwrap_or(0); 138 | 139 | let comment_link = comment_span.value().attr("href"); 140 | 141 | stories.push(Story { 142 | title, 143 | link: link.unwrap_or_default().to_string(), 144 | author, 145 | tags: tags.to_owned(), 146 | votes: votes.parse::().unwrap_or_default(), 147 | comment_count: comment_count.to_string(), 148 | comment_link: comment_link.unwrap_or_default().to_string(), 149 | }); 150 | } 151 | 152 | Ok(stories) 153 | } 154 | 155 | pub fn render(&mut self, frame: &mut Frame) { 156 | let (body_block, footer_block) = { 157 | let chunks = Layout::default() 158 | .direction(Direction::Vertical) 159 | .constraints([Constraint::Min(1), Constraint::Length(3)].as_ref()) 160 | .split(frame.area()); 161 | (chunks[0], chunks[1]) 162 | }; 163 | 164 | // footer 165 | let footer = Paragraph::new(Text::from(format!("Page {}", self.page)).bold()) 166 | .alignment(Alignment::Center) 167 | .wrap(Wrap { trim: true }); 168 | 169 | // Body 170 | 171 | // 2 because two lines for an item list 172 | self.window_height = body_block.height as usize / 2; 173 | 174 | let items: Vec = self 175 | .stories 176 | .iter() 177 | .enumerate() 178 | .map(|(index, story)| { 179 | let first_line = vec![ 180 | Span::styled( 181 | format!("{}. ▲ ", index + 1), 182 | Style::default().fg(Color::Gray), 183 | ), 184 | Span::styled( 185 | story.title.clone(), 186 | Style::default().add_modifier(Modifier::BOLD).blue(), 187 | ), 188 | ]; 189 | 190 | let second_line = vec![ 191 | Span::styled( 192 | format!(" {}", story.votes), 193 | Style::default().fg(Color::Gray), 194 | ), 195 | Span::raw(" votes. By "), 196 | Span::styled( 197 | story.author.clone(), 198 | Style::default() 199 | .fg(Color::Gray) 200 | .add_modifier(Modifier::ITALIC), 201 | ), 202 | Span::raw(". "), 203 | Span::styled( 204 | story.comment_count.clone(), 205 | Style::default().fg(Color::Gray), 206 | ), 207 | Span::raw(" comments. Tags: "), 208 | Span::styled( 209 | story.tags.join(", "), 210 | Style::default() 211 | .fg(Color::Yellow) 212 | .add_modifier(Modifier::ITALIC), 213 | ), 214 | ]; 215 | 216 | ListItem::new(vec![ 217 | Line::from(first_line), 218 | Line::from(second_line).gray(), 219 | Line::from(""), 220 | ]) 221 | }) 222 | .collect(); 223 | 224 | let list = List::new(items.to_vec()) 225 | .highlight_style(Style::new().bg(Color::DarkGray)) 226 | .block(Block::default()) 227 | .style(Style::default()); 228 | 229 | frame.render_stateful_widget(list, body_block, &mut self.state); 230 | frame.render_widget(footer, footer_block); 231 | } 232 | 233 | pub async fn refresh(&mut self) -> Result<(), Box> { 234 | let response = self 235 | .client 236 | .get(format!("https://lobste.rs/page/{}", self.page)) 237 | .send() 238 | .await? 239 | .text() 240 | .await?; 241 | 242 | match App::parse(response) { 243 | Ok(stories) => self.stories = stories, 244 | Err(_) => return Err("Can not parse the response".into()), 245 | } 246 | 247 | Ok(()) 248 | } 249 | 250 | pub fn open(&mut self) -> Result<()> { 251 | let story = &self.stories[self.state.selected().unwrap()]; 252 | open::that(&story.link)?; 253 | Ok(()) 254 | } 255 | 256 | pub fn quit(&mut self) { 257 | self.running = false; 258 | } 259 | 260 | pub fn tick(&mut self) { 261 | self.notifications.retain(|n| n.ttl > 0); 262 | self.notifications.iter_mut().for_each(|n| n.ttl -= 1); 263 | } 264 | } 265 | -------------------------------------------------------------------------------- /src/event.rs: -------------------------------------------------------------------------------- 1 | use std::time::Duration; 2 | 3 | use crossterm::event::{Event as CrosstermEvent, KeyEvent, MouseEvent}; 4 | use futures::{FutureExt, StreamExt}; 5 | use tokio::sync::mpsc; 6 | 7 | use crate::{app::AppResult, notifications::Notification}; 8 | 9 | #[derive(Clone, Debug)] 10 | pub enum Event { 11 | Tick, 12 | Key(KeyEvent), 13 | Mouse(MouseEvent), 14 | Resize(u16, u16), 15 | Notification(Notification), 16 | } 17 | 18 | #[allow(dead_code)] 19 | #[derive(Debug)] 20 | pub struct EventHandler { 21 | pub sender: mpsc::UnboundedSender, 22 | receiver: mpsc::UnboundedReceiver, 23 | handler: tokio::task::JoinHandle<()>, 24 | } 25 | 26 | impl EventHandler { 27 | pub fn new(tick_rate: u64) -> Self { 28 | let tick_rate = Duration::from_millis(tick_rate); 29 | let (sender, receiver) = mpsc::unbounded_channel(); 30 | let _sender = sender.clone(); 31 | let handler = tokio::spawn(async move { 32 | let mut reader = crossterm::event::EventStream::new(); 33 | let mut tick = tokio::time::interval(tick_rate); 34 | loop { 35 | let tick_delay = tick.tick(); 36 | let crossterm_event = reader.next().fuse(); 37 | tokio::select! { 38 | _ = tick_delay => { 39 | _sender.send(Event::Tick).unwrap(); 40 | } 41 | Some(Ok(evt)) = crossterm_event => { 42 | match evt { 43 | CrosstermEvent::Key(key) => { 44 | if key.kind == crossterm::event::KeyEventKind::Press { 45 | _sender.send(Event::Key(key)).unwrap(); 46 | } 47 | }, 48 | CrosstermEvent::Mouse(mouse) => { 49 | _sender.send(Event::Mouse(mouse)).unwrap(); 50 | }, 51 | CrosstermEvent::Resize(x, y) => { 52 | _sender.send(Event::Resize(x, y)).unwrap(); 53 | }, 54 | CrosstermEvent::FocusLost => { 55 | }, 56 | CrosstermEvent::FocusGained => { 57 | }, 58 | CrosstermEvent::Paste(_) => { 59 | }, 60 | } 61 | } 62 | }; 63 | } 64 | }); 65 | Self { 66 | sender, 67 | receiver, 68 | handler, 69 | } 70 | } 71 | 72 | pub async fn next(&mut self) -> AppResult { 73 | self.receiver 74 | .recv() 75 | .await 76 | .ok_or(Box::new(std::io::Error::other("This is an IO error"))) 77 | } 78 | } 79 | -------------------------------------------------------------------------------- /src/handler.rs: -------------------------------------------------------------------------------- 1 | use crate::{ 2 | app::{App, AppResult}, 3 | event::Event, 4 | notifications::{Notification, NotificationLevel}, 5 | }; 6 | use tokio::sync::mpsc; 7 | 8 | use crossterm::event::{KeyCode, KeyEvent, KeyModifiers}; 9 | 10 | pub async fn handle_key_events( 11 | key_event: KeyEvent, 12 | app: &mut App, 13 | sender: mpsc::UnboundedSender, 14 | ) -> AppResult<()> { 15 | match key_event.code { 16 | KeyCode::Esc | KeyCode::Char('q') => { 17 | app.quit(); 18 | } 19 | 20 | KeyCode::Char('c') | KeyCode::Char('C') => { 21 | if key_event.modifiers == KeyModifiers::CONTROL { 22 | app.quit(); 23 | } 24 | } 25 | 26 | KeyCode::Char('G') => { 27 | *app.state.offset_mut() = (app.stories.len() - 1).saturating_sub(app.window_height); 28 | app.state.select(Some(app.stories.len() - 1)); 29 | } 30 | 31 | KeyCode::Char('g') => { 32 | if app.previous_key == KeyCode::Char('g') { 33 | *app.state.offset_mut() = 0; 34 | app.state.select(Some(0)); 35 | } 36 | } 37 | 38 | KeyCode::Char('j') | KeyCode::Down => { 39 | let i = match app.state.selected() { 40 | Some(i) => { 41 | if i < app.window_height { 42 | i + 1 43 | } else if i == app.window_height - 1 { 44 | *app.state.offset_mut() += 1; 45 | i + 1 46 | } else { 47 | i 48 | } 49 | } 50 | None => 0, 51 | }; 52 | 53 | app.state.select(Some(i)); 54 | } 55 | 56 | KeyCode::Char('k') | KeyCode::Up => { 57 | let i = match app.state.selected() { 58 | Some(i) => { 59 | if i > app.state.offset() { 60 | i - 1 61 | } else if i == app.state.offset() && app.state.offset() > 0 { 62 | *app.state.offset_mut() -= 1; 63 | i - 1 64 | } else { 65 | 0 66 | } 67 | } 68 | None => 0, 69 | }; 70 | 71 | app.state.select(Some(i)); 72 | } 73 | 74 | KeyCode::Char('r') => { 75 | match app.refresh().await { 76 | Ok(_) => Notification::send( 77 | "Page refreshed".to_string(), 78 | NotificationLevel::Info, 79 | sender, 80 | )?, 81 | Err(e) => Notification::send(e.to_string(), NotificationLevel::Error, sender)?, 82 | }; 83 | } 84 | 85 | KeyCode::Char('n') => { 86 | app.page = app.page.saturating_add(1); 87 | if let Err(e) = app.refresh().await { 88 | Notification::send(e.to_string(), NotificationLevel::Error, sender)?; 89 | app.page = app.page.saturating_sub(1); 90 | } 91 | app.state.select(Some(0)); 92 | } 93 | 94 | KeyCode::Char('p') => { 95 | if app.page > 1 { 96 | app.page = app.page.saturating_sub(1); 97 | 98 | if let Err(e) = app.refresh().await { 99 | Notification::send(e.to_string(), NotificationLevel::Error, sender)?; 100 | app.page = app.page.saturating_add(1); 101 | } 102 | app.state.select(Some(0)); 103 | } 104 | } 105 | 106 | KeyCode::Char('o') => { 107 | if let Err(e) = app.open() { 108 | Notification::send(e.to_string(), NotificationLevel::Error, sender)?; 109 | } 110 | } 111 | 112 | _ => {} 113 | } 114 | 115 | app.previous_key = key_event.code; 116 | 117 | Ok(()) 118 | } 119 | -------------------------------------------------------------------------------- /src/lib.rs: -------------------------------------------------------------------------------- 1 | pub mod app; 2 | 3 | pub mod event; 4 | 5 | pub mod ui; 6 | 7 | pub mod tui; 8 | 9 | pub mod handler; 10 | 11 | pub mod notifications; 12 | -------------------------------------------------------------------------------- /src/main.rs: -------------------------------------------------------------------------------- 1 | use clap::{Command, crate_description, crate_version}; 2 | use lobtui::app::{App, AppResult}; 3 | use lobtui::event::{Event, EventHandler}; 4 | use lobtui::handler::handle_key_events; 5 | use lobtui::tui::Tui; 6 | use ratatui::Terminal; 7 | use ratatui::backend::CrosstermBackend; 8 | use std::io; 9 | 10 | #[tokio::main] 11 | async fn main() -> AppResult<()> { 12 | Command::new("lobtui") 13 | .about(crate_description!()) 14 | .version(crate_version!()) 15 | .get_matches(); 16 | 17 | let mut app = App::new().await?; 18 | 19 | let backend = CrosstermBackend::new(io::stdout()); 20 | let terminal = Terminal::new(backend)?; 21 | let events = EventHandler::new(1_000); 22 | 23 | let mut tui = Tui::new(terminal, events); 24 | tui.init()?; 25 | 26 | while app.running { 27 | tui.draw(&mut app)?; 28 | match tui.events.next().await? { 29 | Event::Tick => app.tick(), 30 | Event::Key(key_event) => { 31 | handle_key_events(key_event, &mut app, tui.events.sender.clone()).await? 32 | } 33 | Event::Notification(notification) => { 34 | app.notifications.push(notification); 35 | } 36 | _ => {} 37 | } 38 | } 39 | 40 | tui.exit()?; 41 | Ok(()) 42 | } 43 | -------------------------------------------------------------------------------- /src/notifications.rs: -------------------------------------------------------------------------------- 1 | use ratatui::{ 2 | Frame, 3 | layout::{Alignment, Constraint, Direction, Layout, Rect}, 4 | style::{Color, Modifier, Style}, 5 | text::{Line, Text}, 6 | widgets::{Block, BorderType, Borders, Clear, Paragraph, Wrap}, 7 | }; 8 | use tokio::sync::mpsc; 9 | 10 | use crate::{app::AppResult, event::Event}; 11 | 12 | #[derive(Debug, Clone)] 13 | pub struct Notification { 14 | pub message: String, 15 | pub level: NotificationLevel, 16 | pub ttl: u8, 17 | } 18 | 19 | #[derive(Debug, Clone)] 20 | pub enum NotificationLevel { 21 | Error, 22 | Warning, 23 | Info, 24 | } 25 | 26 | impl Notification { 27 | pub fn render(&self, index: usize, frame: &mut Frame) { 28 | let (color, title) = match self.level { 29 | NotificationLevel::Info => (Color::Green, "Info"), 30 | NotificationLevel::Warning => (Color::Yellow, "Warning"), 31 | NotificationLevel::Error => (Color::Red, "Error"), 32 | }; 33 | 34 | let mut text = Text::from(vec![ 35 | Line::from(title).style(Style::new().fg(color).add_modifier(Modifier::BOLD)), 36 | ]); 37 | 38 | text.extend(Text::from(self.message.as_str())); 39 | 40 | let notification_height = text.height() as u16 + 2; 41 | let notification_width = text.width() as u16 + 4; 42 | 43 | let block = Paragraph::new(text) 44 | .alignment(Alignment::Center) 45 | .wrap(Wrap { trim: false }) 46 | .block( 47 | Block::default() 48 | .borders(Borders::ALL) 49 | .style(Style::default()) 50 | .border_type(BorderType::Thick) 51 | .border_style(Style::default().fg(color)), 52 | ); 53 | 54 | let area = notification_rect( 55 | index as u16, 56 | notification_height, 57 | notification_width, 58 | frame.area(), 59 | ); 60 | 61 | frame.render_widget(Clear, area); 62 | frame.render_widget(block, area); 63 | } 64 | 65 | pub fn send( 66 | message: String, 67 | level: NotificationLevel, 68 | sender: mpsc::UnboundedSender, 69 | ) -> AppResult<()> { 70 | let notif = Notification { 71 | message, 72 | level, 73 | ttl: 3, 74 | }; 75 | 76 | sender.send(Event::Notification(notif))?; 77 | 78 | Ok(()) 79 | } 80 | } 81 | 82 | pub fn notification_rect(offset: u16, height: u16, width: u16, r: Rect) -> Rect { 83 | let popup_layout = Layout::default() 84 | .direction(Direction::Vertical) 85 | .constraints( 86 | [ 87 | Constraint::Length(height * offset), 88 | Constraint::Length(height), 89 | Constraint::Min(1), 90 | ] 91 | .as_ref(), 92 | ) 93 | .split(r); 94 | 95 | Layout::default() 96 | .direction(Direction::Horizontal) 97 | .constraints( 98 | [ 99 | Constraint::Min(1), 100 | Constraint::Length(width), 101 | Constraint::Length(2), 102 | ] 103 | .as_ref(), 104 | ) 105 | .split(popup_layout[1])[1] 106 | } 107 | -------------------------------------------------------------------------------- /src/tui.rs: -------------------------------------------------------------------------------- 1 | use crate::app::{App, AppResult}; 2 | use crate::event::EventHandler; 3 | use crate::ui; 4 | use crossterm::event::{DisableMouseCapture, EnableMouseCapture}; 5 | use crossterm::terminal::{self, EnterAlternateScreen, LeaveAlternateScreen}; 6 | use ratatui::Terminal; 7 | use ratatui::backend::Backend; 8 | use std::io; 9 | use std::panic; 10 | 11 | #[derive(Debug)] 12 | pub struct Tui { 13 | terminal: Terminal, 14 | pub events: EventHandler, 15 | } 16 | 17 | impl Tui { 18 | pub fn new(terminal: Terminal, events: EventHandler) -> Self { 19 | Self { terminal, events } 20 | } 21 | 22 | pub fn init(&mut self) -> AppResult<()> { 23 | terminal::enable_raw_mode()?; 24 | crossterm::execute!(io::stdout(), EnterAlternateScreen, EnableMouseCapture)?; 25 | 26 | let panic_hook = panic::take_hook(); 27 | panic::set_hook(Box::new(move |panic| { 28 | Self::reset().expect("failed to reset the terminal"); 29 | panic_hook(panic); 30 | })); 31 | 32 | self.terminal.hide_cursor()?; 33 | self.terminal.clear()?; 34 | Ok(()) 35 | } 36 | 37 | pub fn draw(&mut self, app: &mut App) -> AppResult<()> { 38 | self.terminal.draw(|frame| ui::render(app, frame))?; 39 | Ok(()) 40 | } 41 | 42 | fn reset() -> AppResult<()> { 43 | terminal::disable_raw_mode()?; 44 | crossterm::execute!(io::stdout(), LeaveAlternateScreen, DisableMouseCapture)?; 45 | Ok(()) 46 | } 47 | 48 | pub fn exit(&mut self) -> AppResult<()> { 49 | Self::reset()?; 50 | self.terminal.show_cursor()?; 51 | Ok(()) 52 | } 53 | } 54 | -------------------------------------------------------------------------------- /src/ui.rs: -------------------------------------------------------------------------------- 1 | use ratatui::Frame; 2 | 3 | use crate::app::App; 4 | 5 | pub fn render(app: &mut App, frame: &mut Frame) { 6 | app.render(frame); 7 | 8 | for (index, notification) in app.notifications.iter().enumerate() { 9 | notification.render(index, frame); 10 | } 11 | } 12 | --------------------------------------------------------------------------------