diff --git a/Cargo.lock b/Cargo.lock index 8b1b3831..e9161d6f 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -4,18 +4,18 @@ version = 4 [[package]] name = "addr2line" -version = "0.17.0" +version = "0.24.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9ecd88a8c8378ca913a680cd98f0f13ac67383d35993f86c90a70e3f137816b" +checksum = "dfbe277e56a376000877090da837660b4427aad530e3028d44e0bffe4f89a1c1" dependencies = [ "gimli", ] [[package]] -name = "adler" -version = "1.0.2" +name = "adler2" +version = "2.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" +checksum = "512761e0bb2578dd7380c6baaa0f4ce03e84f95e960231d1dec8bf4d7d6e2627" [[package]] name = "aho-corasick" @@ -43,9 +43,9 @@ dependencies = [ [[package]] name = "anstream" -version = "0.6.15" +version = "0.6.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64e15c1ab1f89faffbf04a634d5e1962e9074f2741eef6d97f3c4e322426d526" +checksum = "8acc5369981196006228e28809f761875c0327210a891e941f4c683b3a99529b" dependencies = [ "anstyle", "anstyle-parse", @@ -58,43 +58,43 @@ dependencies = [ [[package]] name = "anstyle" -version = "1.0.8" +version = "1.0.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1bec1de6f59aedf83baf9ff929c98f2ad654b97c9510f4e70cf6f661d49fd5b1" +checksum = "55cc3b69f167a1ef2e161439aa98aed94e6028e5f9a59be9a6ffb47aef1651f9" [[package]] name = "anstyle-parse" -version = "0.2.5" +version = "0.2.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eb47de1e80c2b463c735db5b217a0ddc39d612e7ac9e2e96a5aed1f57616c1cb" +checksum = "3b2d16507662817a6a20a9ea92df6652ee4f94f914589377d69f3b21bc5798a9" dependencies = [ "utf8parse", ] [[package]] name = "anstyle-query" -version = "1.1.1" +version = "1.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d36fc52c7f6c869915e99412912f22093507da8d9e942ceaf66fe4b7c14422a" +checksum = "79947af37f4177cfead1110013d678905c37501914fba0efea834c3fe9a8d60c" dependencies = [ - "windows-sys 0.52.0", + "windows-sys 0.59.0", ] [[package]] name = "anstyle-wincon" -version = "3.0.4" +version = "3.0.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5bf74e1b6e971609db8ca7a9ce79fd5768ab6ae46441c572e46cf596f59e57f8" +checksum = "2109dbce0e72be3ec00bed26e6a7479ca384ad226efdd66db8fa2e3a38c83125" dependencies = [ "anstyle", - "windows-sys 0.52.0", + "windows-sys 0.59.0", ] [[package]] name = "anyhow" -version = "1.0.75" +version = "1.0.95" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4668cab20f66d8d020e1fbc0ebe47217433c1b6c8f2040faf858554e394ace6" +checksum = "34ac096ce696dc2fcabef30516bb13c0a68a11d30131d3df6f04711467681b04" [[package]] name = "async-recursion" @@ -104,18 +104,18 @@ checksum = "3b43422f69d8ff38f95f1b2bb76517c91589a924d1559a0e935d7c8ce0274c11" dependencies = [ "proc-macro2", "quote", - "syn 2.0.82", + "syn 2.0.96", ] [[package]] name = "async-trait" -version = "0.1.83" +version = "0.1.85" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "721cae7de5c34fbb2acd27e21e6d2cf7b886dce0c27388d46c4e6c47ea4318dd" +checksum = "3f934833b4b7233644e5848f235df3f57ed8c80f1528a26c3dfa13d2147fa056" dependencies = [ "proc-macro2", "quote", - "syn 2.0.82", + "syn 2.0.96", ] [[package]] @@ -135,7 +135,7 @@ dependencies = [ "manyhow", "proc-macro2", "quote", - "syn 2.0.82", + "syn 2.0.96", ] [[package]] @@ -151,7 +151,7 @@ dependencies = [ "proc-macro2", "quote", "quote-use", - "syn 2.0.82", + "syn 2.0.96", ] [[package]] @@ -162,17 +162,17 @@ checksum = "ace50bade8e6234aa140d9a2f552bbee1db4d353f69b8217bc503490fc1a9f26" [[package]] name = "backtrace" -version = "0.3.65" +version = "0.3.74" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "11a17d453482a265fd5f8479f2a3f405566e6ca627837aaddb85af8b1ab8ef61" +checksum = "8d82cb332cdfaed17ae235a638438ac4d4839913cc2af585c3c6746e8f8bee1a" dependencies = [ "addr2line", - "cc", "cfg-if", "libc", "miniz_oxide", "object", "rustc-demangle", + "windows-targets 0.52.6", ] [[package]] @@ -192,15 +192,9 @@ dependencies = [ [[package]] name = "bitflags" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" - -[[package]] -name = "bitflags" -version = "2.4.0" +version = "2.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b4682ae6287fcf752ecaabbfcc7b6f9b72aa33933dc23a554d853aea8eea8635" +checksum = "1be3f42a67d6d345ecd59f675f3f012d6974981560836e938c22b424b85ce1be" [[package]] name = "block-buffer" @@ -225,9 +219,9 @@ checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" [[package]] name = "bytes" -version = "1.7.1" +version = "1.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8318a53db07bb3f8dca91a600466bdb3f2eaadeedfdbcf02e1accbad9271ba50" +checksum = "325918d6fe32f23b19878fe4b34794ae41fc19ddbe53b10571a4874d44ffd39b" [[package]] name = "camino" @@ -237,9 +231,9 @@ checksum = "8b96ec4966b5813e2c0507c1f86115c8c5abaadc3980879c3424042a02fd1ad3" [[package]] name = "cc" -version = "1.1.18" +version = "1.2.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b62ac837cdb5cb22e10a256099b4fc502b1dfe560cb282963a974d7abd80e476" +checksum = "ad0cf6e91fde44c773c6ee7ec6bba798504641a8bc2eb7e37a04ffbf4dfaa55a" dependencies = [ "shlex", ] @@ -252,9 +246,9 @@ checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" [[package]] name = "chrono" -version = "0.4.38" +version = "0.4.39" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a21f936df1771bf62b77f047b726c4625ff2e8aa607c01ec06e5a05bd8463401" +checksum = "7e36cc9d416881d2e24f9a963be5fb1cd90966419ac844274161d10488b3e825" dependencies = [ "android-tzdata", "iana-time-zone", @@ -294,9 +288,9 @@ dependencies = [ [[package]] name = "clap" -version = "4.5.20" +version = "4.5.26" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b97f376d85a664d5837dbae44bf546e6477a679ff6610010f17276f686d867e8" +checksum = "a8eb5e908ef3a6efbe1ed62520fb7287959888c88485abe072543190ecc66783" dependencies = [ "clap_builder", "clap_derive", @@ -304,9 +298,9 @@ dependencies = [ [[package]] name = "clap_builder" -version = "4.5.20" +version = "4.5.26" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19bc80abd44e4bed93ca373a0704ccbd1b710dc5749406201bb018272808dc54" +checksum = "96b01801b5fc6a0a232407abc821660c9c6d25a1cafc0d4f85f29fb8d9afc121" dependencies = [ "anstream", "anstyle", @@ -316,21 +310,21 @@ dependencies = [ [[package]] name = "clap_derive" -version = "4.5.18" +version = "4.5.24" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ac6a0c7b1a9e9a5186361f67dfa1b88213572f427fb9ab038efb2bd8c582dab" +checksum = "54b755194d6389280185988721fffba69495eed5ee9feeee9a599b53db80318c" dependencies = [ "heck", "proc-macro2", "quote", - "syn 2.0.82", + "syn 2.0.96", ] [[package]] name = "clap_lex" -version = "0.7.2" +version = "0.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1462739cb27611015575c0c11df5df7601141071f07518d56fcc1be504cbec97" +checksum = "f46ad14479a25103f283c0f10005961cf086d8dc42205bb44c46ac563475dca6" [[package]] name = "collection_literals" @@ -340,18 +334,17 @@ checksum = "186dce98367766de751c42c4f03970fc60fc012296e706ccbb9d5df9b6c1e271" [[package]] name = "colorchoice" -version = "1.0.2" +version = "1.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3fd119d74b830634cea2a0f58bbd0d54540518a14397557951e79340abc28c0" +checksum = "5b63caa9aa9397e2d9480a9b13673856c78d8ac123288526c37d7839f2a86990" [[package]] name = "config" -version = "0.14.0" +version = "0.14.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7328b20597b53c2454f0b1919720c25c7339051c02b72b7e05409e00b14132be" +checksum = "68578f196d2a33ff61b27fae256c3164f65e36382648e30666dde05b8cc9dfdf" dependencies = [ "convert_case", - "lazy_static", "nom", "pathdiff", "serde", @@ -370,18 +363,18 @@ dependencies = [ [[package]] name = "const_format" -version = "0.2.33" +version = "0.2.34" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "50c655d81ff1114fb0dcdea9225ea9f0cc712a6f8d189378e82bdf62a473a64b" +checksum = "126f97965c8ad46d6d9163268ff28432e8f6a1196a55578867832e3049df63dd" dependencies = [ "const_format_proc_macros", ] [[package]] name = "const_format_proc_macros" -version = "0.2.33" +version = "0.2.34" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eff1a44b93f47b1bac19a27932f5c591e43d1ba357ee4f61526c8a25603f0eb1" +checksum = "1d57c2eccfb16dbac1f4e61e206105db5820c9d26c3c472bc17c774259ef7744" dependencies = [ "proc-macro2", "quote", @@ -415,9 +408,9 @@ checksum = "773648b94d0e5d620f64f280777445740e61fe701025087ec8b57f45c791888b" [[package]] name = "cpufeatures" -version = "0.2.14" +version = "0.2.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "608697df725056feaccfa42cffdaeeec3fccc4ffc38358ecd19b243e716a78e0" +checksum = "16b80225097f2e5ae4e7179dd2266824648f3e2f49d9134d584b76389d31c4c3" dependencies = [ "libc", ] @@ -459,7 +452,7 @@ checksum = "62d671cc41a825ebabc75757b62d3d168c577f9149b2d49ece1dad1f72119d25" dependencies = [ "proc-macro2", "quote", - "syn 2.0.82", + "syn 2.0.96", ] [[package]] @@ -493,6 +486,17 @@ dependencies = [ "windows-sys 0.48.0", ] +[[package]] +name = "displaydoc" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.96", +] + [[package]] name = "drain_filter_polyfill" version = "0.1.3" @@ -516,72 +520,25 @@ dependencies = [ [[package]] name = "equivalent" -version = "1.0.0" +version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "88bffebc5d80432c9b140ee17875ff173a8ab62faad5b257da912bd2f6c1c0a1" +checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" [[package]] name = "errno" -version = "0.3.9" +version = "0.3.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "534c5cf6194dfab3db3242765c03bbe257cf92f22b38f6bc0c58d59108a820ba" +checksum = "33d852cb9b869c2a9b3df2f71a3074817f01e1844f839a144f5fcef059a4eb5d" dependencies = [ "libc", - "windows-sys 0.52.0", + "windows-sys 0.59.0", ] [[package]] name = "fastrand" -version = "2.1.1" +version = "2.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e8c02a5121d4ea3eb16a80748c74f5549a5665e4c21333c6098f283870fbdea6" - -[[package]] -name = "file-explorer" -version = "0.0.0" -dependencies = [ - "anyhow", - "chrono", - "mime_guess", - "tokio", -] - -[[package]] -name = "file-explorer-plugin" -version = "0.0.0" -dependencies = [ - "anyhow", - "async-trait", - "bytes", - "chrono", - "file-explorer", - "file-explorer-proto", - "file-explorer-ui", - "futures", - "http 1.1.0", - "http-body-util", - "http-server-plugin", - "humansize", - "hyper", - "mime_guess", - "multer", - "percent-encoding", - "rust-embed", - "serde", - "serde_json", - "tokio", - "tokio-util", - "tracing", - "tracing-subscriber", -] - -[[package]] -name = "file-explorer-proto" -version = "0.0.0" -dependencies = [ - "chrono", - "serde", -] +checksum = "37909eebbb50d72f9059c3b6d82c0463f2ff062c9e95845c43a6c9c0355411be" [[package]] name = "file-explorer-ui" @@ -589,14 +546,13 @@ version = "0.0.0" dependencies = [ "anyhow", "chrono", - "file-explorer-proto", "gloo", "gloo-file", "leptos", "leptos_meta", "leptos_router", "reqwest", - "rust-embed", + "serde", "wasm-bindgen", "wasm-bindgen-test", "web-sys", @@ -688,7 +644,7 @@ checksum = "162ee34ebcb7c64a8abebc059ce0fee27c2262618d7b60ed8faf72fef13c3650" dependencies = [ "proc-macro2", "quote", - "syn 2.0.82", + "syn 2.0.96", ] [[package]] @@ -746,9 +702,9 @@ dependencies = [ [[package]] name = "gimli" -version = "0.26.1" +version = "0.31.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78cc372d058dcf6d5ecd98510e7fbc9e5aec4d21de70f65fea8fecebcd881bd4" +checksum = "07e28edb80900c19c28f1072f2e8aeca7fa06b23cd4169cefe1af5aa3260783f" [[package]] name = "gloo" @@ -862,7 +818,7 @@ dependencies = [ "futures-core", "futures-sink", "gloo-utils", - "http 1.1.0", + "http 1.2.0", "js-sys", "pin-project", "serde", @@ -949,21 +905,21 @@ dependencies = [ "proc-macro-crate", "proc-macro2", "quote", - "syn 2.0.82", + "syn 2.0.96", ] [[package]] name = "h2" -version = "0.4.6" +version = "0.4.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "524e8ac6999421f49a846c2d4411f337e53497d8ec55d67753beffa43c5d9205" +checksum = "ccae279728d634d083c00f6099cb58f01cc99c145b84b8be2f6c74618d79922e" dependencies = [ "atomic-waker", "bytes", "fnv", "futures-core", "futures-sink", - "http 1.1.0", + "http 1.2.0", "indexmap", "slab", "tokio", @@ -989,9 +945,9 @@ checksum = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1" [[package]] name = "hashbrown" -version = "0.15.0" +version = "0.15.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e087f84d4f86bf4b218b927129862374b72199ae7d8657835f1e89000eea4fb" +checksum = "bf151400ff0baff5465007dd2f3e717f3fe502074ca563069ce3a6629d07b289" [[package]] name = "heck" @@ -999,12 +955,6 @@ version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" -[[package]] -name = "hermit-abi" -version = "0.3.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" - [[package]] name = "html-escape" version = "0.2.13" @@ -1027,9 +977,9 @@ dependencies = [ [[package]] name = "http" -version = "1.1.0" +version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21b9ddb458710bc376481b842f5da65cdf31522de232c1ca8146abce2a358258" +checksum = "f16ca2af56261c99fba8bac40a10251ce8188205a4c448fbb745a2e4daa76fea" dependencies = [ "bytes", "fnv", @@ -1043,7 +993,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1efedce1fb8e6913f23e0c92de8e62cd5b772a67e7b3946df930a62566c93184" dependencies = [ "bytes", - "http 1.1.0", + "http 1.2.0", ] [[package]] @@ -1054,7 +1004,7 @@ checksum = "793429d76616a256bcb62c2a2ec2bed781c8307e797e2598c50010f2bee2544f" dependencies = [ "bytes", "futures-util", - "http 1.1.0", + "http 1.2.0", "http-body", "pin-project-lite", ] @@ -1066,16 +1016,23 @@ dependencies = [ "anyhow", "async-trait", "bytes", + "chrono", "clap", "dirs", - "http 1.1.0", + "http 1.2.0", "http-body-util", - "http-server-plugin", "hyper", "hyper-util", "libloading", "local-ip-address", + "mime_guess", + "multer", + "percent-encoding", + "rust-embed", + "serde", + "serde_json", "tokio", + "tokio-util", "tower", "tower-http", "tower-layer", @@ -1083,27 +1040,11 @@ dependencies = [ "tracing-subscriber", ] -[[package]] -name = "http-server-plugin" -version = "1.0.0-draft+1" -dependencies = [ - "anyhow", - "async-trait", - "bytes", - "http 1.1.0", - "http-body-util", - "hyper", - "rustc_version", - "serde", - "tokio", - "toml", -] - [[package]] name = "httparse" -version = "1.8.0" +version = "1.9.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d897f394bad6a705d5f4104762e116a75639e470d80901eed05a860a95cb1904" +checksum = "7d71d3574edd2771538b901e6549113b4006ece66150fb69c0fb6d9a2adae946" [[package]] name = "httpdate" @@ -1111,26 +1052,17 @@ version = "1.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "df3b46402a9d5adb4c86a0cf463f42e19994e3ee891101b1841f30a545cb49a9" -[[package]] -name = "humansize" -version = "2.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6cb51c9a029ddc91b07a787f1d86b53ccfa49b0e86688c946ebe8d3555685dd7" -dependencies = [ - "libm", -] - [[package]] name = "hyper" -version = "1.4.1" +version = "1.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "50dfd22e0e76d0f662d429a5f80fcaf3855009297eab6a0a9f8543834744ba05" +checksum = "256fb8d4bd6413123cc9d91832d78325c48ff41677595be797d90f42969beae0" dependencies = [ "bytes", "futures-channel", "futures-util", "h2", - "http 1.1.0", + "http 1.2.0", "http-body", "httparse", "httpdate", @@ -1143,12 +1075,12 @@ dependencies = [ [[package]] name = "hyper-rustls" -version = "0.27.3" +version = "0.27.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "08afdbb5c31130e3034af566421053ab03787c640246a446327f550d11bcb333" +checksum = "2d191583f3da1305256f22463b9bb0471acad48a4e534a5218b9963e9c1f59b2" dependencies = [ "futures-util", - "http 1.1.0", + "http 1.2.0", "hyper", "hyper-util", "rustls", @@ -1176,14 +1108,14 @@ dependencies = [ [[package]] name = "hyper-util" -version = "0.1.9" +version = "0.1.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "41296eb09f183ac68eec06e03cdbea2e759633d4067b2f6552fc2e009bcad08b" +checksum = "df2dcfbe0677734ab2f3ffa7fa7bfd4706bfdc1ef393f2ee30184aed67e631b4" dependencies = [ "bytes", "futures-channel", "futures-util", - "http 1.1.0", + "http 1.2.0", "http-body", "hyper", "pin-project-lite", @@ -1216,24 +1148,153 @@ dependencies = [ "cc", ] +[[package]] +name = "icu_collections" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "db2fa452206ebee18c4b5c2274dbf1de17008e874b4dc4f0aea9d01ca79e4526" +dependencies = [ + "displaydoc", + "yoke", + "zerofrom", + "zerovec", +] + +[[package]] +name = "icu_locid" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "13acbb8371917fc971be86fc8057c41a64b521c184808a698c02acc242dbf637" +dependencies = [ + "displaydoc", + "litemap", + "tinystr", + "writeable", + "zerovec", +] + +[[package]] +name = "icu_locid_transform" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "01d11ac35de8e40fdeda00d9e1e9d92525f3f9d887cdd7aa81d727596788b54e" +dependencies = [ + "displaydoc", + "icu_locid", + "icu_locid_transform_data", + "icu_provider", + "tinystr", + "zerovec", +] + +[[package]] +name = "icu_locid_transform_data" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fdc8ff3388f852bede6b579ad4e978ab004f139284d7b28715f773507b946f6e" + +[[package]] +name = "icu_normalizer" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "19ce3e0da2ec68599d193c93d088142efd7f9c5d6fc9b803774855747dc6a84f" +dependencies = [ + "displaydoc", + "icu_collections", + "icu_normalizer_data", + "icu_properties", + "icu_provider", + "smallvec", + "utf16_iter", + "utf8_iter", + "write16", + "zerovec", +] + +[[package]] +name = "icu_normalizer_data" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8cafbf7aa791e9b22bec55a167906f9e1215fd475cd22adfcf660e03e989516" + +[[package]] +name = "icu_properties" +version = "1.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "93d6020766cfc6302c15dbbc9c8778c37e62c14427cb7f6e601d849e092aeef5" +dependencies = [ + "displaydoc", + "icu_collections", + "icu_locid_transform", + "icu_properties_data", + "icu_provider", + "tinystr", + "zerovec", +] + +[[package]] +name = "icu_properties_data" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "67a8effbc3dd3e4ba1afa8ad918d5684b8868b3b26500753effea8d2eed19569" + +[[package]] +name = "icu_provider" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6ed421c8a8ef78d3e2dbc98a973be2f3770cb42b606e3ab18d6237c4dfde68d9" +dependencies = [ + "displaydoc", + "icu_locid", + "icu_provider_macros", + "stable_deref_trait", + "tinystr", + "writeable", + "yoke", + "zerofrom", + "zerovec", +] + +[[package]] +name = "icu_provider_macros" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1ec89e9337638ecdc08744df490b221a7399bf8d164eb52a665454e60e075ad6" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.96", +] + [[package]] name = "idna" -version = "0.5.0" +version = "1.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "634d9b1461af396cad843f47fdba5597a4f9e6ddd4bfb6ff5d85028c25cb12f6" +checksum = "686f825264d630750a544639377bae737628043f20d38bbc029e8f29ea968a7e" dependencies = [ - "unicode-bidi", - "unicode-normalization", + "idna_adapter", + "smallvec", + "utf8_iter", +] + +[[package]] +name = "idna_adapter" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "daca1df1c957320b2cf139ac61e7bd64fed304c5040df000a745aa1de3b4ef71" +dependencies = [ + "icu_normalizer", + "icu_properties", ] [[package]] name = "indexmap" -version = "2.6.0" +version = "2.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "707907fe3c25f5424cce2cb7e1cbcafee6bdbe735ca90ef77c29e84591e5b9da" +checksum = "62f822373a4fe84d4bb149bf54e584a7f4abec90e072ed49cda0edea5b95471f" dependencies = [ "equivalent", - "hashbrown 0.15.0", + "hashbrown 0.15.2", ] [[package]] @@ -1244,9 +1305,12 @@ checksum = "71dd52191aae121e8611f1e8dc3e324dd0dd1dee1e6dd91d10ee07a3cfb4d9d8" [[package]] name = "inventory" -version = "0.3.15" +version = "0.3.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f958d3d68f4167080a18141e10381e7634563984a537f2a49a30fd8e53ac5767" +checksum = "3b31349d02fe60f80bbbab1a9402364cad7460626d6030494b08ac4a2075bf81" +dependencies = [ + "rustversion", +] [[package]] name = "ipnet" @@ -1271,16 +1335,17 @@ dependencies = [ [[package]] name = "itoa" -version = "1.0.1" +version = "1.0.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1aab8fc367588b89dcee83ab0fd66b72b50b72fa1904d7095045ace2b0c81c35" +checksum = "d75a2a4b1b190afb6f5425f10f6a8f959d2ea0b9c2b1d79553551850539e4674" [[package]] name = "js-sys" -version = "0.3.72" +version = "0.3.77" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a88f1bda2bd75b0452a14784937d796722fdebfe50df998aeb3f0b7603019a9" +checksum = "1cfaf33c695fc6e08064efbc1f72ec937429614f25eef83af942d0e227c3a28f" dependencies = [ + "once_cell", "wasm-bindgen", ] @@ -1367,7 +1432,7 @@ dependencies = [ "quote", "rstml", "serde", - "syn 2.0.82", + "syn 2.0.96", "walkdir", ] @@ -1389,7 +1454,7 @@ dependencies = [ "quote", "rstml", "server_fn_macro", - "syn 2.0.82", + "syn 2.0.96", "tracing", "uuid", ] @@ -1479,33 +1544,27 @@ dependencies = [ [[package]] name = "libc" -version = "0.2.158" +version = "0.2.169" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8adc4bb1803a324070e64a98ae98f38934d91957a99cfb3a43dcbc01bc56439" +checksum = "b5aba8db14291edd000dfcc4d620c7ebfb122c613afb886ca8803fa4e128a20a" [[package]] name = "libloading" -version = "0.8.5" +version = "0.8.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4979f22fdb869068da03c9f7528f8297c6fd2606bc3a4affe42e6a823fdb8da4" +checksum = "fc2f4eb4bc735547cfed7c0a4922cbd04a4655978c09b54f1f7b228750664c34" dependencies = [ "cfg-if", "windows-targets 0.52.6", ] -[[package]] -name = "libm" -version = "0.2.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ec2a862134d2a7d32d7983ddcdd1c4923530833c9f2ea1a44fc5fa473989058" - [[package]] name = "libredox" version = "0.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c0ff37bd590ca25063e35af745c343cb7a0271906fb7b37e4813e8f79f00268d" dependencies = [ - "bitflags 2.4.0", + "bitflags", "libc", ] @@ -1521,9 +1580,15 @@ dependencies = [ [[package]] name = "linux-raw-sys" -version = "0.4.14" +version = "0.4.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d26c52dbd32dccf2d10cac7725f8eae5296885fb5703b261f7d0a0739ec807ab" + +[[package]] +name = "litemap" +version = "0.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78b3ae25bc7c8c38cec158d1f2757ee79e9b3740fbc7ccf0e59e4b08d793fa89" +checksum = "4ee93343901ab17bd981295f2cf0026d4ad018c7c31ba84549a4ddbb47a45104" [[package]] name = "local-ip-address" @@ -1562,7 +1627,7 @@ dependencies = [ "manyhow-macros", "proc-macro2", "quote", - "syn 2.0.82", + "syn 2.0.96", ] [[package]] @@ -1587,9 +1652,9 @@ dependencies = [ [[package]] name = "memchr" -version = "2.5.0" +version = "2.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2dffe52ecf27772e601905b7522cb4ef790d2cc203488bbd0e2fe85fcb74566d" +checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" [[package]] name = "mime" @@ -1609,9 +1674,9 @@ dependencies = [ [[package]] name = "minicov" -version = "0.3.5" +version = "0.3.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c71e683cd655513b99affab7d317deb690528255a0d5f717f1024093c12b169" +checksum = "f27fe9f1cc3c22e1687f9446c2083c4c5fc7f0bcf1c7a86bdbded14985895b4b" dependencies = [ "cc", "walkdir", @@ -1625,20 +1690,19 @@ checksum = "68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79a" [[package]] name = "miniz_oxide" -version = "0.5.1" +version = "0.8.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d2b29bd4bc3f33391105ebee3589c19197c4271e3e5a9ec9bfe8127eeff8f082" +checksum = "4ffbe83022cedc1d264172192511ae958937694cd57ce297164951b8b3568394" dependencies = [ - "adler", + "adler2", ] [[package]] name = "mio" -version = "1.0.2" +version = "1.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "80e04d1dcff3aae0704555fe5fee3bcfaf3d1fdf8a7e521d5b9d2b42acb52cec" +checksum = "2886843bf800fba2e3377cff24abf6379b4c4d5c6681eaf9ea5b0d15090450bd" dependencies = [ - "hermit-abi", "libc", "wasi", "windows-sys 0.52.0", @@ -1653,7 +1717,7 @@ dependencies = [ "bytes", "encoding_rs", "futures-util", - "http 1.1.0", + "http 1.2.0", "httparse", "memchr", "mime", @@ -1734,9 +1798,9 @@ dependencies = [ [[package]] name = "object" -version = "0.28.3" +version = "0.36.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "40bec70ba014595f99f7aa110b84331ffe1ee9aece7fe6f387cc7e3ecda4d456" +checksum = "62948e14d923ea95ea2c7c86c71013138b66525b86bdc08d2dcc262bdb497b87" dependencies = [ "memchr", ] @@ -1753,9 +1817,9 @@ dependencies = [ [[package]] name = "once_cell" -version = "1.18.0" +version = "1.20.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd8b5dd2ae5ed71462c540258bedcb51965123ad7e7ccf4b9a8cafaa4a63576d" +checksum = "1261fe7e33c73b354eab43b1273a57c8f967d0391e80353e51f764ac02cf6775" [[package]] name = "openssl" @@ -1763,7 +1827,7 @@ version = "0.10.68" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6174bc48f102d208783c2c84bf931bb75927a617866870de8a4ea85597f871f5" dependencies = [ - "bitflags 2.4.0", + "bitflags", "cfg-if", "foreign-types", "libc", @@ -1780,7 +1844,7 @@ checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" dependencies = [ "proc-macro2", "quote", - "syn 2.0.82", + "syn 2.0.96", ] [[package]] @@ -1850,9 +1914,9 @@ checksum = "57c0d7b74b563b49d38dae00a0c37d4d6de9b432382b2892f0574ddcae73fd0a" [[package]] name = "pathdiff" -version = "0.2.2" +version = "0.2.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d61c5ce1153ab5b689d0c074c4e7fc613e942dfb7dd9eea5ab202d2ad91fe361" +checksum = "df94ce210e5bc13cb6651479fa48d14f601d9858cfe0467f43ae157023b938d3" [[package]] name = "percent-encoding" @@ -1862,29 +1926,29 @@ checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" [[package]] name = "pin-project" -version = "1.1.6" +version = "1.1.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "baf123a161dde1e524adf36f90bc5d8d3462824a9c43553ad07a8183161189ec" +checksum = "1e2ec53ad785f4d35dac0adea7f7dc6f1bb277ad84a680c7afefeae05d1f5916" dependencies = [ "pin-project-internal", ] [[package]] name = "pin-project-internal" -version = "1.1.6" +version = "1.1.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4502d8515ca9f32f1fb543d987f63d95a14934883db45bdb48060b6b69257f8" +checksum = "d56a66c0c55993aa927429d0f8a0abfd74f084e4d9c192cffed01e418d83eefb" dependencies = [ "proc-macro2", "quote", - "syn 2.0.82", + "syn 2.0.96", ] [[package]] name = "pin-project-lite" -version = "0.2.14" +version = "0.2.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bda66fc9667c18cb2758a2ac84d1167245054bcf85d5d1aaa6923f45801bdd02" +checksum = "3b3cff922bd51709b605d9ead9aa71031d81447142d828eb4a6eba76fe619f9b" [[package]] name = "pin-utils" @@ -1911,12 +1975,12 @@ checksum = "953ec861398dccce10c670dfeaf3ec4911ca479e9c02154b3a215178c5f566f2" [[package]] name = "prettyplease" -version = "0.2.24" +version = "0.2.27" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "910d41a655dac3b764f1ade94821093d3610248694320cd072303a8eedcf221d" +checksum = "483f8c21f64f3ea09fe0f30f5d48c3e8eefe5dac9129f0075f76593b4c1da705" dependencies = [ "proc-macro2", - "syn 2.0.82", + "syn 2.0.96", ] [[package]] @@ -1997,9 +2061,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.87" +version = "1.0.93" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b3e4daa0dcf6feba26f985457cdf104d4b4256fc5a09547140f3631bb076b19a" +checksum = "60946a68e5f9d28b0dc1c21bb8a97ee7d018a8b322fa57838ba31cc878e22d99" dependencies = [ "unicode-ident", ] @@ -2012,16 +2076,16 @@ checksum = "af066a9c399a26e020ada66a034357a868728e72cd426f3adcd35f80d88d88c8" dependencies = [ "proc-macro2", "quote", - "syn 2.0.82", + "syn 2.0.96", "version_check", "yansi", ] [[package]] name = "quote" -version = "1.0.37" +version = "1.0.38" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5b9d34b8991d19d98081b46eacdd8eb58c6f2b201139f7c5f643cc155a633af" +checksum = "0e4dccaaaf89514f546c693ddc140f729f958c247918a13380cccc6078391acc" dependencies = [ "proc-macro2", ] @@ -2045,16 +2109,16 @@ dependencies = [ "proc-macro-utils 0.10.0", "proc-macro2", "quote", - "syn 2.0.82", + "syn 2.0.96", ] [[package]] name = "redox_syscall" -version = "0.5.7" +version = "0.5.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b6dfecf2c74bce2466cabf93f6664d6998a69eb21e39f4207930065b27b771f" +checksum = "03a862b389f93e68874fbf580b9de08dd02facb9a788ebadaf4a3fd33cf58834" dependencies = [ - "bitflags 2.4.0", + "bitflags", ] [[package]] @@ -2070,14 +2134,14 @@ dependencies = [ [[package]] name = "regex" -version = "1.9.4" +version = "1.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "12de2eff854e5fa4b1295edd650e227e9d8fb0c9e90b12e7f36d6a6811791a29" +checksum = "b544ef1b4eac5dc2db33ea63606ae9ffcfac26c1416a2806ae0bf5f56b201191" dependencies = [ "aho-corasick", "memchr", - "regex-automata 0.3.7", - "regex-syntax 0.7.5", + "regex-automata 0.4.9", + "regex-syntax 0.8.5", ] [[package]] @@ -2091,13 +2155,13 @@ dependencies = [ [[package]] name = "regex-automata" -version = "0.3.7" +version = "0.4.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49530408a136e16e5b486e883fbb6ba058e8e4e8ae6621a77b048b314336e629" +checksum = "809e8dc61f6de73b46c85f4c96486310fe304c434cfa43669d7b40f711150908" dependencies = [ "aho-corasick", "memchr", - "regex-syntax 0.7.5", + "regex-syntax 0.8.5", ] [[package]] @@ -2108,15 +2172,15 @@ checksum = "f162c6dd7b008981e4d40210aca20b4bd0f9b60ca9271061b07f78537722f2e1" [[package]] name = "regex-syntax" -version = "0.7.5" +version = "0.8.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dbb5fb1acd8a1a18b3dd5be62d25485eb770e05afb408a9627d14d451bae12da" +checksum = "2b15c43186be67a4fd63bee50d0303afffcef381492ebe2c5d87f324e1b8815c" [[package]] name = "reqwest" -version = "0.12.9" +version = "0.12.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a77c62af46e79de0a562e1a9849205ffcb7fc1238876e9bd743357570e04046f" +checksum = "43e734407157c3c2034e0258f5e4473ddb361b1e85f95a66690d67264d7cd1da" dependencies = [ "base64", "bytes", @@ -2124,7 +2188,7 @@ dependencies = [ "futures-core", "futures-util", "h2", - "http 1.1.0", + "http 1.2.0", "http-body", "http-body-util", "hyper", @@ -2143,10 +2207,11 @@ dependencies = [ "serde", "serde_json", "serde_urlencoded", - "sync_wrapper 1.0.1", + "sync_wrapper", "system-configuration", "tokio", "tokio-native-tls", + "tower", "tower-service", "url", "wasm-bindgen", @@ -2179,7 +2244,7 @@ dependencies = [ "proc-macro2", "proc-macro2-diagnostics", "quote", - "syn 2.0.82", + "syn 2.0.96", "syn_derive", "thiserror", ] @@ -2204,7 +2269,7 @@ dependencies = [ "proc-macro2", "quote", "rust-embed-utils", - "syn 2.0.82", + "syn 2.0.96", "walkdir", ] @@ -2220,9 +2285,9 @@ dependencies = [ [[package]] name = "rustc-demangle" -version = "0.1.21" +version = "0.1.24" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ef03e0a2b150c7a90d01faf6254c9c48a41e95fb2a8c2ac1c6f0d2b9aefc342" +checksum = "719b953e2095829ee67db738b3bfa9fa368c94900df327b3f07fe6e794d2fe1f" [[package]] name = "rustc-hash" @@ -2230,33 +2295,24 @@ version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "08d43f7aa6b08d49f382cde6a7982047c3426db949b1424bc4b7ec9ae12c6ce2" -[[package]] -name = "rustc_version" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cfcb3a22ef46e85b45de6ee7e79d063319ebb6594faafcf1c225ea92ab6e9b92" -dependencies = [ - "semver", -] - [[package]] name = "rustix" -version = "0.38.37" +version = "0.38.43" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8acb788b847c24f28525660c4d7758620a7210875711f79e7f663cc152726811" +checksum = "a78891ee6bf2340288408954ac787aa063d8e8817e9f53abb37c695c6d834ef6" dependencies = [ - "bitflags 2.4.0", + "bitflags", "errno", "libc", "linux-raw-sys", - "windows-sys 0.52.0", + "windows-sys 0.59.0", ] [[package]] name = "rustls" -version = "0.23.16" +version = "0.23.21" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eee87ff5d9b36712a58574e12e9f0ea80f915a5b0ac518d322b24a465617925e" +checksum = "8f287924602bf649d949c63dc8ac8b235fa5387d394020705b80c4eb597ce5b8" dependencies = [ "once_cell", "rustls-pki-types", @@ -2276,9 +2332,9 @@ dependencies = [ [[package]] name = "rustls-pki-types" -version = "1.10.0" +version = "1.10.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "16f1201b3c9a7ee8039bcadc17b7e605e2945b27eee7631788c1bd2b0643674b" +checksum = "d2bf47e6ff922db3825eb750c4e2ff784c6ff8fb9e13046ef6a1d1c5401b0b37" [[package]] name = "rustls-webpki" @@ -2293,9 +2349,9 @@ dependencies = [ [[package]] name = "rustversion" -version = "1.0.18" +version = "1.0.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0e819f2bc632f285be6d7cd36e25940d45b2391dd6d9b939e79de557f7014248" +checksum = "f7c45b9784283f1b2e7fb61b42047c2fd678ef0960d4f6f1eba131594cc369d4" [[package]] name = "ryu" @@ -2314,9 +2370,9 @@ dependencies = [ [[package]] name = "schannel" -version = "0.1.26" +version = "0.1.27" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "01227be5826fa0690321a2ba6c5cd57a19cf3f6a09e76973b58e61de6ab9d1c1" +checksum = "1f29ebaa345f945cec9fbbc532eb307f0fdad8161f281b6369539c8d84876b3d" dependencies = [ "windows-sys 0.59.0", ] @@ -2335,11 +2391,11 @@ checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" [[package]] name = "security-framework" -version = "2.10.0" +version = "2.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "770452e37cad93e0a50d5abc3990d2bc351c36d0328f86cefec2f2fb206eaef6" +checksum = "897b2245f0b511c87893af39b033e5ca9cce68824c4d7e7630b5a1d339658d02" dependencies = [ - "bitflags 1.3.2", + "bitflags", "core-foundation", "core-foundation-sys", "libc", @@ -2348,9 +2404,9 @@ dependencies = [ [[package]] name = "security-framework-sys" -version = "2.12.0" +version = "2.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea4a292869320c0272d7bc55a5a6aafaff59b4f63404a003887b679a2e05b4b6" +checksum = "49db231d56a190491cb4aeda9527f1ad45345af50b0851622a7adb8c03b01c32" dependencies = [ "core-foundation-sys", "libc", @@ -2358,15 +2414,9 @@ dependencies = [ [[package]] name = "self_cell" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d369a96f978623eb3dc28807c4852d6cc617fed53da5d3c400feff1ef34a714a" - -[[package]] -name = "semver" -version = "1.0.23" +version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61697e0a1c7e512e84a621326239844a24d8207b4669b41bc18b32ea5cbf988b" +checksum = "c2fdfc24bc566f839a2da4c4295b82db7d25a24253867d5c64355abb5799bdbe" [[package]] name = "send_wrapper" @@ -2379,9 +2429,9 @@ dependencies = [ [[package]] name = "serde" -version = "1.0.210" +version = "1.0.217" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c8e3592472072e6e22e0a54d5904d9febf8508f65fb8552499a1abc7d1078c3a" +checksum = "02fc4265df13d6fa1d00ecff087228cc0a2b5f3c0e87e258d8b94a156e984c70" dependencies = [ "serde_derive", ] @@ -2399,20 +2449,20 @@ dependencies = [ [[package]] name = "serde_derive" -version = "1.0.210" +version = "1.0.217" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "243902eda00fad750862fc144cea25caca5e20d615af0a81bee94ca738f1df1f" +checksum = "5a9bf7cf98d04a2b28aead066b7496853d4779c9cc183c440dbac457641e19a0" dependencies = [ "proc-macro2", "quote", - "syn 2.0.82", + "syn 2.0.96", ] [[package]] name = "serde_json" -version = "1.0.128" +version = "1.0.135" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ff5456707a1de34e7e37f2a6fd3d3f808c318259cbd01ab6377795054b483d8" +checksum = "2b0d7ba2887406110130a978386c4e1befb98c674b4fba677954e4db976630d9" dependencies = [ "itoa", "memchr", @@ -2484,7 +2534,7 @@ dependencies = [ "dashmap", "futures", "gloo-net 0.6.0", - "http 1.1.0", + "http 1.2.0", "js-sys", "once_cell", "send_wrapper", @@ -2511,7 +2561,7 @@ dependencies = [ "convert_case", "proc-macro2", "quote", - "syn 2.0.82", + "syn 2.0.96", "xxhash-rust", ] @@ -2522,7 +2572,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7f2aa8119b558a17992e0ac1fd07f080099564f24532858811ce04f742542440" dependencies = [ "server_fn_macro", - "syn 2.0.82", + "syn 2.0.96", ] [[package]] @@ -2553,18 +2603,21 @@ checksum = "0fda2ff0d084019ba4d7c6f371c95d8fd75ce3524c3cb8fb653a3023f6323e64" [[package]] name = "signal-hook-registry" -version = "1.4.0" +version = "1.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e51e73328dc4ac0c7ccbda3a494dfa03df1de2f46018127f60c693f2648455b0" +checksum = "a9e9e0b4211b72e7b8b6e85c807d36c212bdb33ea8587f7569562a84df5465b1" dependencies = [ "libc", ] [[package]] name = "slab" -version = "0.4.6" +version = "0.4.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eb703cfe953bccee95685111adeedb76fabe4e97549a58d16f03ea7b9367bb32" +checksum = "8f92a496fb766b417c996b9c5e57daf2f7ad3b0bebe1ccfca4856390e3d3bb67" +dependencies = [ + "autocfg", +] [[package]] name = "slotmap" @@ -2584,9 +2637,9 @@ checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "socket2" -version = "0.5.7" +version = "0.5.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce305eb0b4296696835b71df73eb912e0f1ffd2556a501fcede6e0c50349191c" +checksum = "c970269d99b64e60ec3bd6ad27270092a5394c4e309314b18ae3fe575695fbe8" dependencies = [ "libc", "windows-sys 0.52.0", @@ -2598,6 +2651,12 @@ version = "0.9.8" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6980e8d7511241f8acf4aebddbb1ff938df5eebe98691418c4468d0b72a96a67" +[[package]] +name = "stable_deref_trait" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a8f112729512f8e442d81f95a8a7ddf2b7c6b8a1a6f509a95864142b30cab2d3" + [[package]] name = "strsim" version = "0.11.1" @@ -2623,9 +2682,9 @@ dependencies = [ [[package]] name = "syn" -version = "2.0.82" +version = "2.0.96" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "83540f837a8afc019423a8edb95b52a8effe46957ee402287f4292fae35be021" +checksum = "d5d0adab1ae378d7f53bdebc67a39f1f151407ef230f0ce2883572f5d8985c80" dependencies = [ "proc-macro2", "quote", @@ -2641,22 +2700,27 @@ dependencies = [ "proc-macro-error", "proc-macro2", "quote", - "syn 2.0.82", + "syn 2.0.96", ] [[package]] name = "sync_wrapper" -version = "0.1.2" +version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2047c6ded9c721764247e62cd3b03c09ffc529b2ba5b10ec482ae507a4a70160" +checksum = "0bf256ce5efdfa370213c1dabab5935a12e49f2c58d15e9eac2870d3b4f27263" +dependencies = [ + "futures-core", +] [[package]] -name = "sync_wrapper" -version = "1.0.1" +name = "synstructure" +version = "0.13.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7065abeca94b6a8a577f9bd45aa0867a2238b74e8eb67cf10d492bc39351394" +checksum = "c8af7666ab7b6390ab78131fb5b0fce11d6b7a6951602017c35fa82800708971" dependencies = [ - "futures-core", + "proc-macro2", + "quote", + "syn 2.0.96", ] [[package]] @@ -2665,7 +2729,7 @@ version = "0.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3c879d448e9d986b661742763247d3693ed13609438cf3d006f51f5368a5ba6b" dependencies = [ - "bitflags 2.4.0", + "bitflags", "core-foundation", "system-configuration-sys", ] @@ -2682,34 +2746,36 @@ dependencies = [ [[package]] name = "tempfile" -version = "3.10.1" +version = "3.15.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85b77fafb263dd9d05cbeac119526425676db3784113aa9295c88498cbf8bff1" +checksum = "9a8a559c81686f576e8cd0290cd2a24a2a9ad80c98b3478856500fcbd7acd704" dependencies = [ "cfg-if", "fastrand", + "getrandom", + "once_cell", "rustix", - "windows-sys 0.52.0", + "windows-sys 0.59.0", ] [[package]] name = "thiserror" -version = "1.0.55" +version = "1.0.69" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e3de26b0965292219b4287ff031fcba86837900fe9cd2b34ea8ad893c0953d2" +checksum = "b6aaf5339b578ea85b50e080feb250a3e8ae8cfcdff9a461c9ec2904bc923f52" dependencies = [ "thiserror-impl", ] [[package]] name = "thiserror-impl" -version = "1.0.55" +version = "1.0.69" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "268026685b2be38d7103e9e507c938a1fcb3d7e6eb15e87870b617bf37b6d581" +checksum = "4fee6c4efc90059e10f81e6d42c60a18f76588c3d74cb83a0b242a2b6c7504c1" dependencies = [ "proc-macro2", "quote", - "syn 2.0.82", + "syn 2.0.96", ] [[package]] @@ -2723,31 +2789,25 @@ dependencies = [ ] [[package]] -name = "tinyvec" -version = "1.8.0" +name = "tinystr" +version = "0.7.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "445e881f4f6d382d5f27c034e25eb92edd7c784ceab92a0937db7f2e9471b938" +checksum = "9117f5d4db391c1cf6927e7bea3db74b9a1c1add8f7eda9ffd5364f40f57b82f" dependencies = [ - "tinyvec_macros", + "displaydoc", + "zerovec", ] -[[package]] -name = "tinyvec_macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" - [[package]] name = "tokio" -version = "1.40.0" +version = "1.43.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2b070231665d27ad9ec9b8df639893f46727666c6767db40317fbe920a5d998" +checksum = "3d61fa4ffa3de412bfea335c6ecff681de2b609ba3c77ef3e00e521813a9ed9e" dependencies = [ "backtrace", "bytes", "libc", "mio", - "parking_lot", "pin-project-lite", "signal-hook-registry", "socket2", @@ -2757,13 +2817,13 @@ dependencies = [ [[package]] name = "tokio-macros" -version = "2.4.0" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "693d596312e88961bc67d7f1f97af8a70227d9f90c31bba5806eec004978d752" +checksum = "6e06d43f1345a3bcd39f6a56dbb7dcab2ba47e68e8ac134855e7e2bdbaf8cab8" dependencies = [ "proc-macro2", "quote", - "syn 2.0.82", + "syn 2.0.96", ] [[package]] @@ -2778,20 +2838,19 @@ dependencies = [ [[package]] name = "tokio-rustls" -version = "0.26.0" +version = "0.26.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c7bc40d0e5a97695bb96e27995cd3a08538541b0a846f65bba7a359f36700d4" +checksum = "5f6d0975eaace0cf0fcadee4e4aaa5da15b5c079146f2cffb67c113be122bf37" dependencies = [ "rustls", - "rustls-pki-types", "tokio", ] [[package]] name = "tokio-util" -version = "0.7.12" +version = "0.7.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61e7c3654c13bcd040d4a03abee2c75b1d14a37b423cf5a813ceae1cc903ec6a" +checksum = "d7fcaa8d55a2bdd6b83ace262b016eca0d79ee02818c5c1bcdf0305114081078" dependencies = [ "bytes", "futures-core", @@ -2842,32 +2901,33 @@ dependencies = [ "serde", "serde_spanned", "toml_datetime", - "winnow 0.6.20", + "winnow 0.6.24", ] [[package]] name = "tower" -version = "0.5.1" +version = "0.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2873938d487c3cfb9aed7546dc9f2711d867c9f90c46b889989a2cb84eba6b4f" +checksum = "d039ad9159c98b70ecfd540b2573b97f7f52c3e8d9f8ad57a24b916a536975f9" dependencies = [ "futures-core", "futures-util", "pin-project-lite", - "sync_wrapper 0.1.2", + "sync_wrapper", + "tokio", "tower-layer", "tower-service", ] [[package]] name = "tower-http" -version = "0.6.1" +version = "0.6.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8437150ab6bbc8c5f0f519e3d5ed4aa883a83dd4cdd3d1b21f9482936046cb97" +checksum = "403fa3b783d4b626a8ad51d766ab03cb6d2dbfc46b1c5d4448395e6628dc9697" dependencies = [ - "bitflags 2.4.0", + "bitflags", "bytes", - "http 1.1.0", + "http 1.2.0", "pin-project-lite", "tower-layer", "tower-service", @@ -2887,9 +2947,9 @@ checksum = "8df9b6e13f2d32c91b9bd719c00d1958837bc7dec474d94952798cc8e69eeec3" [[package]] name = "tracing" -version = "0.1.40" +version = "0.1.41" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3523ab5a71916ccf420eebdf5521fcef02141234bbc0b8a49f2fdc4544364ef" +checksum = "784e0ac535deb450455cbfa28a6f0df145ea1bb7ae51b821cf5e7927fdcfbdd0" dependencies = [ "pin-project-lite", "tracing-attributes", @@ -2898,20 +2958,20 @@ dependencies = [ [[package]] name = "tracing-attributes" -version = "0.1.27" +version = "0.1.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7" +checksum = "395ae124c09f9e6918a2310af6038fba074bcf474ac352496d5910dd59a2226d" dependencies = [ "proc-macro2", "quote", - "syn 2.0.82", + "syn 2.0.96", ] [[package]] name = "tracing-core" -version = "0.1.32" +version = "0.1.33" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c06d3da6113f116aaee68e4d601191614c9053067f9ab7f6edbcb161237daa54" +checksum = "e672c95779cf947c5311f83787af4fa8fffd12fb27e4993211a84bdfd9610f9c" dependencies = [ "once_cell", "valuable", @@ -2930,9 +2990,9 @@ dependencies = [ [[package]] name = "tracing-subscriber" -version = "0.3.18" +version = "0.3.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad0f048c97dbd9faa9b7df56362b8ebcaa52adb06b498c050d2f4e32f90a7a8b" +checksum = "e8189decb5ac0fa7bc8b96b7cb9b2701d60d48805aca84a238004d665fcc4008" dependencies = [ "matchers", "nu-ansi-term", @@ -2948,9 +3008,9 @@ dependencies = [ [[package]] name = "try-lock" -version = "0.2.3" +version = "0.2.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59547bce71d9c38b83d9c0e92b6066c4253371f15005def0c30d9657f50c7642" +checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b" [[package]] name = "typed-builder" @@ -2969,7 +3029,7 @@ checksum = "1f718dfaf347dcb5b983bfc87608144b0bad87970aebcbea5ce44d2a30c08e63" dependencies = [ "proc-macro2", "quote", - "syn 2.0.82", + "syn 2.0.96", ] [[package]] @@ -2980,33 +3040,15 @@ checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825" [[package]] name = "unicase" -version = "2.7.0" +version = "2.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f7d2d4dafb69621809a81864c9c1b864479e1235c0dd4e199924b9742439ed89" -dependencies = [ - "version_check", -] - -[[package]] -name = "unicode-bidi" -version = "0.3.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ab17db44d7388991a428b2ee655ce0c212e862eff1768a455c58f9aad6e7893" +checksum = "75b844d17643ee918803943289730bec8aac480150456169e647ed0b576ba539" [[package]] name = "unicode-ident" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d22af068fba1eb5edcb4aea19d382b2a3deb4c8f9d475c589b6ada9e0fd493ee" - -[[package]] -name = "unicode-normalization" -version = "0.1.24" +version = "1.0.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5033c97c4262335cded6d6fc3e5c18ab755e1a3dc96376350f3d8e9f009ad956" -dependencies = [ - "tinyvec", -] +checksum = "adb9e6ca4f869e1180728b7950e35922a7fc6397f7b641499e8f3ef06e50dc83" [[package]] name = "unicode-segmentation" @@ -3028,21 +3070,33 @@ checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" [[package]] name = "url" -version = "2.5.2" +version = "2.5.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22784dbdf76fdde8af1aeda5622b546b422b6fc585325248a2bf9f5e41e94d6c" +checksum = "32f8b686cadd1473f4bd0117a5d28d36b1ade384ea9b5069a1c40aefed7fda60" dependencies = [ "form_urlencoded", "idna", "percent-encoding", ] +[[package]] +name = "utf16_iter" +version = "1.0.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c8232dd3cdaed5356e0f716d285e4b40b932ac434100fe9b7e0e8e935b9e6246" + [[package]] name = "utf8-width" version = "0.1.7" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "86bd8d4e895da8537e5315b8254664e6b769c4ff3db18321b297a1e7004392e3" +[[package]] +name = "utf8_iter" +version = "1.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6c140620e7ffbb22c2dee59cafe6084a59b5ffc27a8859a5f0d494b5d52b6be" + [[package]] name = "utf8parse" version = "0.2.2" @@ -3051,9 +3105,9 @@ checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" [[package]] name = "uuid" -version = "1.11.0" +version = "1.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8c5f0a0af699448548ad1a2fbf920fb4bee257eae39953ba95cb84891a0446a" +checksum = "b913a3b5fe84142e269d63cc62b64319ccaf89b748fc31fe025177f767a756c4" dependencies = [ "getrandom", ] @@ -3088,11 +3142,10 @@ dependencies = [ [[package]] name = "want" -version = "0.3.0" +version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ce8a968cb1cd110d136ff8b819a556d6fb6d919363c61534f6860c7eb172ba0" +checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e" dependencies = [ - "log", "try-lock", ] @@ -3104,35 +3157,35 @@ checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" [[package]] name = "wasm-bindgen" -version = "0.2.95" +version = "0.2.100" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "128d1e363af62632b8eb57219c8fd7877144af57558fb2ef0368d0087bddeb2e" +checksum = "1edc8929d7499fc4e8f0be2262a241556cfc54a0bea223790e71446f2aab1ef5" dependencies = [ "cfg-if", "once_cell", + "rustversion", "wasm-bindgen-macro", ] [[package]] name = "wasm-bindgen-backend" -version = "0.2.95" +version = "0.2.100" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cb6dd4d3ca0ddffd1dd1c9c04f94b868c37ff5fac97c30b97cff2d74fce3a358" +checksum = "2f0a0651a5c2bc21487bde11ee802ccaf4c51935d0d3d42a6101f98161700bc6" dependencies = [ "bumpalo", "log", - "once_cell", "proc-macro2", "quote", - "syn 2.0.82", + "syn 2.0.96", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-futures" -version = "0.4.45" +version = "0.4.43" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc7ec4f8827a71586374db3e87abdb5a2bb3a15afed140221307c3ec06b1f63b" +checksum = "61e9300f63a621e96ed275155c108eb6f843b6a26d053f122ab69724559dc8ed" dependencies = [ "cfg-if", "js-sys", @@ -3142,9 +3195,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro" -version = "0.2.95" +version = "0.2.100" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e79384be7f8f5a9dd5d7167216f022090cf1f9ec128e6e6a482a2cb5c5422c56" +checksum = "7fe63fc6d09ed3792bd0897b314f53de8e16568c2b3f7982f468c0bf9bd0b407" dependencies = [ "quote", "wasm-bindgen-macro-support", @@ -3152,28 +3205,31 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro-support" -version = "0.2.95" +version = "0.2.100" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26c6ab57572f7a24a4985830b120de1594465e5d500f24afe89e16b4e833ef68" +checksum = "8ae87ea40c9f689fc23f209965b6fb8a99ad69aeeb0231408be24920604395de" dependencies = [ "proc-macro2", "quote", - "syn 2.0.82", + "syn 2.0.96", "wasm-bindgen-backend", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-shared" -version = "0.2.95" +version = "0.2.100" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "65fc09f10666a9f147042251e0dda9c18f166ff7de300607007e96bdebc1068d" +checksum = "1a05d73b933a847d6cccdda8f838a22ff101ad9bf93e33684f39c1f5f0eece3d" +dependencies = [ + "unicode-ident", +] [[package]] name = "wasm-bindgen-test" -version = "0.3.45" +version = "0.3.43" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d381749acb0943d357dcbd8f0b100640679883fcdeeef04def49daf8d33a5426" +checksum = "68497a05fb21143a08a7d24fc81763384a3072ee43c44e86aad1744d6adef9d9" dependencies = [ "console_error_panic_hook", "js-sys", @@ -3186,13 +3242,13 @@ dependencies = [ [[package]] name = "wasm-bindgen-test-macro" -version = "0.3.45" +version = "0.3.43" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c97b2ef2c8d627381e51c071c2ab328eac606d3f69dd82bcbca20a9e389d95f0" +checksum = "4b8220be1fa9e4c889b30fd207d4906657e7e90b12e0e6b0c8b8d8709f5de021" dependencies = [ "proc-macro2", "quote", - "syn 2.0.82", + "syn 2.0.96", ] [[package]] @@ -3210,9 +3266,9 @@ dependencies = [ [[package]] name = "web-sys" -version = "0.3.72" +version = "0.3.77" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6488b90108c040df0fe62fa815cbdee25124641df01814dd7282749234c6112" +checksum = "33b6dd2ef9186f1f2072e409e99cd22a975331a6b3591b12c764e0e55c60d5d2" dependencies = [ "js-sys", "wasm-bindgen", @@ -3447,18 +3503,30 @@ dependencies = [ [[package]] name = "winnow" -version = "0.6.20" +version = "0.6.24" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "36c1fec1a2bb5866f07c25f68c26e565c4c200aebb96d7e55710c19d3e8ac49b" +checksum = "c8d71a593cc5c42ad7876e2c1fda56f314f3754c084128833e64f1345ff8a03a" dependencies = [ "memchr", ] +[[package]] +name = "write16" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d1890f4022759daae28ed4fe62859b1236caebfc61ede2f63ed4e695f3f6d936" + +[[package]] +name = "writeable" +version = "0.5.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e9df38ee2d2c3c5948ea468a8406ff0db0b29ae1ffde1bcf20ef305bcc95c51" + [[package]] name = "xxhash-rust" -version = "0.8.12" +version = "0.8.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a5cbf750400958819fb6178eaa83bee5cd9c29a26a40cc241df8c70fdd46984" +checksum = "fdd20c5420375476fbd4394763288da7eb0cc0b8c11deed431a91562af7335d3" [[package]] name = "yansi" @@ -3466,8 +3534,75 @@ version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "cfe53a6657fd280eaa890a3bc59152892ffa3e30101319d168b781ed6529b049" +[[package]] +name = "yoke" +version = "0.7.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "120e6aef9aa629e3d4f52dc8cc43a015c7724194c97dfaf45180d2daf2b77f40" +dependencies = [ + "serde", + "stable_deref_trait", + "yoke-derive", + "zerofrom", +] + +[[package]] +name = "yoke-derive" +version = "0.7.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2380878cad4ac9aac1e2435f3eb4020e8374b5f13c296cb75b4620ff8e229154" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.96", + "synstructure", +] + +[[package]] +name = "zerofrom" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cff3ee08c995dee1859d998dea82f7374f2826091dd9cd47def953cae446cd2e" +dependencies = [ + "zerofrom-derive", +] + +[[package]] +name = "zerofrom-derive" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "595eed982f7d355beb85837f651fa22e90b3c044842dc7f2c2842c086f295808" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.96", + "synstructure", +] + [[package]] name = "zeroize" version = "1.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ced3678a2879b30306d323f4542626697a464a97c0a07c9aebf7ebca65cd4dde" + +[[package]] +name = "zerovec" +version = "0.10.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aa2b893d79df23bfb12d5461018d408ea19dfafe76c2c7ef6d4eba614f8ff079" +dependencies = [ + "yoke", + "zerofrom", + "zerovec-derive", +] + +[[package]] +name = "zerovec-derive" +version = "0.10.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6eafa6dfb17584ea3e2bd6e76e0cc15ad7af12b09abdd1ca55961bed9b1063c6" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.96", +] diff --git a/Cargo.toml b/Cargo.toml index d9fb44ff..c291eaca 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,11 +1,7 @@ [workspace] members = [ - "crates/file-explorer", - "crates/file-explorer-plugin", - "crates/file-explorer-proto", "crates/file-explorer-ui", "crates/http-server", - "crates/http-server-plugin", ] default-members = ["crates/http-server"] resolver = "1" @@ -50,9 +46,3 @@ tower-layer = "0.3.3" tracing = "0.1.40" tracing-subscriber = "0.3.18" web-sys = "0.3.72" - -# Workspace Crates -file-explorer = { path = "crates/file-explorer" } -file-explorer-proto = { path = "crates/file-explorer-proto" } -file-explorer-ui = { path = "crates/file-explorer-ui" } -http-server-plugin = { path = "crates/http-server-plugin" } diff --git a/Makefile b/Makefile index 9640dcd6..b8f03d70 100644 --- a/Makefile +++ b/Makefile @@ -3,17 +3,8 @@ default: @echo No default target. -dev: ui-build plugin-build - cargo b --all && cargo r - -release: plugin-build - make -C ./crates/file-explorer-plugin release - -plugin-build: ui-release - make -C ./crates/file-explorer-plugin release - ui-build: - make -C ./crates/file-explorer-ui build + make -C ./crates/file-explorer-ui release ui-dev: @echo Starting File Explorer UI… diff --git a/crates/file-explorer-plugin/Cargo.toml b/crates/file-explorer-plugin/Cargo.toml deleted file mode 100644 index d10d05c9..00000000 --- a/crates/file-explorer-plugin/Cargo.toml +++ /dev/null @@ -1,35 +0,0 @@ -[package] -name = "file-explorer-plugin" -version = "0.0.0" -authors = ["Esteban Borai "] -edition = "2021" -publish = false - -[lib] -crate-type = ["cdylib", "rlib"] - -[dependencies] -anyhow = { workspace = true } -async-trait = { workspace = true } -bytes = { workspace = true } -chrono = { workspace = true, features = ["serde"] } -futures = { workspace = true } -http = { workspace = true } -http-body-util = { workspace = true } -humansize = { workspace = true } -hyper = { workspace = true } -mime_guess = { workspace = true } -multer = { workspace = true } -rust-embed = { workspace = true } -serde = { workspace = true, features = ["derive"] } -serde_json = { workspace = true } -percent-encoding = { workspace = true } -tokio = { workspace = true, features = ["fs", "rt-multi-thread", "signal", "macros"] } -tokio-util = { workspace = true, features = ["io"] } -tracing = { workspace = true } -tracing-subscriber = { workspace = true, features = ["env-filter"] } - -http-server-plugin = { workspace = true } -file-explorer = { workspace = true } -file-explorer-proto = { workspace = true } -file-explorer-ui = { workspace = true } diff --git a/crates/file-explorer-plugin/Makefile b/crates/file-explorer-plugin/Makefile deleted file mode 100644 index ce0fb559..00000000 --- a/crates/file-explorer-plugin/Makefile +++ /dev/null @@ -1,9 +0,0 @@ -.PHONY: default - -default: - @echo No default target. - -release: - @echo Building file-explorer-plugin… - cargo b - cp ../../target/debug/libfile_explorer_plugin.dylib ../http-server/inline/file_explorer.plugin.httprs diff --git a/crates/file-explorer-proto/Cargo.toml b/crates/file-explorer-proto/Cargo.toml deleted file mode 100644 index 35d5a72f..00000000 --- a/crates/file-explorer-proto/Cargo.toml +++ /dev/null @@ -1,10 +0,0 @@ -[package] -name = "file-explorer-proto" -version = "0.0.0" -authors = ["Esteban Borai "] -edition = "2021" -publish = false - -[dependencies] -chrono = { workspace = true, features = ["serde"] } -serde = { workspace = true, features = ["derive"] } diff --git a/crates/file-explorer-ui/Cargo.toml b/crates/file-explorer-ui/Cargo.toml index d25b4395..16bbb10f 100644 --- a/crates/file-explorer-ui/Cargo.toml +++ b/crates/file-explorer-ui/Cargo.toml @@ -23,11 +23,9 @@ leptos = { workspace = true, features = ["csr"] } leptos_meta = { workspace = true, features = ["csr"] } leptos_router = { workspace = true, features = ["csr"] } reqwest = { workspace = true, features = ["json"] } -rust-embed = { workspace = true } +serde = { workspace = true, features = ["derive"] } web-sys = { workspace = true, features = ["FileList", "HtmlInputElement"] } -file-explorer-proto = { workspace = true } - [dev-dependencies] web-sys = { workspace = true } diff --git a/crates/file-explorer-ui/Makefile b/crates/file-explorer-ui/Makefile index b743e861..94e67fa9 100644 --- a/crates/file-explorer-ui/Makefile +++ b/crates/file-explorer-ui/Makefile @@ -3,9 +3,6 @@ default: @echo No default target. -build: - trunk build --locked --config ./Trunk.toml - dev: trunk serve --config ./Trunk.toml diff --git a/crates/file-explorer-ui/src/api.rs b/crates/file-explorer-ui/src/api/mod.rs similarity index 96% rename from crates/file-explorer-ui/src/api.rs rename to crates/file-explorer-ui/src/api/mod.rs index 4ac2bd21..d8cb4cff 100644 --- a/crates/file-explorer-ui/src/api.rs +++ b/crates/file-explorer-ui/src/api/mod.rs @@ -1,9 +1,11 @@ +pub mod proto; + use anyhow::Result; use gloo::utils::window; use reqwest::{header::CONTENT_TYPE, Url}; use web_sys::FormData; -use file_explorer_proto::DirectoryIndex; +use self::proto::DirectoryIndex; pub struct FileDownload { pub bytes: Vec, diff --git a/crates/file-explorer-proto/src/lib.rs b/crates/file-explorer-ui/src/api/proto.rs similarity index 100% rename from crates/file-explorer-proto/src/lib.rs rename to crates/file-explorer-ui/src/api/proto.rs diff --git a/crates/file-explorer-ui/src/components/organisms/navigation_bar.rs b/crates/file-explorer-ui/src/components/organisms/navigation_bar.rs index 61d157e4..462f43c5 100644 --- a/crates/file-explorer-ui/src/components/organisms/navigation_bar.rs +++ b/crates/file-explorer-ui/src/components/organisms/navigation_bar.rs @@ -1,7 +1,6 @@ use leptos::{component, view, For, IntoView, Signal, SignalGet}; -use file_explorer_proto::BreadcrumbItem; - +use crate::api::proto::BreadcrumbItem; use crate::components::atoms::icons::House; #[component] diff --git a/crates/file-explorer-ui/src/components/pages/explorer.rs b/crates/file-explorer-ui/src/components/pages/explorer.rs index b239feda..69fa0f9d 100644 --- a/crates/file-explorer-ui/src/components/pages/explorer.rs +++ b/crates/file-explorer-ui/src/components/pages/explorer.rs @@ -3,8 +3,7 @@ use leptos::{ component, create_memo, create_signal, spawn_local, view, IntoView, SignalGet, SignalSet, }; -use file_explorer_proto::DirectoryIndex; - +use crate::api::proto::DirectoryIndex; use crate::api::Api; use crate::components::organisms::action_bar::ActionBar; use crate::components::organisms::navigation_bar::NavigationBar; diff --git a/crates/file-explorer-ui/src/components/templates/file_list/entry.rs b/crates/file-explorer-ui/src/components/templates/file_list/entry.rs index d7de1cbb..d5edc593 100644 --- a/crates/file-explorer-ui/src/components/templates/file_list/entry.rs +++ b/crates/file-explorer-ui/src/components/templates/file_list/entry.rs @@ -1,7 +1,7 @@ use chrono::{DateTime, Local}; use leptos::{component, view, IntoView, View}; -use file_explorer_proto::EntryType; +use crate::api::proto::EntryType; use super::download_button::DownloadButton; use super::entry_icon::EntryIcon; diff --git a/crates/file-explorer-ui/src/components/templates/file_list/entry_icon.rs b/crates/file-explorer-ui/src/components/templates/file_list/entry_icon.rs index 571c6c92..25cdb558 100644 --- a/crates/file-explorer-ui/src/components/templates/file_list/entry_icon.rs +++ b/crates/file-explorer-ui/src/components/templates/file_list/entry_icon.rs @@ -1,7 +1,6 @@ use leptos::{component, view, IntoView}; -use file_explorer_proto::EntryType; - +use crate::api::proto::EntryType; use crate::components::atoms::icons::{File, Folder, Git, Justfile, Markdown, Rust, Toml}; #[component] diff --git a/crates/file-explorer-ui/src/components/templates/file_list/mod.rs b/crates/file-explorer-ui/src/components/templates/file_list/mod.rs index 3a0db79e..3870b2ce 100644 --- a/crates/file-explorer-ui/src/components/templates/file_list/mod.rs +++ b/crates/file-explorer-ui/src/components/templates/file_list/mod.rs @@ -4,7 +4,7 @@ mod entry_icon; use leptos::{component, view, For, IntoView, Signal, SignalGet}; -use file_explorer_proto::DirectoryEntry; +use crate::api::proto::DirectoryEntry; use self::entry::Entry; diff --git a/crates/file-explorer-ui/src/lib.rs b/crates/file-explorer-ui/src/lib.rs index 7635c7c8..fd679fa0 100644 --- a/crates/file-explorer-ui/src/lib.rs +++ b/crates/file-explorer-ui/src/lib.rs @@ -3,13 +3,8 @@ mod components; use leptos::{component, view, IntoView}; use leptos_meta::provide_meta_context; -use rust_embed::Embed; -use crate::components::pages::explorer::Explorer; - -#[derive(Embed)] -#[folder = "public/dist"] -pub struct Assets; +use self::components::pages::explorer::Explorer; #[component] pub fn App() -> impl IntoView { diff --git a/crates/file-explorer/Cargo.toml b/crates/file-explorer/Cargo.toml deleted file mode 100644 index 178e59c9..00000000 --- a/crates/file-explorer/Cargo.toml +++ /dev/null @@ -1,12 +0,0 @@ -[package] -name = "file-explorer" -version = "0.0.0" -authors = ["Esteban Borai "] -edition = "2021" -publish = false - -[dependencies] -anyhow = { workspace = true } -chrono = { workspace = true, features = ["serde"] } -mime_guess = { workspace = true } -tokio = { workspace = true, features = ["fs", "rt-multi-thread", "signal", "macros"] } diff --git a/crates/http-server-plugin/Cargo.toml b/crates/http-server-plugin/Cargo.toml deleted file mode 100644 index e632453c..00000000 --- a/crates/http-server-plugin/Cargo.toml +++ /dev/null @@ -1,25 +0,0 @@ -[package] -name = "http-server-plugin" -version = "1.0.0-draft+1" -authors = ["Esteban Borai "] -edition = "2021" -description = "HTTP Server RS Plugin Crate" -repository = "https://github.com/http-server-rs/http-server" -categories = ["web-programming", "web-programming::http-server"] -keywords = ["sdk", "http", "server", "plugin", "dll"] -license = "MIT OR Apache-2.0" -readme = "../../README.md" - -[dependencies] -anyhow = { workspace = true } -async-trait = { workspace = true } -bytes = { workspace = true } -http = { workspace = true } -http-body-util = { workspace = true } -hyper = { workspace = true } -serde = { workspace = true } -tokio = { workspace = true, features = ["full"] } -toml = { workspace = true } - -[build-dependencies] -rustc_version = { workspace = true } diff --git a/crates/http-server-plugin/build.rs b/crates/http-server-plugin/build.rs deleted file mode 100644 index a38022ff..00000000 --- a/crates/http-server-plugin/build.rs +++ /dev/null @@ -1,4 +0,0 @@ -fn main() { - let version = rustc_version::version().unwrap(); - println!("cargo:rustc-env=RUSTC_VERSION={}", version); -} diff --git a/crates/http-server-plugin/src/config.rs b/crates/http-server-plugin/src/config.rs deleted file mode 100644 index 9f5e63ec..00000000 --- a/crates/http-server-plugin/src/config.rs +++ /dev/null @@ -1,18 +0,0 @@ -use std::fs::read_to_string; -use std::path::PathBuf; - -use anyhow::{bail, Result}; -use serde::de::DeserializeOwned; -use toml::Table; - -pub fn read_from_path(path: PathBuf, key: &str) -> Result { - let config_str = read_to_string(&path)?; - let config_tbl: Table = toml::from_str(&config_str)?; - - if let Some(tbl) = config_tbl.get(key) { - let config: T = tbl.to_owned().try_into().unwrap(); - return Ok(config); - } - - bail!("Key not found") -} diff --git a/crates/http-server-plugin/src/lib.rs b/crates/http-server-plugin/src/lib.rs deleted file mode 100644 index 6b17af15..00000000 --- a/crates/http-server-plugin/src/lib.rs +++ /dev/null @@ -1,50 +0,0 @@ -pub mod config; - -use std::path::PathBuf; -use std::sync::Arc; - -use async_trait::async_trait; -use http::request::Parts; -use http_body_util::Full; -use hyper::body::Bytes; -use hyper::Response; -use tokio::runtime::Handle; - -pub static CORE_VERSION: &str = env!("CARGO_PKG_VERSION"); -pub static RUSTC_VERSION: &str = env!("RUSTC_VERSION"); - -#[async_trait] -pub trait Plugin: Send + Sync { - async fn call(&self, parts: Parts, body: Bytes) -> Result>, PluginError>; -} - -#[derive(Debug)] -pub enum PluginError { - SpawnError { err: String }, - Other { msg: String }, -} - -#[allow(improper_ctypes_definitions)] -pub struct PluginDeclaration { - pub rustc_version: &'static str, - pub core_version: &'static str, - pub register: - unsafe extern "C" fn(config_path: PathBuf, rt: Arc, &mut dyn PluginRegistrar), -} - -pub trait PluginRegistrar { - fn register_function(&mut self, name: &str, function: Arc); -} - -#[macro_export] -macro_rules! export_plugin { - ($register:expr) => { - #[doc(hidden)] - #[no_mangle] - pub static PLUGIN_DECLARATION: $crate::PluginDeclaration = $crate::PluginDeclaration { - rustc_version: $crate::RUSTC_VERSION, - core_version: $crate::CORE_VERSION, - register: $register, - }; - }; -} diff --git a/crates/http-server/Cargo.toml b/crates/http-server/Cargo.toml index 52053db7..55c41553 100644 --- a/crates/http-server/Cargo.toml +++ b/crates/http-server/Cargo.toml @@ -10,20 +10,13 @@ keywords = ["configurable", "http", "server", "serve", "static"] license = "MIT OR Apache-2.0" readme = "README.md" -[[bin]] -name = "http-server" -path = "src/bin/main.rs" - -[lib] -name = "http_server_rs" -path = "src/lib.rs" - # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [dependencies] anyhow = { workspace = true } async-trait = { workspace = true } bytes = { workspace = true } +chrono = { workspace = true, features = ["serde"] } clap = { workspace = true, features = ["env", "derive", "std"] } dirs = { workspace = true } http = { workspace = true } @@ -32,11 +25,16 @@ hyper = { workspace = true } hyper-util = { workspace = true, features = ["full"] } libloading = { workspace = true } local-ip-address = { workspace = true } +mime_guess = { workspace = true } +multer = { workspace = true } +rust-embed = { workspace = true } +percent-encoding = { workspace = true } +serde = { workspace = true, features = ["derive"] } +serde_json = { workspace = true } tokio = { workspace = true, features = ["fs", "rt-multi-thread", "signal", "macros"] } +tokio-util = { workspace = true } tower-http = { workspace = true, features = ["cors"] } tower = { workspace = true, features = ["util"] } tower-layer = { workspace = true } tracing = { workspace = true } tracing-subscriber = { workspace = true, features = ["env-filter"] } - -http-server-plugin = { workspace = true } diff --git a/crates/http-server/Makefile b/crates/http-server/Makefile deleted file mode 100644 index ca7565eb..00000000 --- a/crates/http-server/Makefile +++ /dev/null @@ -1,7 +0,0 @@ -.PHONY: default - -default: - @echo No default target. - -release: - cargo b --release -p file-explorer-plugin diff --git a/crates/http-server/inline/.gitkeep b/crates/http-server/inline/.gitkeep deleted file mode 100644 index e69de29b..00000000 diff --git a/crates/http-server/src/bin/cli/command/setup.rs b/crates/http-server/src/bin/cli/command/setup.rs deleted file mode 100644 index 75860148..00000000 --- a/crates/http-server/src/bin/cli/command/setup.rs +++ /dev/null @@ -1,42 +0,0 @@ -use std::fs::{create_dir_all, write}; - -use anyhow::Result; -use clap::Parser; - -use http_server_rs::{install_path, plugins_path, DEFAULT_PLUGIN_NAME, FILE_EXPLORER_PLUGIN_BYTES}; - -#[derive(Debug, Parser)] -pub struct SetupOpt {} - -impl SetupOpt { - pub fn exec(&self) -> Result<()> { - let http_server_install_path = install_path()?; - - if http_server_install_path.exists() { - println!("HTTP Server System Files already installed."); - } - - let plugins_path = plugins_path()?; - - if !plugins_path.exists() { - println!( - "Creating HTTP Server System Files at: {}", - http_server_install_path.display() - ); - create_dir_all(&plugins_path)?; - } - - let file_explorer_plugin_path = plugins_path.join(DEFAULT_PLUGIN_NAME); - - if !file_explorer_plugin_path.exists() { - println!( - "Installing File Explorer Plugin at: {}", - file_explorer_plugin_path.display() - ); - write(&file_explorer_plugin_path, FILE_EXPLORER_PLUGIN_BYTES)?; - } - - println!("HTTP Server Installed"); - Ok(()) - } -} diff --git a/crates/http-server/src/bin/cli/command/mod.rs b/crates/http-server/src/cli/command/mod.rs similarity index 60% rename from crates/http-server/src/bin/cli/command/mod.rs rename to crates/http-server/src/cli/command/mod.rs index f6084334..6afe6180 100644 --- a/crates/http-server/src/bin/cli/command/mod.rs +++ b/crates/http-server/src/cli/command/mod.rs @@ -1,15 +1,11 @@ -mod setup; mod start; use clap::Parser; -use self::setup::SetupOpt; use self::start::StartOpt; #[derive(Debug, Parser)] pub enum Command { - /// Setup the HTTP Server System Files - Setup(SetupOpt), /// Start the HTTP Server Start(StartOpt), } diff --git a/crates/http-server/src/bin/cli/command/start.rs b/crates/http-server/src/cli/command/start.rs similarity index 91% rename from crates/http-server/src/bin/cli/command/start.rs rename to crates/http-server/src/cli/command/start.rs index 56cbaf97..108333b8 100644 --- a/crates/http-server/src/bin/cli/command/start.rs +++ b/crates/http-server/src/cli/command/start.rs @@ -7,8 +7,8 @@ use clap::Parser; use tokio::runtime::Builder; use tracing::{error, info}; -use http_server_rs::server::config::Config; -use http_server_rs::server::Server; +use crate::config::Config; +use crate::server::Server; const THREAD_NAME: &str = "http-server"; @@ -46,7 +46,7 @@ impl StartOpt { let server = Server::new(config); rt.block_on(async { - match server.run(Arc::clone(&rt)).await { + match server.run().await { Ok(_) => { info!("Server exited successfuly"); Ok(()) diff --git a/crates/http-server/src/bin/cli/mod.rs b/crates/http-server/src/cli/mod.rs similarity index 100% rename from crates/http-server/src/bin/cli/mod.rs rename to crates/http-server/src/cli/mod.rs diff --git a/crates/http-server/src/server/config.rs b/crates/http-server/src/config.rs similarity index 100% rename from crates/http-server/src/server/config.rs rename to crates/http-server/src/config.rs diff --git a/crates/file-explorer/src/fs/directory.rs b/crates/http-server/src/handler/file_explorer/core/fs/directory.rs similarity index 100% rename from crates/file-explorer/src/fs/directory.rs rename to crates/http-server/src/handler/file_explorer/core/fs/directory.rs diff --git a/crates/file-explorer/src/fs/file.rs b/crates/http-server/src/handler/file_explorer/core/fs/file.rs similarity index 100% rename from crates/file-explorer/src/fs/file.rs rename to crates/http-server/src/handler/file_explorer/core/fs/file.rs diff --git a/crates/file-explorer/src/fs/mod.rs b/crates/http-server/src/handler/file_explorer/core/fs/mod.rs similarity index 83% rename from crates/file-explorer/src/fs/mod.rs rename to crates/http-server/src/handler/file_explorer/core/fs/mod.rs index 63fc62c8..4e1bbf51 100644 --- a/crates/file-explorer/src/fs/mod.rs +++ b/crates/http-server/src/handler/file_explorer/core/fs/mod.rs @@ -1,13 +1,10 @@ -mod directory; -mod file; +pub mod directory; +pub mod file; use std::path::PathBuf; use anyhow::Result; -pub use self::directory::Directory; -pub use self::file::File; - #[derive(Debug, Clone)] pub struct FileSystem { pub path: PathBuf, diff --git a/crates/file-explorer/src/lib.rs b/crates/http-server/src/handler/file_explorer/core/mod.rs similarity index 98% rename from crates/file-explorer/src/lib.rs rename to crates/http-server/src/handler/file_explorer/core/mod.rs index e007c8b9..41a2d95a 100644 --- a/crates/file-explorer/src/lib.rs +++ b/crates/http-server/src/handler/file_explorer/core/mod.rs @@ -2,11 +2,11 @@ mod fs; use std::path::{Component, PathBuf}; +use anyhow::Result; use tokio::fs::OpenOptions; -pub use self::fs::{Directory, File}; - -use anyhow::Result; +use self::fs::directory::Directory; +use self::fs::file::File; /// Any OS filesystem entry recognized by [`FileExplorer`] is treated as a /// `Entry` both `File` and `Directory` are possible values. diff --git a/crates/file-explorer-plugin/src/lib.rs b/crates/http-server/src/handler/file_explorer/mod.rs similarity index 75% rename from crates/file-explorer-plugin/src/lib.rs rename to crates/http-server/src/handler/file_explorer/mod.rs index d7910b14..1baa0632 100644 --- a/crates/file-explorer-plugin/src/lib.rs +++ b/crates/http-server/src/handler/file_explorer/mod.rs @@ -1,127 +1,79 @@ +mod core; +mod proto; mod utils; +use core::Entry; use std::fs::read_dir; -use std::mem::MaybeUninit; use std::path::{Component, Path, PathBuf}; -use std::sync::Arc; use anyhow::{Context, Result}; -use async_trait::async_trait; -use http::request::Parts; -use http::HeaderValue; -use http_body_util::Full; -use hyper::body::Bytes; -use hyper::header::CONTENT_TYPE; -use hyper::{Method, Response, StatusCode, Uri}; +use bytes::Bytes; +use http::{header::CONTENT_TYPE, request::Parts, HeaderValue, Method, Response, StatusCode, Uri}; +use http_body_util::{BodyExt, Full}; use multer::Multipart; use percent_encoding::{percent_decode_str, utf8_percent_encode}; -use serde::Deserialize; +use proto::{DirectoryEntry, DirectoryIndex, EntryType, Sort}; +use rust_embed::Embed; use tokio::io::AsyncWriteExt; -use tokio::runtime::Handle; -use file_explorer::{Entry, FileExplorer}; -use file_explorer_proto::{BreadcrumbItem, DirectoryEntry, DirectoryIndex, EntryType, Sort}; -use file_explorer_ui::Assets; -use http_server_plugin::config::read_from_path; -use http_server_plugin::{export_plugin, Plugin, PluginError, PluginRegistrar}; +use crate::server::{HttpRequest, HttpResponse}; +use self::proto::BreadcrumbItem; use self::utils::{decode_uri, encode_uri, PERCENT_ENCODE_SET}; -const FILE_BUFFER_SIZE: usize = 8 * 1024; +#[derive(Embed)] +#[folder = "../file-explorer-ui/public/dist"] +struct FileExplorerAssets; -pub type FileBuffer = Box<[MaybeUninit; FILE_BUFFER_SIZE]>; - -export_plugin!(register); - -const PLUGIN_NAME: &str = "file-explorer"; - -#[allow(improper_ctypes_definitions)] -extern "C" fn register(config_path: PathBuf, rt: Arc, registrar: &mut dyn PluginRegistrar) { - tracing_subscriber::fmt() - .with_max_level(tracing::Level::INFO) - .init(); - - let config: FileExplorerConfig = read_from_path(config_path, PLUGIN_NAME).unwrap(); - - registrar.register_function( - PLUGIN_NAME, - Arc::new(FileExplorerPlugin::new(rt, config.path)), - ); -} - -#[derive(Debug, Deserialize)] -struct FileExplorerConfig { - pub path: PathBuf, -} - -struct FileExplorerPlugin { - file_explorer: FileExplorer, +pub struct FileExplorer { + file_explorer: core::FileExplorer, path: PathBuf, - rt: Arc, } -#[async_trait] -impl Plugin for FileExplorerPlugin { - async fn call(&self, parts: Parts, body: Bytes) -> Result>, PluginError> { - self.rt - .block_on(async move { self.handle(parts, body).await }) - } -} - -impl FileExplorerPlugin { - fn new(rt: Arc, path: PathBuf) -> Self { - let file_explorer = FileExplorer::new(path.clone()); - +impl FileExplorer { + pub fn new(path: PathBuf) -> Self { Self { - file_explorer, + file_explorer: core::FileExplorer::new(path.clone()), path, - rt, } } - async fn handle( - &self, - parts: Parts, - body: Bytes, - ) -> Result>, PluginError> { - tracing::info!("Handling request: {:?}", parts); + pub async fn handle(&self, req: HttpRequest) -> Result { + let (parts, body) = req.into_parts(); + let body = body.collect().await.unwrap().to_bytes(); if parts.uri.path().starts_with("/api/v1") { - self.handle_api(parts, body).await - } else { - let path = parts.uri.path(); - let path = path.strip_prefix('/').unwrap_or(path); - - if let Some(file) = Assets::get(path) { - let content_type = mime_guess::from_path(path).first_or_octet_stream(); - let content_type = HeaderValue::from_str(content_type.as_ref()).unwrap(); - let body = Full::new(Bytes::from(file.data.to_vec())); - let mut response = Response::new(body); - let mut headers = response.headers().clone(); - - headers.append(CONTENT_TYPE, content_type); - *response.headers_mut() = headers; - - return Ok(response); - } + return self.handle_api(parts, body).await; + } - let index = Assets::get("index.html").unwrap(); - let body = Full::new(Bytes::from(index.data.to_vec())); + let path = parts.uri.path(); + let path = path.strip_prefix('/').unwrap_or(path); + + if let Some(file) = FileExplorerAssets::get(path) { + let content_type = mime_guess::from_path(path).first_or_octet_stream(); + let content_type = HeaderValue::from_str(content_type.as_ref()).unwrap(); + let body = Full::new(Bytes::from(file.data.to_vec())); let mut response = Response::new(body); let mut headers = response.headers().clone(); - headers.append(CONTENT_TYPE, "text/html".try_into().unwrap()); + headers.append(CONTENT_TYPE, content_type); *response.headers_mut() = headers; - Ok(response) + return Ok(response); } + + let index = FileExplorerAssets::get("index.html").unwrap(); + let body = Full::new(Bytes::from(index.data.to_vec())); + let mut response = Response::new(body); + let mut headers = response.headers().clone(); + + headers.append(CONTENT_TYPE, "text/html".try_into().unwrap()); + *response.headers_mut() = headers; + + Ok(response) } - async fn handle_api( - &self, - parts: Parts, - body: Bytes, - ) -> Result>, PluginError> { + async fn handle_api(&self, parts: Parts, body: Bytes) -> Result { let path = Self::parse_req_uri(parts.uri.clone()).unwrap(); match parts.method { @@ -166,11 +118,7 @@ impl FileExplorerPlugin { } } - async fn handle_file_upload( - &self, - parts: Parts, - body: Bytes, - ) -> Result>, PluginError> { + async fn handle_file_upload(&self, parts: Parts, body: Bytes) -> Result { // Extract the `multipart/form-data` boundary from the headers. let boundary = parts .headers diff --git a/crates/http-server/src/handler/file_explorer/proto.rs b/crates/http-server/src/handler/file_explorer/proto.rs new file mode 100644 index 00000000..67ba90f5 --- /dev/null +++ b/crates/http-server/src/handler/file_explorer/proto.rs @@ -0,0 +1,86 @@ +use std::cmp::Ordering; + +use chrono::{DateTime, Local}; +use serde::{Deserialize, Serialize}; + +#[derive(Clone, Debug, Deserialize, PartialEq, Eq, Serialize)] +pub enum EntryType { + Directory, + File, + Git, + Justfile, + Markdown, + Rust, + Toml, +} + +/// A Directory entry used to display a File Explorer's entry. +/// This struct is directly related to the Handlebars template used +/// to power the File Explorer's UI +#[derive(Clone, Debug, Deserialize, Eq, Serialize)] +pub struct DirectoryEntry { + pub display_name: String, + pub is_dir: bool, + pub size_bytes: u64, + pub entry_path: String, + pub entry_type: EntryType, + pub date_created: Option>, + pub date_modified: Option>, +} + +impl Ord for DirectoryEntry { + fn cmp(&self, other: &Self) -> Ordering { + if self.is_dir && other.is_dir { + return self.display_name.cmp(&other.display_name); + } + + if self.is_dir && !other.is_dir { + return Ordering::Less; + } + + Ordering::Greater + } +} + +impl PartialOrd for DirectoryEntry { + fn partial_cmp(&self, other: &Self) -> Option { + Some(self.cmp(other)) + } +} + +impl PartialEq for DirectoryEntry { + fn eq(&self, other: &Self) -> bool { + if self.is_dir && other.is_dir { + return self.display_name == other.display_name; + } + + self.display_name == other.display_name + } +} + +/// A Breadcrumb Item used to navigate to previous path components +#[derive(Clone, Debug, Deserialize, Serialize, PartialEq, Eq)] +pub struct BreadcrumbItem { + pub depth: u8, + pub entry_name: String, + pub entry_link: String, +} + +/// The value passed to the Handlebars template engine. +/// All references contained in File Explorer's UI are provided +/// via the `DirectoryIndex` struct +#[derive(Clone, Debug, Deserialize, Serialize)] +pub struct DirectoryIndex { + pub entries: Vec, + pub breadcrumbs: Vec, + pub sort: Sort, +} + +#[derive(Clone, Serialize, Debug, PartialEq, Deserialize)] +pub enum Sort { + Directory, + Name, + Size, + DateCreated, + DateModified, +} diff --git a/crates/file-explorer-plugin/src/utils.rs b/crates/http-server/src/handler/file_explorer/utils.rs similarity index 100% rename from crates/file-explorer-plugin/src/utils.rs rename to crates/http-server/src/handler/file_explorer/utils.rs diff --git a/crates/http-server/src/handler/mod.rs b/crates/http-server/src/handler/mod.rs new file mode 100644 index 00000000..f2aeb5e7 --- /dev/null +++ b/crates/http-server/src/handler/mod.rs @@ -0,0 +1 @@ +pub mod file_explorer; diff --git a/crates/http-server/src/lib.rs b/crates/http-server/src/lib.rs deleted file mode 100644 index 553c9eb9..00000000 --- a/crates/http-server/src/lib.rs +++ /dev/null @@ -1,27 +0,0 @@ -pub mod server; - -use std::path::PathBuf; - -use anyhow::{bail, Result}; -use dirs::home_dir; - -pub const HTTP_SERVER_HOME_DIRNAME: &str = ".http-server-rs"; -pub const HTTP_SERVER_PLUGINS_DIRNAME: &str = "plugins"; -pub const DEFAULT_PLUGIN_NAME: &str = "file_explorer.plugin.httprs"; -pub const FILE_EXPLORER_PLUGIN_BYTES: &[u8] = - include_bytes!("../inline/file_explorer.plugin.httprs"); - -pub fn install_path() -> Result { - let Some(home) = home_dir() else { - bail!("Failed to resolve Home Directory. Unable to install."); - }; - - Ok(home.join(HTTP_SERVER_HOME_DIRNAME)) -} - -pub fn plugins_path() -> Result { - let install_path = install_path()?; - let plugins_path = install_path.join(HTTP_SERVER_PLUGINS_DIRNAME); - - Ok(plugins_path) -} diff --git a/crates/http-server/src/bin/main.rs b/crates/http-server/src/main.rs similarity index 87% rename from crates/http-server/src/bin/main.rs rename to crates/http-server/src/main.rs index 80cf79ed..ee5f3555 100644 --- a/crates/http-server/src/bin/main.rs +++ b/crates/http-server/src/main.rs @@ -1,4 +1,7 @@ pub mod cli; +pub mod config; +pub mod handler; +pub mod server; use anyhow::Result; use clap::Parser; @@ -14,7 +17,6 @@ fn main() -> Result<()> { match args.command { Command::Start(opt) => opt.exec()?, - Command::Setup(opt) => opt.exec()?, } Ok(()) diff --git a/crates/http-server/src/server/mod.rs b/crates/http-server/src/server.rs similarity index 56% rename from crates/http-server/src/server/mod.rs rename to crates/http-server/src/server.rs index 9c546c3e..9df18ed4 100644 --- a/crates/http-server/src/server/mod.rs +++ b/crates/http-server/src/server.rs @@ -1,14 +1,10 @@ -pub mod config; -pub mod plugin; - -use std::convert::Infallible; use std::net::{IpAddr, Ipv4Addr, SocketAddr}; use std::path::PathBuf; use std::str::FromStr; use std::sync::Arc; use anyhow::Result; -use http_body_util::{BodyExt, Full}; +use http_body_util::Full; use hyper::body::{Bytes, Incoming}; use hyper::server::conn::http1; use hyper::{Method, Request, Response}; @@ -16,12 +12,14 @@ use hyper_util::rt::TokioIo; use hyper_util::service::TowerToHyperService; use local_ip_address::local_ip; use tokio::net::TcpListener; -use tokio::runtime::Runtime; use tower::ServiceBuilder; use tower_http::cors::{Any, CorsLayer}; -use self::config::Config; -use self::plugin::PluginStore; +use crate::config::Config; +use crate::handler::file_explorer::FileExplorer; + +pub type HttpRequest = Request; +pub type HttpResponse = Response>; const ALL_INTERFACES_IPV4: Ipv4Addr = Ipv4Addr::new(0, 0, 0, 0); @@ -34,12 +32,9 @@ impl Server { Server { config } } - pub async fn run(self, rt: Arc) -> Result<()> { + pub async fn run(&self) -> Result<()> { let addr = SocketAddr::from((self.config.host, self.config.port)); let listener = TcpListener::bind(addr).await?; - let plugin_store = Arc::new(PluginStore::new()); - let config = PathBuf::from_str("./config.toml")?; - let handle = Arc::new(rt.handle().to_owned()); println!("Listening on http://{}", addr); @@ -49,16 +44,13 @@ impl Server { } } - unsafe { - plugin_store - .load(Arc::clone(&handle), config, "file_explorer.plugin.httprs") - .await?; - } + let file_explorer = FileExplorer::new(PathBuf::from_str("./").unwrap()); + let file_explorer = Arc::new(file_explorer); loop { + let file_explorer = Arc::clone(&file_explorer); let (stream, _) = listener.accept().await?; let io = TokioIo::new(stream); - let plugin_store = Arc::clone(&plugin_store); let cors = if self.config.cors { Some( CorsLayer::new() @@ -69,24 +61,9 @@ impl Server { None }; - handle.spawn(async move { - let plugin_store = Arc::clone(&plugin_store); + tokio::spawn(async move { let svc = tower::service_fn(|req: Request| async { - let (parts, body) = req.into_parts(); - let body = body.collect().await.unwrap().to_bytes(); - - match plugin_store.run("file-explorer", parts, body).await { - Ok(res) => Ok::< - Response>, - Infallible, - >(res), - Err(err) => { - eprintln!("Error: {:?}", err); - Ok(Response::new(Full::new(Bytes::from( - "Internal Server Error", - )))) - } - } + file_explorer.handle(req).await }); let svc = ServiceBuilder::new().option_layer(cors).service(svc); diff --git a/crates/http-server/src/server/plugin.rs b/crates/http-server/src/server/plugin.rs deleted file mode 100644 index a9a302ae..00000000 --- a/crates/http-server/src/server/plugin.rs +++ /dev/null @@ -1,140 +0,0 @@ -use std::collections::HashMap; -use std::io::{Error as IOError, Result as IOResult}; -use std::path::PathBuf; -use std::sync::Arc; - -use async_trait::async_trait; -use http::request::Parts; -use http_body_util::Full; -use hyper::body::Bytes; -use hyper::Response; -use libloading::Library; -use tokio::runtime::Handle; -use tokio::sync::Mutex; - -use http_server_plugin::{Plugin, PluginDeclaration, PluginError, CORE_VERSION, RUSTC_VERSION}; - -use crate::plugins_path; - -/// A proxy object which wraps a [`Plugin`] and makes sure it can't outlive -/// the library it came from. -#[derive(Clone)] -pub struct PluginProxy { - function: Arc, - _lib: Arc, -} - -#[async_trait] -impl Plugin for PluginProxy { - async fn call(&self, parts: Parts, bytes: Bytes) -> Result>, PluginError> { - self.function.call(parts, bytes).await - } -} - -pub struct PluginStore { - functions: Mutex>, - handle: Arc, - libraries: Mutex>>, -} - -impl Default for PluginStore { - fn default() -> Self { - Self::new() - } -} - -impl PluginStore { - pub fn new() -> Self { - let handle = Arc::new(Handle::current()); - - Self { - functions: Mutex::new(HashMap::default()), - handle, - libraries: Mutex::new(Vec::new()), - } - } - - /// Loads a plugin from the given path. - /// - /// # Safety - /// - /// This function is unsafe because it loads a shared library and calls - /// functions from it. - pub async unsafe fn load( - &self, - rt_handle: Arc, - config_path: PathBuf, - plugin_filename: &str, - ) -> IOResult<()> { - let plugin_path = plugins_path() - .map_err(|err| IOError::other(format!("Failed to retrieve plugin path: {err}")))? - .join(plugin_filename); - let library = Library::new(&plugin_path).map_err(|err| { - IOError::other(format!("Failed to load plugin from {plugin_path:?}: {err}")) - })?; - let library = Arc::new(library); - let decl = library - .get::<*mut PluginDeclaration>(b"PLUGIN_DECLARATION\0") - .unwrap() - .read(); - - if decl.rustc_version != RUSTC_VERSION || decl.core_version != CORE_VERSION { - return Err(IOError::other("Version Mismatch.")); - } - - let mut registrar = PluginRegistrar::new(Arc::clone(&library)); - - (decl.register)(config_path, Arc::clone(&rt_handle), &mut registrar); - - self.functions.lock().await.extend(registrar.functions); - self.libraries.lock().await.push(library); - - Ok(()) - } - - async fn get(&self, func: &str) -> Option { - self.functions.lock().await.get(func).cloned() - } - - pub async fn run( - &self, - plugin: &str, - parts: Parts, - bytes: Bytes, - ) -> Result>, PluginError> { - let function_proxy = self.get(plugin).await.unwrap(); - let join_handle = self - .handle - .spawn(async move { function_proxy.call(parts, bytes).await }) - .await; - - join_handle.map_err(|err| PluginError::SpawnError { - err: err.to_string(), - })? - } -} - -struct PluginRegistrar { - functions: HashMap, - lib: Arc, -} - -impl PluginRegistrar { - fn new(lib: Arc) -> PluginRegistrar { - PluginRegistrar { - lib, - functions: HashMap::default(), - } - } -} - -impl http_server_plugin::PluginRegistrar for PluginRegistrar { - fn register_function(&mut self, name: &str, function: Arc) { - let proxy = PluginProxy { - function, - _lib: Arc::clone(&self.lib), - }; - - self.functions.insert(name.to_string(), proxy); - } -}