diff --git a/Cargo.lock b/Cargo.lock index d5523f5..d34bed2 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -19,9 +19,9 @@ checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" [[package]] name = "aes" -version = "0.8.3" +version = "0.8.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ac1f845298e95f983ff1944b728ae08b8cebab80d684f0a832ed0fc74dfa27e2" +checksum = "b169f7a6d4742236a0a00c541b845991d0ac43e546831af1249753ab4c3aa3a0" dependencies = [ "cfg-if", "cipher", @@ -30,20 +30,9 @@ dependencies = [ [[package]] name = "ahash" -version = "0.7.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a824f2aa7e75a0c98c5a504fceb80649e9c35265d44525b5f94de4771a395cd" -dependencies = [ - "getrandom", - "once_cell", - "version_check", -] - -[[package]] -name = "ahash" -version = "0.8.7" +version = "0.8.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77c3a9648d43b9cd48db467b3f87fdd6e146bcc88ab0180006cef2179fe11d01" +checksum = "e89da841a80418a9b391ebaea17f5c112ffaaa96f621d2c285b5174da76b9011" dependencies = [ "cfg-if", "once_cell", @@ -53,24 +42,24 @@ dependencies = [ [[package]] name = "aho-corasick" -version = "1.0.5" +version = "1.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c378d78423fdad8089616f827526ee33c19f2fddbd5de1629152c9593ba4783" +checksum = "8e60d3430d3a69478ad0993f19238d2df97c507009a52b3c10addcd7f6bcb916" dependencies = [ "memchr", ] [[package]] name = "allocator-api2" -version = "0.2.16" +version = "0.2.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0942ffc6dcaadf03badf6e6a2d0228460359d5e34b57ccdc720b7382dfbd5ec5" +checksum = "5c6cb57a04249c6480766f7f7cef5467412af1490f8d1e243141daddada3264f" [[package]] name = "alloy-primitives" -version = "0.7.4" +version = "0.7.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db8aa973e647ec336810a9356af8aea787249c9d00b1525359f3db29a68d231b" +checksum = "f783611babedbbe90db3478c120fb5f5daacceffc210b39adc0af4fe0da70bad" dependencies = [ "bytes", "cfg-if", @@ -100,51 +89,51 @@ dependencies = [ [[package]] name = "anstream" -version = "0.3.2" +version = "0.6.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ca84f3628370c59db74ee214b3263d58f9aadd9b4fe7e711fd87dc452b7f163" +checksum = "418c75fa768af9c03be99d17643f93f79bbba589895012a80e3452a19ddda15b" dependencies = [ "anstyle", "anstyle-parse", "anstyle-query", "anstyle-wincon", "colorchoice", - "is-terminal", + "is_terminal_polyfill", "utf8parse", ] [[package]] name = "anstyle" -version = "1.0.1" +version = "1.0.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3a30da5c5f2d5e72842e00bcb57657162cdabef0931f40e2deb9b4140440cecd" +checksum = "038dfcf04a5feb68e9c60b21c9625a54c2c0616e79b72b0fd87075a056ae1d1b" [[package]] name = "anstyle-parse" -version = "0.2.1" +version = "0.2.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "938874ff5980b03a87c5524b3ae5b59cf99b1d6bc836848df7bc5ada9643c333" +checksum = "c03a11a9034d92058ceb6ee011ce58af4a9bf61491aa7e1e59ecd24bd40d22d4" dependencies = [ "utf8parse", ] [[package]] name = "anstyle-query" -version = "1.0.0" +version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ca11d4be1bab0c8bc8734a9aa7bf4ee8316d462a08c6ac5052f888fef5b494b" +checksum = "ad186efb764318d35165f1758e7dcef3b10628e26d41a44bc5550652e6804391" dependencies = [ - "windows-sys 0.48.0", + "windows-sys 0.52.0", ] [[package]] name = "anstyle-wincon" -version = "1.0.2" +version = "3.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c677ab05e09154296dd37acecd46420c17b9713e8366facafa8fc0885167cf4c" +checksum = "61a38449feb7068f52bb06c12759005cf459ee52bb4adc1d5a7c4322d716fb19" dependencies = [ "anstyle", - "windows-sys 0.48.0", + "windows-sys 0.52.0", ] [[package]] @@ -167,7 +156,7 @@ dependencies = [ "digest", "itertools 0.10.5", "num-bigint", - "num-traits 0.2.16", + "num-traits 0.2.19", "paste", "rustc_version", "zeroize", @@ -190,7 +179,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7abe79b0e4288889c4574159ab790824d0033b9fdcb2a112a3182fac2e514565" dependencies = [ "num-bigint", - "num-traits 0.2.16", + "num-traits 0.2.19", "proc-macro2", "quote", "syn 1.0.109", @@ -213,7 +202,7 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "94893f1e0c6eeab764ade8dc4c0db24caf4fe7cbbaafc0eba0a9030f447b5185" dependencies = [ - "num-traits 0.2.16", + "num-traits 0.2.19", "rand", ] @@ -257,14 +246,13 @@ dependencies = [ [[package]] name = "auto_impl" -version = "1.1.0" +version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fee3da8ef1276b0bee5dd1c7258010d8fffd31801447323115a25560e1327b89" +checksum = "3c87f3f15e7794432337fc718554eaa4dc8f04c9677a950ffe366f20a162ae42" dependencies = [ - "proc-macro-error", "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.48", ] [[package]] @@ -357,7 +345,7 @@ checksum = "a6773ddc0eafc0e509fb60e48dff7f450f8e674a0686ae8605e8d9901bd5eefa" dependencies = [ "num-bigint", "num-integer", - "num-traits 0.2.16", + "num-traits 0.2.19", "serde", ] @@ -454,20 +442,20 @@ dependencies = [ "lazy_static", "num-bigint", "num-integer", - "num-traits 0.2.16", + "num-traits 0.2.19", "serde", ] [[package]] name = "cairo-lang-casm" -version = "2.6.3" +version = "2.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "10d9c31baeb6b52586b5adc88f01e90f86389d63d94363c562de5c79352e545b" +checksum = "6296d5748288d9fb97175d31aff9f68ea3f602456923895e512b078e9a2210a0" dependencies = [ "cairo-lang-utils", "indoc", "num-bigint", - "num-traits 0.2.16", + "num-traits 0.2.19", "parity-scale-codec", "serde", ] @@ -497,18 +485,18 @@ dependencies = [ [[package]] name = "cairo-lang-debug" -version = "2.6.3" +version = "2.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a761eb8e31ea65a2dd45f729c74f1770315f97124dad93d1f6853a10d460c6b" +checksum = "2a3cbf67fd766cb7ed48b72e6abf7041857518c9b9fd42475a60c138671c6603" dependencies = [ "cairo-lang-utils", ] [[package]] name = "cairo-lang-defs" -version = "2.6.3" +version = "2.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6d60bc5d72fe7a95ba34e041dcbdf1cf3bfccb87008a515514b74913fa8ff05" +checksum = "7b284e41dfc158dfbdc02612dbfdb27a55547d23063bdc53105eeec41d8df006" dependencies = [ "cairo-lang-debug", "cairo-lang-diagnostics", @@ -523,9 +511,9 @@ dependencies = [ [[package]] name = "cairo-lang-diagnostics" -version = "2.6.3" +version = "2.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "356089e1b0a0ba9e115566191745613b3806a20259ad76764df82ab534d5412a" +checksum = "c6314b24901af8be75cd0e1363e3ff1a8020066372501f4cfc9161726b06ec2a" dependencies = [ "cairo-lang-debug", "cairo-lang-filesystem", @@ -535,9 +523,9 @@ dependencies = [ [[package]] name = "cairo-lang-eq-solver" -version = "2.6.3" +version = "2.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fc43246cc2e5afd5a028bcdd63876ac3f8b1f4fb3ff785daaa0f0fbb51c9d906" +checksum = "4f95f5c8f7ea75580d164b5304251022e3d47f43fc1c778a01381b55ca9f268c" dependencies = [ "cairo-lang-utils", "good_lp", @@ -545,9 +533,9 @@ dependencies = [ [[package]] name = "cairo-lang-filesystem" -version = "2.6.3" +version = "2.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6bcb9a4a40e53fa099774bd08bbcc3430f51213cc7fb1b50c2e9d01155731798" +checksum = "d3e58b80f0b413ef1320358fde1a0877fc3fbf740f5cead0de3e947a1bc3bfd4" dependencies = [ "cairo-lang-debug", "cairo-lang-utils", @@ -559,9 +547,9 @@ dependencies = [ [[package]] name = "cairo-lang-lowering" -version = "2.6.3" +version = "2.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ba60e1e2477aa0f610ccf29189097d580464607c94b51741e1c18e64d6cee5f" +checksum = "abe6d604a06ea96c05b3666f2e8fac63cb8709e13667de272912f81db004a16b" dependencies = [ "cairo-lang-debug", "cairo-lang-defs", @@ -576,7 +564,7 @@ dependencies = [ "itertools 0.11.0", "log", "num-bigint", - "num-traits 0.2.16", + "num-traits 0.2.19", "once_cell", "salsa", "smol_str", @@ -584,9 +572,9 @@ dependencies = [ [[package]] name = "cairo-lang-parser" -version = "2.6.3" +version = "2.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f16ba1535e0cc5e79c2eff6592859bbdac03dc53d4dcdd26dbdbc04a77c3f5c" +checksum = "eaf1c279de47a77422f81b8a98023cd523cf0ae79f7153d60c4cf8b62b8ece2f" dependencies = [ "cairo-lang-diagnostics", "cairo-lang-filesystem", @@ -596,7 +584,7 @@ dependencies = [ "colored", "itertools 0.11.0", "num-bigint", - "num-traits 0.2.16", + "num-traits 0.2.19", "salsa", "smol_str", "unescaper", @@ -604,9 +592,9 @@ dependencies = [ [[package]] name = "cairo-lang-plugins" -version = "2.6.3" +version = "2.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "81c8cf6e0ee3d6b19429cc1663738b22f1ecea7d51bf7452e8e1086f08798baf" +checksum = "a1177a07498bdf45cba62f0c727388ff7433072847dbf701c58fa3c3e358154e" dependencies = [ "cairo-lang-defs", "cairo-lang-diagnostics", @@ -623,9 +611,9 @@ dependencies = [ [[package]] name = "cairo-lang-proc-macros" -version = "2.6.3" +version = "2.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67f9da66325ce7ed6c002360f26106fe79deb9f8a2fca30abdbb8d388da7bb46" +checksum = "0c90d812ec983c5a8e3173aca3fc55036b9739201c89f30271ee14a4c1189379" dependencies = [ "cairo-lang-debug", "quote", @@ -634,9 +622,9 @@ dependencies = [ [[package]] name = "cairo-lang-project" -version = "2.6.3" +version = "2.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e198af1ab3d05c7fb8b6a9a7a2e9bce245a6c855df5f770b751d29874a23b152" +checksum = "3985495d7e9dc481e97135d7139cfa098024351fb51d5feef8366b5fbc104807" dependencies = [ "cairo-lang-filesystem", "cairo-lang-utils", @@ -648,9 +636,9 @@ dependencies = [ [[package]] name = "cairo-lang-semantic" -version = "2.6.3" +version = "2.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d7df81521c2125e3e95b683cc99374db1aebd7ddb317c5ca3dd92a235a9eb13" +checksum = "d5cfadbb9ca3479a6b5c02c0a125a5747835ba57a2de9c4e9764f42d85abe059" dependencies = [ "cairo-lang-debug", "cairo-lang-defs", @@ -665,7 +653,7 @@ dependencies = [ "indoc", "itertools 0.11.0", "num-bigint", - "num-traits 0.2.16", + "num-traits 0.2.19", "once_cell", "salsa", "smol_str", @@ -687,7 +675,7 @@ dependencies = [ "lalrpop", "lalrpop-util", "num-bigint", - "num-traits 0.2.16", + "num-traits 0.2.19", "regex", "salsa", "serde", @@ -708,7 +696,7 @@ dependencies = [ "cairo-lang-sierra-type-size", "cairo-lang-utils", "itertools 0.11.0", - "num-traits 0.2.16", + "num-traits 0.2.19", "thiserror", ] @@ -723,7 +711,7 @@ dependencies = [ "cairo-lang-sierra-type-size", "cairo-lang-utils", "itertools 0.11.0", - "num-traits 0.2.16", + "num-traits 0.2.19", "thiserror", ] @@ -744,7 +732,7 @@ dependencies = [ "cairo-lang-syntax", "cairo-lang-utils", "itertools 0.11.0", - "num-traits 0.2.16", + "num-traits 0.2.19", "once_cell", "salsa", "smol_str", @@ -767,7 +755,7 @@ dependencies = [ "indoc", "itertools 0.11.0", "num-bigint", - "num-traits 0.2.16", + "num-traits 0.2.19", "thiserror", ] @@ -827,7 +815,7 @@ dependencies = [ "itertools 0.11.0", "num-bigint", "num-integer", - "num-traits 0.2.16", + "num-traits 0.2.19", "once_cell", "serde", "serde_json", @@ -839,15 +827,15 @@ dependencies = [ [[package]] name = "cairo-lang-syntax" -version = "2.6.3" +version = "2.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8262c426a57e1e5ec297db24278464841500613445e2cb1c43d5f71ad91ee8d6" +checksum = "4c62f5bd74e249636e7c48d8b95e6cc0ee991206d4a6cbe5c2624184a828e70b" dependencies = [ "cairo-lang-debug", "cairo-lang-filesystem", "cairo-lang-utils", "num-bigint", - "num-traits 0.2.16", + "num-traits 0.2.19", "salsa", "smol_str", "unescaper", @@ -855,9 +843,9 @@ dependencies = [ [[package]] name = "cairo-lang-syntax-codegen" -version = "2.6.3" +version = "2.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70e2d692eae4bb4179a4a1148fd5eb738a91653d86750c813658ffad4a99fa97" +checksum = "a744747e9ab03b65480265304490f3e29d99e4cb297e39d0e6fdb047c1bc86a7" dependencies = [ "genco", "xshell", @@ -865,24 +853,24 @@ dependencies = [ [[package]] name = "cairo-lang-utils" -version = "2.6.3" +version = "2.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bf733a7cdc4166d0baf0ed8a98d9ada827daee6653b37d9326e334e53481c6d3" +checksum = "e6f98e8769412907ceb106c21c70907cc0c87ca0a2a44c82b6229a695a6f9b48" dependencies = [ "hashbrown 0.14.5", - "indexmap 2.2.2", + "indexmap 2.2.6", "itertools 0.11.0", "num-bigint", - "num-traits 0.2.16", + "num-traits 0.2.19", "schemars", "serde", ] [[package]] name = "cairo-vm" -version = "0.9.2" +version = "0.9.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fd569684da80d747273613d5c809e4f81bf6f6b1b64d0301b12bac8f2fb8ffb1" +checksum = "d90d260c5b0c0812f02fcbdc21eb0d5908fcecdca888fb779b54c3967f7f88bf" dependencies = [ "anyhow", "bincode", @@ -898,8 +886,9 @@ dependencies = [ "num-bigint", "num-integer", "num-prime", - "num-traits 0.2.16", + "num-traits 0.2.19", "rand", + "rust_decimal", "serde", "serde_json", "sha2", @@ -930,19 +919,25 @@ version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" +[[package]] +name = "cfg_aliases" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fd16c4719339c4530435d38e511904438d07cce7950afa3718a84ac36c10e89e" + [[package]] name = "chrono" -version = "0.4.31" +version = "0.4.38" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f2c685bad3eb3d45a01354cedb7d5faa66194d1d58ba6e267a8de788f79db38" +checksum = "a21f936df1771bf62b77f047b726c4625ff2e8aa607c01ec06e5a05bd8463401" dependencies = [ "android-tzdata", "iana-time-zone", "js-sys", - "num-traits 0.2.16", + "num-traits 0.2.19", "serde", "wasm-bindgen", - "windows-targets 0.48.2", + "windows-targets 0.52.0", ] [[package]] @@ -957,20 +952,19 @@ dependencies = [ [[package]] name = "clap" -version = "4.3.21" +version = "4.5.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c27cdf28c0f604ba3f512b0c9a409f8de8513e4816705deb0498b627e7c3a3fd" +checksum = "5db83dced34638ad474f39f250d7fea9598bdd239eaced1bdf45d597da0f433f" dependencies = [ "clap_builder", "clap_derive", - "once_cell", ] [[package]] name = "clap_builder" -version = "4.3.21" +version = "4.5.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "08a9f1ab5e9f01a9b81f202e8562eb9a10de70abf9eaeac1be465c28b75aa4aa" +checksum = "f7e204572485eb3fbf28f871612191521df159bc3e15a9f5064c66dba3a8c05f" dependencies = [ "anstream", "anstyle", @@ -980,11 +974,11 @@ dependencies = [ [[package]] name = "clap_derive" -version = "4.3.12" +version = "4.5.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "54a9bb5758fc5dfe728d1019941681eccaf0cf8a4189b692a0ee2f2ecf90a050" +checksum = "c780290ccf4fb26629baa7a1081e68ced113f1d3ec302fa5948f1c381ebf06c6" dependencies = [ - "heck 0.4.1", + "heck 0.5.0", "proc-macro2", "quote", "syn 2.0.48", @@ -992,15 +986,15 @@ dependencies = [ [[package]] name = "clap_lex" -version = "0.5.0" +version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2da6da31387c7e4ef160ffab6d5e7f00c42626fe39aea70a7b0f1773f7dd6c1b" +checksum = "4b82cf0babdbd58558212896d1a4272303a57bdb245c2bf1147185fb45640e70" [[package]] name = "colorchoice" -version = "1.0.0" +version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "acbf1af155f9b9ef647e42cdc158db4b64a1b61f743629225fde6f3e0be2a7c7" +checksum = "0b6a852b24ab71dffc585bcb46eaf7959d175cb865a7152e35b348d1b2960422" [[package]] name = "colored" @@ -1043,9 +1037,9 @@ checksum = "32b13ea120a812beba79e34316b3942a857c86ec1593cb34f27bb28272ce2cca" [[package]] name = "const-hex" -version = "1.10.0" +version = "1.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a5104de16b218eddf8e34ffe2f86f74bfa4e61e95a1b89732fccf6325efd0557" +checksum = "94fb8a24a26d37e1ffd45343323dc9fe6654ceea44c12f2fcb3d7ac29e610bc6" dependencies = [ "cfg-if", "cpufeatures", @@ -1107,18 +1101,18 @@ checksum = "e496a50fda8aacccc86d7529e2c1e0892dbd0f898a6b5645b5561b89c3210efa" [[package]] name = "cpufeatures" -version = "0.2.9" +version = "0.2.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a17b76ff3a4162b0b27f354a0c87015ddad39d35f9c0c36607a3bdd175dde1f1" +checksum = "53fe5e26ff1b7aef8bca9c6080520cfb8d9333c7568e1829cef191a9723e5504" dependencies = [ "libc", ] [[package]] name = "crc32fast" -version = "1.3.2" +version = "1.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b540bd8bc810d3885c6ea91e2018302f68baba2129ab3e88f32389ee9370880d" +checksum = "a97769d94ddab943e4510d138150169a2758b5ef3eb191a9ee688de3e23ef7b3" dependencies = [ "cfg-if", ] @@ -1144,9 +1138,9 @@ dependencies = [ [[package]] name = "crossbeam-utils" -version = "0.8.19" +version = "0.8.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "248e3bacc7dc6baa3b21e405ee045c3047101a49145e7e9eca583ab4c2ca5345" +checksum = "22ec99545bb0ed0ea7bb9b8e1e9122ea386ff8a48c0922e43f36d45ab09e0e80" [[package]] name = "crunchy" @@ -1156,9 +1150,9 @@ checksum = "7a81dae078cea95a014a339291cec439d2f232ebe854a9d672b796c6afafa9b7" [[package]] name = "crypto-bigint" -version = "0.5.3" +version = "0.5.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "740fe28e594155f10cfc383984cbefd529d7396050557148f79cb0f621204124" +checksum = "0dc92fb57ca44df6db8059111ab3af99a63d5d0f8375d9972e319a379c6bab76" dependencies = [ "generic-array", "subtle", @@ -1186,19 +1180,19 @@ dependencies = [ [[package]] name = "ctrlc" -version = "3.4.1" +version = "3.4.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82e95fbd621905b854affdc67943b043a0fbb6ed7385fd5a25650d19a8a6cfdf" +checksum = "672465ae37dc1bc6380a6547a8883d5dd397b0f1faaad4f265726cc7042a5345" dependencies = [ "nix", - "windows-sys 0.48.0", + "windows-sys 0.52.0", ] [[package]] name = "darling" -version = "0.20.3" +version = "0.20.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0209d94da627ab5605dcccf08bb18afa5009cfbef48d8a8b7d7bdbc79be25c5e" +checksum = "83b2eb4d90d12bdda5ed17de686c2acb4c57914f8f921b8da7e112b5a36f3fe1" dependencies = [ "darling_core", "darling_macro", @@ -1206,9 +1200,9 @@ dependencies = [ [[package]] name = "darling_core" -version = "0.20.3" +version = "0.20.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "177e3443818124b357d8e76f53be906d60937f0d3a90773a664fa63fa253e621" +checksum = "622687fe0bac72a04e5599029151f5796111b90f1baaa9b544d807a5e31cd120" dependencies = [ "fnv", "ident_case", @@ -1220,9 +1214,9 @@ dependencies = [ [[package]] name = "darling_macro" -version = "0.20.3" +version = "0.20.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "836a9bbc7ad63342d6d6e7b815ccab164bc77a2d95d84bc3117a8c0d5c98e2d5" +checksum = "733cabb43482b1a1b53eee8583c2b9e8684d592215ea83efd305dd31bc2f0178" dependencies = [ "darling_core", "quote", @@ -1231,10 +1225,11 @@ dependencies = [ [[package]] name = "deranged" -version = "0.3.8" +version = "0.3.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f2696e8a945f658fd14dc3b87242e6b80cd0f36ff04ea560fa39082368847946" +checksum = "b42b6fa04a440b495c8b04d0e71b707c585f83cb9cb28cf8cd0d976c315e31b4" dependencies = [ + "powerfmt", "serde", ] @@ -1262,12 +1257,6 @@ dependencies = [ "syn 1.0.109", ] -[[package]] -name = "diff" -version = "0.1.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56254986775e3233ffa9c4d7d3faaf6d36a2c09d30b20687e9f88bc8bafc16c8" - [[package]] name = "digest" version = "0.10.7" @@ -1323,9 +1312,9 @@ dependencies = [ [[package]] name = "dyn-clone" -version = "1.0.16" +version = "1.0.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "545b22097d44f8a9581187cdf93de7a71e4722bf51200cfaba810865b49a495d" +checksum = "0d6ef0072f8a535281e4876be788938b528e9a1d43900b82c2569af7da799125" [[package]] name = "either" @@ -1335,9 +1324,9 @@ checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" [[package]] name = "ena" -version = "0.14.2" +version = "0.14.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c533630cf40e9caa44bd91aadc88a75d75a4c3a12b4cfde353cbed41daa1e1f1" +checksum = "3d248bdd43ce613d87415282f69b9bb99d947d290b10962dd6c56233312c2ad5" dependencies = [ "log", ] @@ -1353,9 +1342,9 @@ dependencies = [ [[package]] name = "env_logger" -version = "0.10.0" +version = "0.10.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85cdab6a89accf66733ad5a1693a4dcced6aeff64602b634530dd73c1f3ee9f0" +checksum = "4cd405aab171cb85d6735e5c8d9db038c17d3ca007a4d2c25f337935c3d90580" dependencies = [ "humantime", "is-terminal", @@ -1455,9 +1444,9 @@ checksum = "0ce7134b9999ecaf8bcd65542e436736ef32ddca1b3e06094cb6ec5755203b80" [[package]] name = "flate2" -version = "1.0.27" +version = "1.0.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c6c98ee8095e9d1dcbf2fcc6d95acccb90d1c81db1e44725c6a984b1dbdfb010" +checksum = "5f54427cfd1c7829e2a139fcefea601bf088ebca651d2bf53ebc600eac295dae" dependencies = [ "crc32fast", "miniz_oxide", @@ -1538,9 +1527,9 @@ dependencies = [ [[package]] name = "genco" -version = "0.17.8" +version = "0.17.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "98d7af598790738fee616426e669360fa361273b1b9c9b7f30c92fa627605cad" +checksum = "afac3cbb14db69ac9fef9cdb60d8a87e39a7a527f85a81a923436efa40ad42c6" dependencies = [ "genco-macros", "relative-path", @@ -1549,9 +1538,9 @@ dependencies = [ [[package]] name = "genco-macros" -version = "0.17.8" +version = "0.17.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d4cf186fea4af17825116f72932fe52cce9a13bae39ff63b4dc0cfdb3fb4bde1" +checksum = "553630feadf7b76442b0849fd25fdf89b860d933623aec9693fed19af0400c78" dependencies = [ "proc-macro2", "quote", @@ -1589,9 +1578,9 @@ checksum = "b6c80984affa11d98d1b88b66ac8853f143217b399d3c74116778ff8fdb4ed2e" [[package]] name = "good_lp" -version = "1.7.0" +version = "1.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa124423ded10046a849fa0ae9747c541895557f1af177e0890b09879e7e9e7d" +checksum = "3198bd13dea84c76a64621d6ee8ee26a4960a9a0d538eca95ca8f1320a469ac9" dependencies = [ "fnv", "minilp", @@ -1679,9 +1668,6 @@ name = "hashbrown" version = "0.12.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888" -dependencies = [ - "ahash 0.7.7", -] [[package]] name = "hashbrown" @@ -1689,7 +1675,7 @@ version = "0.14.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1" dependencies = [ - "ahash 0.8.7", + "ahash", "allocator-api2", "serde", ] @@ -1709,11 +1695,17 @@ version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8" +[[package]] +name = "heck" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" + [[package]] name = "hermit-abi" -version = "0.3.2" +version = "0.3.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "443144c8cdadd93ebf52ddb4056d257f5b52c04d3c804e657d19eb73fc33668b" +checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" [[package]] name = "hex" @@ -1834,16 +1826,16 @@ dependencies = [ [[package]] name = "iana-time-zone" -version = "0.1.57" +version = "0.1.60" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2fad5b825842d2b38bd206f3e81d6957625fd7f0a361e345c30e01a0ae2dd613" +checksum = "e7ffbb5a1b541ea2561f8c41c087286cc091e21e556a4f09a8f6cbf17b69b141" dependencies = [ "android_system_properties", "core-foundation-sys", "iana-time-zone-haiku", "js-sys", "wasm-bindgen", - "windows", + "windows-core", ] [[package]] @@ -1934,9 +1926,9 @@ dependencies = [ [[package]] name = "indexmap" -version = "2.2.2" +version = "2.2.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "824b2ae422412366ba479e8111fd301f7b5faece8149317bb81925979a53f520" +checksum = "168fb715dda47215e360912c096649d23d58bf392ac62f73919e831745e40f26" dependencies = [ "equivalent", "hashbrown 0.14.5", @@ -1945,9 +1937,9 @@ dependencies = [ [[package]] name = "indoc" -version = "2.0.4" +version = "2.0.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e186cfbae8084e513daff4240b4797e342f988cecda4fb6c939150f96315fd8" +checksum = "b248f5224d1d606005e02c97f5aa4e88eeb230488bcc03bc9ca4d7991399f2b5" [[package]] name = "inout" @@ -1960,9 +1952,9 @@ dependencies = [ [[package]] name = "instant" -version = "0.1.12" +version = "0.1.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a5bbe824c507c5da5956355e86a746d82e0e1464f65d862cc5e71da70e94b2c" +checksum = "e0242819d153cba4b4b05a5a8f2a7e9bbf97b6055b2a002b395c96b5ff3c0222" dependencies = [ "cfg-if", ] @@ -1975,15 +1967,21 @@ checksum = "28b29a3cd74f0f4598934efe3aeba42bae0eb4680554128851ebbecb02af14e6" [[package]] name = "is-terminal" -version = "0.4.9" +version = "0.4.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cb0889898416213fab133e1d33a0e5858a48177452750691bde3666d0fdbaf8b" +checksum = "f23ff5ef2b80d608d61efee834934d862cd92461afc0560dedf493e4c033738b" dependencies = [ "hermit-abi", - "rustix", - "windows-sys 0.48.0", + "libc", + "windows-sys 0.52.0", ] +[[package]] +name = "is_terminal_polyfill" +version = "1.70.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8478577c03552c21db0e2724ffb8986a5ce7af88107e6be5d2ee6e158c12800" + [[package]] name = "itertools" version = "0.10.5" @@ -2069,43 +2067,42 @@ dependencies = [ [[package]] name = "keccak" -version = "0.1.4" +version = "0.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f6d5ed8676d904364de097082f4e7d240b571b67989ced0240f08b7f966f940" +checksum = "ecc2af9a1119c51f12a14607e783cb977bde58bc069ff0c3da1095e635d70654" dependencies = [ "cpufeatures", ] [[package]] name = "lalrpop" -version = "0.20.0" +version = "0.20.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da4081d44f4611b66c6dd725e6de3169f9f63905421e8626fcb86b6a898998b8" +checksum = "55cb077ad656299f160924eb2912aa147d7339ea7d69e1b5517326fdcec3c1ca" dependencies = [ "ascii-canvas", "bit-set", - "diff", "ena", - "is-terminal", - "itertools 0.10.5", + "itertools 0.11.0", "lalrpop-util", "petgraph", "pico-args", "regex", - "regex-syntax", + "regex-syntax 0.8.4", "string_cache", "term", "tiny-keccak", "unicode-xid", + "walkdir", ] [[package]] name = "lalrpop-util" -version = "0.20.0" +version = "0.20.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f35c735096c0293d313e8f2a641627472b83d01b937177fe76e5e2708d31e0d" +checksum = "507460a910eb7b32ee961886ff48539633b788a36b65692b95f225b844c82553" dependencies = [ - "regex", + "regex-automata 0.4.7", ] [[package]] @@ -2131,9 +2128,9 @@ checksum = "4ec2a862134d2a7d32d7983ddcdd1c4923530833c9f2ea1a44fc5fa473989058" [[package]] name = "libmimalloc-sys" -version = "0.1.35" +version = "0.1.38" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3979b5c37ece694f1f5e51e7ecc871fdb0f517ed04ee45f88d15d6d553cb9664" +checksum = "0e7bb23d733dfcc8af652a78b7bf232f0e967710d044732185e561e47c0336b6" dependencies = [ "cc", "libc", @@ -2147,9 +2144,9 @@ checksum = "01cda141df6706de531b6c46c3a33ecca755538219bd484262fa09410c13539c" [[package]] name = "lock_api" -version = "0.4.10" +version = "0.4.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1cc9717a20b1bb222f333e6a92fd32f7d8a18ddc5a3191a11af45dcbf4dcd16" +checksum = "07af8b9cdd281b7915f413fa73f29ebd5d55d0d3f0155584dade1ff18cea1b17" dependencies = [ "autocfg", "scopeguard", @@ -2163,11 +2160,11 @@ checksum = "b5e6163cb8c49088c2c36f57875e58ccd8c87c7427f7fbd50ea6710b2f3f2e8f" [[package]] name = "lru" -version = "0.7.8" +version = "0.12.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e999beba7b6e8345721bd280141ed958096a2e4abdf74f67ff4ce49b4b54e47a" +checksum = "d3262e75e648fce39813cb56ac41f3c3e3f65217ebf3844d818d1f9398cfb0dc" dependencies = [ - "hashbrown 0.12.3", + "hashbrown 0.14.5", ] [[package]] @@ -2196,15 +2193,15 @@ dependencies = [ [[package]] name = "memchr" -version = "2.5.0" +version = "2.7.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2dffe52ecf27772e601905b7522cb4ef790d2cc203488bbd0e2fe85fcb74566d" +checksum = "6d0d8b92cd8358e8d229c11df9358decae64d137c5be540952c5ca7b25aea768" [[package]] name = "mimalloc" -version = "0.1.39" +version = "0.1.42" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa01922b5ea280a911e323e4d2fd24b7fe5cc4042e0d2cda3c40775cdc4bdc9c" +checksum = "e9186d86b79b52f4a77af65604b51225e8db1d6ee7e3f41aec1e40829c71a176" dependencies = [ "libmimalloc-sys", ] @@ -2260,7 +2257,7 @@ dependencies = [ "matrixmultiply", "num-complex", "num-integer", - "num-traits 0.2.16", + "num-traits 0.2.19", "rawpointer", ] @@ -2272,18 +2269,19 @@ checksum = "27b02d87554356db9e9a873add8782d4ea6e3e58ea071a9adb9a2e8ddb884a8b" [[package]] name = "new_debug_unreachable" -version = "1.0.4" +version = "1.0.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e4a24736216ec316047a1fc4252e27dabb04218aa4a3f37c6e7ddbf1f9782b54" +checksum = "650eef8c711430f1a879fdd01d4745a7deea475becfb90269c06775983bbf086" [[package]] name = "nix" -version = "0.27.1" +version = "0.28.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2eb04e9c688eff1c89d72b407f168cf79bb9e867a9d3323ed6c01519eb9cc053" +checksum = "ab2156c4fce2f8df6c499cc1c763e4394b7482525bf2a9701c9d79d215f519e4" dependencies = [ "bitflags 2.4.0", "cfg-if", + "cfg_aliases", "libc", ] @@ -2299,13 +2297,12 @@ dependencies = [ [[package]] name = "num-bigint" -version = "0.4.4" +version = "0.4.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "608e7659b5c3d7cba262d894801b9ec9d00de989e8a82bd4bef91d08da45cdc0" +checksum = "c165a9ab64cf766f73521c0dd2cfdff64f488b8f0b3e621face3462d3db536d7" dependencies = [ - "autocfg", "num-integer", - "num-traits 0.2.16", + "num-traits 0.2.19", "rand", "serde", ] @@ -2317,17 +2314,22 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b6b19411a9719e753aff12e5187b74d60d3dc449ec3f4dc21e3989c3f554bc95" dependencies = [ "autocfg", - "num-traits 0.2.16", + "num-traits 0.2.19", ] +[[package]] +name = "num-conv" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "51d515d32fb182ee37cda2ccdcb92950d6a3c2893aa280e540671c2cd0f3b1d9" + [[package]] name = "num-integer" -version = "0.1.45" +version = "0.1.46" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "225d3389fb3509a24c93f5c29eb6bde2586b98d9f016636dff58d7c6f7569cd9" +checksum = "7969661fd2958a5cb096e56c8e1ad0444ac2bbcd0061bd28660485a44879858f" dependencies = [ - "autocfg", - "num-traits 0.2.16", + "num-traits 0.2.19", ] [[package]] @@ -2338,14 +2340,14 @@ checksum = "64a5fe11d4135c3bcdf3a95b18b194afa9608a5f6ff034f5d857bc9a27fb0119" dependencies = [ "num-bigint", "num-integer", - "num-traits 0.2.16", + "num-traits 0.2.19", ] [[package]] name = "num-prime" -version = "0.4.3" +version = "0.4.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f4e3bc495f6e95bc15a6c0c55ac00421504a5a43d09e3cc455d1fea7015581d" +checksum = "e238432a7881ec7164503ccc516c014bf009be7984cde1ba56837862543bdec3" dependencies = [ "bitvec", "either", @@ -2353,7 +2355,7 @@ dependencies = [ "num-bigint", "num-integer", "num-modular", - "num-traits 0.2.16", + "num-traits 0.2.19", "rand", ] @@ -2363,14 +2365,14 @@ version = "0.1.43" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "92e5113e9fd4cc14ded8e499429f396a20f98c772a47cc8622a736e1ec843c31" dependencies = [ - "num-traits 0.2.16", + "num-traits 0.2.19", ] [[package]] name = "num-traits" -version = "0.2.16" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f30b0abd723be7e2ffca1272140fac1a2f084c77ec3e123c192b66af1ee9e6c2" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", "libm", @@ -2424,9 +2426,9 @@ checksum = "04744f49eae99ab78e0d5c0b603ab218f515ea8cfe5a456d7629ad883a3b6e7d" [[package]] name = "parity-scale-codec" -version = "3.6.9" +version = "3.6.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "881331e34fa842a2fb61cc2db9643a8fedc615e47cfcc52597d1af0db9a7e8fe" +checksum = "306800abfa29c7f16596b5970a588435e3d5b3149683d00c12b699cc19f895ee" dependencies = [ "arrayvec", "bitvec", @@ -2438,9 +2440,9 @@ dependencies = [ [[package]] name = "parity-scale-codec-derive" -version = "3.6.9" +version = "3.6.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "be30eaf4b0a9fba5336683b38de57bb86d179a35862ba6bfcf57625d006bde5b" +checksum = "d830939c76d294956402033aee57a6da7b438f2294eb94864c37b0569053a42c" dependencies = [ "proc-macro-crate", "proc-macro2", @@ -2461,12 +2463,12 @@ dependencies = [ [[package]] name = "parking_lot" -version = "0.12.1" +version = "0.12.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3742b2c103b9f06bc9fff0a37ff4912935851bee6d36f3c02bcc755bcfec228f" +checksum = "f1bf18183cf54e8d6059647fc3063646a1801cf30896933ec2311622cc4b9a27" dependencies = [ "lock_api", - "parking_lot_core 0.9.8", + "parking_lot_core 0.9.10", ] [[package]] @@ -2485,22 +2487,22 @@ dependencies = [ [[package]] name = "parking_lot_core" -version = "0.9.8" +version = "0.9.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93f00c865fe7cabf650081affecd3871070f26767e7b2070a3ffae14c654b447" +checksum = "1e401f977ab385c9e4e3ab30627d6f26d00e2c73eef317493c4ec6d468726cf8" dependencies = [ "cfg-if", "libc", - "redox_syscall 0.3.5", + "redox_syscall 0.5.1", "smallvec", - "windows-targets 0.48.2", + "windows-targets 0.52.0", ] [[package]] name = "paste" -version = "1.0.14" +version = "1.0.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "de3145af08024dea9fa9914f381a17b8fc6034dfb00f3a84013f7ff43f29ed4c" +checksum = "57c0d7b74b563b49d38dae00a0c37d4d6de9b432382b2892f0574ddcae73fd0a" [[package]] name = "path-clean" @@ -2525,12 +2527,12 @@ checksum = "9b2a4787296e9989611394c33f193f676704af1686e70b8f8033ab5ba9a35a94" [[package]] name = "petgraph" -version = "0.6.4" +version = "0.6.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e1d3afd2628e69da2be385eb6f2fd57c8ac7977ceeff6dc166ff1657b0e386a9" +checksum = "b4c5cc86750666a3ed20bdaf5ca2a0344f9c67674cae0515bec2da16fbaa47db" dependencies = [ "fixedbitset", - "indexmap 2.2.2", + "indexmap 2.2.6", ] [[package]] @@ -2580,6 +2582,12 @@ version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" +[[package]] +name = "powerfmt" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "439ee305def115ba05938db6eb1644ff94165c5ab5e9420d1c1bcedbba909391" + [[package]] name = "ppv-lite86" version = "0.2.17" @@ -2594,9 +2602,9 @@ checksum = "925383efa346730478fb4838dbe9137d2a47675ad789c546d150a6e1dd4ab31c" [[package]] name = "primitive-types" -version = "0.12.1" +version = "0.12.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9f3486ccba82358b11a77516035647c34ba167dfa53312630de83b12bd4f3d66" +checksum = "0b34d9fd68ae0b74a41b21c03c2f62847aa0ffea044eee893b4c140b37e244e2" dependencies = [ "fixed-hash", "impl-codec", @@ -2607,35 +2615,11 @@ dependencies = [ [[package]] name = "proc-macro-crate" -version = "2.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7e8366a6159044a37876a2b9817124296703c586a5c92e2c53751fa06d8d43e8" -dependencies = [ - "toml_edit 0.20.7", -] - -[[package]] -name = "proc-macro-error" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da25490ff9892aab3fcf7c36f08cfb902dd3e71ca0f9f9517bea02a73a5ce38c" -dependencies = [ - "proc-macro-error-attr", - "proc-macro2", - "quote", - "syn 1.0.109", - "version_check", -] - -[[package]] -name = "proc-macro-error-attr" -version = "1.0.4" +version = "3.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1be40180e52ecc98ad80b184934baf3d0d29f979574e439af5a55274b35f869" +checksum = "6d37c51ca738a55da99dc0c4a34860fd675453b8b36209178c2249bb13651284" dependencies = [ - "proc-macro2", - "quote", - "version_check", + "toml_edit 0.21.1", ] [[package]] @@ -2654,7 +2638,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "31b476131c3c86cb68032fdc5cb6d5a1045e3e42d96b69fa599fd77701e1f5bf" dependencies = [ "bitflags 2.4.0", - "num-traits 0.2.16", + "num-traits 0.2.19", "rand", "rand_chacha", "rand_xorshift", @@ -2729,9 +2713,9 @@ checksum = "60a357793950651c4ed0f3f52338f53b2f809f32d83a07f72909fa13e4c6c1e3" [[package]] name = "rayon" -version = "1.8.1" +version = "1.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa7237101a77a10773db45d62004a272517633fbcc3df19d96455ede1122e051" +checksum = "b418a60154510ca1a002a752ca9714984e21e4241e804d32555251faf8b78ffa" dependencies = [ "either", "rayon-core", @@ -2758,11 +2742,11 @@ dependencies = [ [[package]] name = "redox_syscall" -version = "0.3.5" +version = "0.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "567664f262709473930a4bf9e51bf2ebf3348f2e748ccc50dea20646858f8f29" +checksum = "469052894dcb553421e483e4209ee581a45100d31b4018de03e5a7ad86374a7e" dependencies = [ - "bitflags 1.3.2", + "bitflags 2.4.0", ] [[package]] @@ -2784,8 +2768,8 @@ checksum = "12de2eff854e5fa4b1295edd650e227e9d8fb0c9e90b12e7f36d6a6811791a29" dependencies = [ "aho-corasick", "memchr", - "regex-automata", - "regex-syntax", + "regex-automata 0.3.7", + "regex-syntax 0.7.5", ] [[package]] @@ -2796,7 +2780,18 @@ checksum = "49530408a136e16e5b486e883fbb6ba058e8e4e8ae6621a77b048b314336e629" dependencies = [ "aho-corasick", "memchr", - "regex-syntax", + "regex-syntax 0.7.5", +] + +[[package]] +name = "regex-automata" +version = "0.4.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "38caf58cc5ef2fed281f89292ef23f6365465ed9a41b7a7754eb4e26496c92df" +dependencies = [ + "aho-corasick", + "memchr", + "regex-syntax 0.8.4", ] [[package]] @@ -2805,11 +2800,17 @@ version = "0.7.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "dbb5fb1acd8a1a18b3dd5be62d25485eb770e05afb408a9627d14d451bae12da" +[[package]] +name = "regex-syntax" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a66a03ae7c801facd77a29370b4faec201768915ac14a721ba36f20bc9c209b" + [[package]] name = "relative-path" -version = "1.9.2" +version = "1.9.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e898588f33fdd5b9420719948f9f2a32c922a246964576f71ba7f24f80610fbc" +checksum = "ba39f3699c378cd8970968dcbff9c43159ea4cfbd88d43c00b22f2ef10a435d2" [[package]] name = "reqwest" @@ -2887,9 +2888,9 @@ dependencies = [ [[package]] name = "ruint" -version = "1.12.1" +version = "1.12.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f308135fef9fc398342da5472ce7c484529df23743fb7c734e0f3d472971e62" +checksum = "2c3cc4c2511671f327125da14133d0c5c5d137f006a1017a16f557bc85b16286" dependencies = [ "proptest", "rand", @@ -2901,9 +2902,19 @@ dependencies = [ [[package]] name = "ruint-macro" -version = "1.2.0" +version = "1.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "48fd7bd8a6377e15ad9d42a8ec25371b94ddc67abe7c8b9127bec79bebaaae18" + +[[package]] +name = "rust_decimal" +version = "1.35.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f86854cf50259291520509879a5c294c3c9a4c334e9ff65071c51e42ef1e2343" +checksum = "1790d1c4c0ca81211399e0e0af16333276f375209e71a37b67698a373db5b47a" +dependencies = [ + "arrayvec", + "num-traits 0.2.19", +] [[package]] name = "rustc-demangle" @@ -3037,9 +3048,9 @@ dependencies = [ [[package]] name = "schemars" -version = "0.8.16" +version = "0.8.21" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "45a28f4c49489add4ce10783f7911893516f15afe45d015608d41faca6bc4d29" +checksum = "09c024468a378b7e36765cd36702b7a90cc3cba11654f6685c8f233408e89e92" dependencies = [ "dyn-clone", "indexmap 1.9.3", @@ -3050,14 +3061,14 @@ dependencies = [ [[package]] name = "schemars_derive" -version = "0.8.16" +version = "0.8.21" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c767fd6fa65d9ccf9cf026122c1b555f2ef9a4f0cea69da4d7dbc3e258d30967" +checksum = "b1eee588578aff73f856ab961cd2f79e36bc45d7ded33a7562adba4667aecc0e" dependencies = [ "proc-macro2", "quote", "serde_derive_internals", - "syn 1.0.109", + "syn 2.0.48", ] [[package]] @@ -3090,9 +3101,9 @@ dependencies = [ [[package]] name = "semver" -version = "1.0.19" +version = "1.0.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad977052201c6de01a8ef2aa3378c4bd23217a056337d1d6da40468d267a4fb0" +checksum = "61697e0a1c7e512e84a621326239844a24d8207b4669b41bc18b32ea5cbf988b" [[package]] name = "serde" @@ -3116,13 +3127,13 @@ dependencies = [ [[package]] name = "serde_derive_internals" -version = "0.26.0" +version = "0.29.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85bf8229e7920a9f636479437026331ce11aa132b4dde37d121944a44d6e5f3c" +checksum = "18d26a20a969b9e3fdf2fc2d9f21eda6c40e2de84c9408bb5d3b05d499aae711" dependencies = [ "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.48", ] [[package]] @@ -3159,9 +3170,9 @@ dependencies = [ [[package]] name = "serde_spanned" -version = "0.6.5" +version = "0.6.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eb3622f419d1296904700073ea6cc23ad690adbd66f13ea683df73298736f0c1" +checksum = "79e674e01f999af37c49f70a6ede167a8a60b2503e56c5599532a65baa5969a0" dependencies = [ "serde", ] @@ -3238,9 +3249,9 @@ dependencies = [ [[package]] name = "signal-hook-registry" -version = "1.4.1" +version = "1.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8229b473baa5980ac72ef434c4415e70c4b5e71b423043adb4ba059f89c99a1" +checksum = "a9e9e0b4211b72e7b8b6e85c807d36c212bdb33ea8587f7569562a84df5465b1" dependencies = [ "libc", ] @@ -3293,15 +3304,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.0" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62bb4feee49fdd9f707ef802e22365a35de4b7b299de4763d44bfea899442ff9" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "smol_str" -version = "0.2.1" +version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6845563ada680337a52d43bb0b29f396f2d911616f6573012645b9e3d048a49" +checksum = "dd538fb6910ac1099850255cf94a94df6551fbdd602454387d0adb2d1ca6dead" dependencies = [ "serde", ] @@ -3417,7 +3428,7 @@ dependencies = [ "hmac", "num-bigint", "num-integer", - "num-traits 0.2.16", + "num-traits 0.2.19", "rfc6979", "sha2", "starknet-crypto-codegen", @@ -3437,7 +3448,7 @@ dependencies = [ "hmac", "num-bigint", "num-integer", - "num-traits 0.2.16", + "num-traits 0.2.19", "rfc6979", "sha2", "starknet-crypto-codegen", @@ -3545,7 +3556,7 @@ dependencies = [ "cairo-lang-starknet-classes", "derive_more", "hex", - "indexmap 2.2.2", + "indexmap 2.2.6", "once_cell", "primitive-types", "serde", @@ -3570,16 +3581,16 @@ checksum = "f91138e76242f575eb1d3b38b4f1362f10d3a43f47d182a5b359af488a02293b" dependencies = [ "new_debug_unreachable", "once_cell", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "phf_shared", "precomputed-hash", ] [[package]] name = "strsim" -version = "0.10.0" +version = "0.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "73473c0e59e6d5812c5dfe2a064a6444949f089e20eec9a2e5506596494e4623" +checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" [[package]] name = "strum" @@ -3684,9 +3695,9 @@ dependencies = [ [[package]] name = "termcolor" -version = "1.2.0" +version = "1.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "be55cf8942feac5c765c2c993422806843c9a9a45d4d5c407ad6dd2ea95eb9b6" +checksum = "06794f8f6c5c898b3275aebefa6b8a1cb24cd2c6c79397ab15774837a0bc5755" dependencies = [ "winapi-util", ] @@ -3733,12 +3744,14 @@ dependencies = [ [[package]] name = "time" -version = "0.3.29" +version = "0.3.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "426f806f4089c493dcac0d24c29c01e2c38baf8e30f1b716ee37e83d200b18fe" +checksum = "5dfd88e563464686c916c7e46e623e520ddc6d79fa6641390f2e3fa86e83e885" dependencies = [ "deranged", "itoa", + "num-conv", + "powerfmt", "serde", "time-core", "time-macros", @@ -3752,10 +3765,11 @@ checksum = "ef927ca75afb808a4d64dd374f00a2adf8d0fcff8e7b184af886c3c87ec4a3f3" [[package]] name = "time-macros" -version = "0.2.15" +version = "0.2.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ad70d68dba9e1f8aceda7aa6711965dfec1cac869f311a51bd08b3a2ccbce20" +checksum = "3f252a68540fde3a3877aeea552b832b40ab9a69e318efd078774a01ddee1ccf" dependencies = [ + "num-conv", "time-core", ] @@ -3794,7 +3808,7 @@ dependencies = [ "libc", "mio", "num_cpus", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "pin-project-lite", "signal-hook-registry", "socket2 0.5.5", @@ -3839,47 +3853,47 @@ dependencies = [ [[package]] name = "toml" -version = "0.8.9" +version = "0.8.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c6a4b9e8023eb94392d3dca65d717c53abc5dad49c07cb65bb8fcd87115fa325" +checksum = "6f49eb2ab21d2f26bd6db7bf383edc527a7ebaee412d17af4d40fdccd442f335" dependencies = [ "serde", "serde_spanned", "toml_datetime", - "toml_edit 0.21.1", + "toml_edit 0.22.14", ] [[package]] name = "toml_datetime" -version = "0.6.5" +version = "0.6.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3550f4e9685620ac18a50ed434eb3aec30db8ba93b0287467bca5826ea25baf1" +checksum = "4badfd56924ae69bcc9039335b2e017639ce3f9b001c393c1b2d1ef846ce2cbf" dependencies = [ "serde", ] [[package]] name = "toml_edit" -version = "0.20.7" +version = "0.21.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70f427fce4d84c72b5b732388bf4a9f4531b53f74e2887e3ecb2481f68f66d81" +checksum = "6a8534fd7f78b5405e860340ad6575217ce99f38d4d5c8f2442cb5ecb50090e1" dependencies = [ - "indexmap 2.2.2", + "indexmap 2.2.6", "toml_datetime", - "winnow", + "winnow 0.5.40", ] [[package]] name = "toml_edit" -version = "0.21.1" +version = "0.22.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a8534fd7f78b5405e860340ad6575217ce99f38d4d5c8f2442cb5ecb50090e1" +checksum = "f21c7aaf97f1bd9ca9d4f9e73b0a6c74bd5afef56f2bc931943a6e1c37e04e38" dependencies = [ - "indexmap 2.2.2", + "indexmap 2.2.6", "serde", "serde_spanned", "toml_datetime", - "winnow", + "winnow 0.6.13", ] [[package]] @@ -3943,9 +3957,9 @@ dependencies = [ [[package]] name = "tracing-attributes" -version = "0.1.26" +version = "0.1.27" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f4f31f56159e98206da9efd823404b79b6ef3143b4a7ab76e67b1751b25a4ab" +checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7" dependencies = [ "proc-macro2", "quote", @@ -4023,9 +4037,9 @@ dependencies = [ [[package]] name = "unicode-segmentation" -version = "1.10.1" +version = "1.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1dd624098567895118886609431a7c3b8f516e41d30e0643f03d94592a147e36" +checksum = "d4c87d22b6e3f4a18d4d40ef354e97c90fcb14dd91d7dc0aa9d8a1172ebf7202" [[package]] name = "unicode-xid" @@ -4067,9 +4081,9 @@ checksum = "daf8dba3b7eb870caf1ddeed7bc9d2a049f3cfdfae7cb521b087cc33ae4c49da" [[package]] name = "utf8parse" -version = "0.2.1" +version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "711b9620af191e0cdc7468a8d14e709c3dcdb115b36f838e601583af800a370a" +checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" [[package]] name = "uuid" @@ -4101,9 +4115,9 @@ checksum = "6a02e4885ed3bc0f2de90ea6dd45ebcbb66dacffe03547fadbb0eeae2770887d" [[package]] name = "walkdir" -version = "2.3.3" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "36df944cda56c7d8d8b7496af378e6b16de9284591917d307c9b4d313c44e698" +checksum = "29790946404f91d9c5d06f9874efddea1dc06c5efe94541a7d6863108e3a5e4b" dependencies = [ "same-file", "winapi-util", @@ -4255,12 +4269,12 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" [[package]] -name = "windows" -version = "0.48.0" +name = "windows-core" +version = "0.52.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e686886bc078bc1b0b600cac0147aadb815089b6e4da64016cbd754b6342700f" +checksum = "33ab640c8d7e35bf8ba19b884ba838ceb4fba93a4e8c65a9059d08afcfc683d9" dependencies = [ - "windows-targets 0.48.2", + "windows-targets 0.52.0", ] [[package]] @@ -4463,9 +4477,18 @@ checksum = "dff9641d1cd4be8d1a070daf9e3773c5f67e78b4d9d42263020c057706765c04" [[package]] name = "winnow" -version = "0.5.15" +version = "0.5.40" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7c2e3184b9c4e92ad5167ca73039d0c42476302ab603e2fec4487511f38ccefc" +checksum = "f593a95398737aeed53e489c785df13f3618e41dbcd6718c6addbf1395aa6876" +dependencies = [ + "memchr", +] + +[[package]] +name = "winnow" +version = "0.6.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "59b5e5f6c299a3c7890b876a2a587f3115162487e704907d9b6cd29473052ba1" dependencies = [ "memchr", ] @@ -4491,33 +4514,33 @@ dependencies = [ [[package]] name = "xshell" -version = "0.2.5" +version = "0.2.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce2107fe03e558353b4c71ad7626d58ed82efaf56c54134228608893c77023ad" +checksum = "6db0ab86eae739efd1b054a8d3d16041914030ac4e01cd1dca0cf252fd8b6437" dependencies = [ "xshell-macros", ] [[package]] name = "xshell-macros" -version = "0.2.5" +version = "0.2.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7e2c411759b501fb9501aac2b1b2d287a6e93e5bdcf13c25306b23e1b716dd0e" +checksum = "9d422e8e38ec76e2f06ee439ccc765e9c6a9638b9e7c9f2e8255e4d41e8bd852" [[package]] name = "zerocopy" -version = "0.7.32" +version = "0.7.34" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74d4d3961e53fa4c9a25a8637fc2bfaf2595b3d3ae34875568a5cf64787716be" +checksum = "ae87e3fcd617500e5d106f0380cf7b77f3c6092aae37191433159dda23cfb087" dependencies = [ "zerocopy-derive", ] [[package]] name = "zerocopy-derive" -version = "0.7.32" +version = "0.7.34" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ce1b18ccd8e73a9321186f97e46f9f04b778851177567b1975109d26a08d2a6" +checksum = "15e934569e47891f7d9411f1a451d947a60e000ab3bd24fbb970f000387d1b3b" dependencies = [ "proc-macro2", "quote", @@ -4526,9 +4549,9 @@ dependencies = [ [[package]] name = "zeroize" -version = "1.6.0" +version = "1.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2a0956f1ba7c7909bfb66c2e9e4124ab6f6482560f6628b5aaeba39207c9aad9" +checksum = "ced3678a2879b30306d323f4542626697a464a97c0a07c9aebf7ebca65cd4dde" dependencies = [ "zeroize_derive", ] diff --git a/Cargo.toml b/Cargo.toml index 13912aa..24527c9 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -35,4 +35,4 @@ tempfile = "3.10.1" [[bin]] name = "slot" -path = "src/main.rs" +path = "src/bin/main.rs" diff --git a/src/api.rs b/src/api.rs index 41b9a86..245fddf 100644 --- a/src/api.rs +++ b/src/api.rs @@ -96,3 +96,9 @@ impl Client { url } } + +impl Default for Client { + fn default() -> Self { + Self::new() + } +} diff --git a/src/command/auth/info.rs b/src/bin/command/auth/info.rs similarity index 67% rename from src/command/auth/info.rs rename to src/bin/command/auth/info.rs index b63071e..6728cf2 100644 --- a/src/command/auth/info.rs +++ b/src/bin/command/auth/info.rs @@ -1,20 +1,11 @@ use anyhow::Result; use clap::Args; -use graphql_client::{GraphQLQuery, Response}; -use me::{ResponseData, Variables}; - -use crate::{api::Client, credential::Credentials}; - -#[derive(GraphQLQuery)] -#[graphql( - schema_path = "schema.json", - query_path = "src/command/auth/info.graphql", - response_derives = "Debug, Clone, Serialize" -)] -pub struct Me; +use slot::graphql::auth::{me::*, Me}; +use slot::graphql::{GraphQLQuery, Response}; +use slot::{api::Client, credential::Credentials}; #[derive(Debug, Args)] -pub struct InfoArgs {} +pub struct InfoArgs; impl InfoArgs { // TODO: find the account info from `credentials.json` first before making a request diff --git a/src/command/auth/login.rs b/src/bin/command/auth/login.rs similarity index 91% rename from src/command/auth/login.rs rename to src/bin/command/auth/login.rs index 36ad2d0..15f0e91 100644 --- a/src/command/auth/login.rs +++ b/src/bin/command/auth/login.rs @@ -1,10 +1,10 @@ -use crate::{browser::Browser, server::LocalServer}; use anyhow::Result; use clap::Args; +use slot::{browser::Browser, server::LocalServer}; use tokio::runtime::Runtime; #[derive(Debug, Args)] -pub struct LoginArgs {} +pub struct LoginArgs; impl LoginArgs { pub fn run(&self) -> Result<()> { diff --git a/src/command/auth/mod.rs b/src/bin/command/auth/mod.rs similarity index 97% rename from src/command/auth/mod.rs rename to src/bin/command/auth/mod.rs index de175d2..c5f0e5f 100644 --- a/src/command/auth/mod.rs +++ b/src/bin/command/auth/mod.rs @@ -3,7 +3,7 @@ use clap::Subcommand; use self::{info::InfoArgs, login::LoginArgs}; -pub mod info; +mod info; mod login; #[derive(Subcommand, Debug)] diff --git a/src/command/deployments/accounts.rs b/src/bin/command/deployments/accounts.rs similarity index 92% rename from src/command/deployments/accounts.rs rename to src/bin/command/deployments/accounts.rs index ddc6179..a647700 100644 --- a/src/command/deployments/accounts.rs +++ b/src/bin/command/deployments/accounts.rs @@ -2,32 +2,22 @@ use anyhow::Result; use clap::Args; -use graphql_client::{GraphQLQuery, Response}; use katana_primitives::contract::ContractAddress; use katana_primitives::genesis::allocation::GenesisAccountAlloc; use katana_primitives::genesis::allocation::{ DevAllocationsGenerator, DevGenesisAccount, GenesisAccount, }; use katana_primitives::genesis::Genesis; +use slot::graphql::deployments::katana_accounts::KatanaAccountsDeploymentConfig::KatanaConfig; +use slot::graphql::deployments::{katana_accounts::*, KatanaAccounts}; +use slot::graphql::{GraphQLQuery, Response}; use starknet::core::types::FieldElement; -use crate::api::Client; -use crate::credential::Credentials; +use slot::api::Client; +use slot::credential::Credentials; use super::services::KatanaAccountCommands; -use self::katana_accounts::{ - KatanaAccountsDeploymentConfig::KatanaConfig, ResponseData, Variables, -}; - -#[derive(GraphQLQuery)] -#[graphql( - schema_path = "schema.json", - query_path = "src/command/deployments/accounts.graphql", - response_derives = "Debug" -)] -pub struct KatanaAccounts; - #[derive(Debug, Args)] #[command(next_help_heading = "Accounts options")] pub struct AccountsArgs { diff --git a/src/command/deployments/create.rs b/src/bin/command/deployments/create.rs similarity index 88% rename from src/command/deployments/create.rs rename to src/bin/command/deployments/create.rs index 63a1ec2..3d61f41 100644 --- a/src/command/deployments/create.rs +++ b/src/bin/command/deployments/create.rs @@ -2,27 +2,16 @@ use anyhow::Result; use clap::Args; -use graphql_client::{GraphQLQuery, Response}; - -use crate::{ - api::Client, - command::deployments::create::create_deployment::{ - CreateDeploymentCreateDeployment::{KatanaConfig, MadaraConfig, ToriiConfig}, - CreateKatanaConfigInput, CreateMadaraConfigInput, CreateServiceConfigInput, - CreateServiceInput, CreateToriiConfigInput, DeploymentService, DeploymentTier, Variables, - }, - credential::Credentials, +use slot::api::Client; +use slot::credential::Credentials; +use slot::graphql::deployments::create_deployment::CreateDeploymentCreateDeployment::{ + KatanaConfig, MadaraConfig, ToriiConfig, }; +use slot::graphql::deployments::create_deployment::{self, *}; +use slot::graphql::deployments::CreateDeployment; +use slot::graphql::{GraphQLQuery, Response}; -use super::{services::CreateServiceCommands, Long, Tier}; - -#[derive(GraphQLQuery)] -#[graphql( - schema_path = "schema.json", - query_path = "src/command/deployments/create.graphql", - response_derives = "Debug" -)] -pub struct CreateDeployment; +use super::{services::CreateServiceCommands, Tier}; #[derive(Debug, Args)] #[command(next_help_heading = "Create options")] diff --git a/src/command/deployments/delete.rs b/src/bin/command/deployments/delete.rs similarity index 69% rename from src/command/deployments/delete.rs rename to src/bin/command/deployments/delete.rs index a01771c..c4d71ab 100644 --- a/src/command/deployments/delete.rs +++ b/src/bin/command/deployments/delete.rs @@ -1,22 +1,8 @@ -#![allow(clippy::enum_variant_names)] - use anyhow::Result; use clap::Args; -use graphql_client::{GraphQLQuery, Response}; - -use crate::{ - api::Client, - command::deployments::delete::delete_deployment::{DeploymentService, Variables}, - credential::Credentials, -}; - -#[derive(GraphQLQuery)] -#[graphql( - schema_path = "schema.json", - query_path = "src/command/deployments/delete.graphql", - response_derives = "Debug" -)] -pub struct DeleteDeployment; +use slot::graphql::deployments::{delete_deployment::*, DeleteDeployment}; +use slot::graphql::{GraphQLQuery, Response}; +use slot::{api::Client, credential::Credentials}; #[derive(clap::ValueEnum, Clone, Debug, serde::Serialize)] pub enum Service { @@ -51,7 +37,7 @@ impl DeleteArgs { let user = Credentials::load()?; let client = Client::new_with_token(user.access_token); - let res: Response = client.query(&request_body).await?; + let res: Response = client.query(&request_body).await?; if let Some(errors) = res.errors.clone() { for err in errors { println!("Error: {}", err.message); diff --git a/src/command/deployments/describe.rs b/src/bin/command/deployments/describe.rs similarity index 85% rename from src/command/deployments/describe.rs rename to src/bin/command/deployments/describe.rs index 3a57537..186e7b7 100644 --- a/src/command/deployments/describe.rs +++ b/src/bin/command/deployments/describe.rs @@ -1,28 +1,14 @@ #![allow(clippy::enum_variant_names)] +use super::services::Service; use anyhow::Result; use clap::Args; -use graphql_client::{GraphQLQuery, Response}; - -use crate::{api::Client, credential::Credentials}; - -use self::describe_deployment::{ - DeploymentService, - DescribeDeploymentDeploymentConfig::{KatanaConfig, MadaraConfig, ToriiConfig}, - ResponseData, Variables, +use slot::graphql::deployments::describe_deployment::DescribeDeploymentDeploymentConfig::{ + KatanaConfig, MadaraConfig, ToriiConfig, }; - -use super::services::Service; - -type Long = u64; - -#[derive(GraphQLQuery)] -#[graphql( - schema_path = "schema.json", - query_path = "src/command/deployments/describe.graphql", - response_derives = "Debug" -)] -pub struct DescribeDeployment; +use slot::graphql::deployments::{describe_deployment::*, DescribeDeployment}; +use slot::graphql::{GraphQLQuery, Response}; +use slot::{api::Client, credential::Credentials}; #[derive(Debug, Args)] #[command(next_help_heading = "Describe options")] diff --git a/src/command/deployments/fork.rs b/src/bin/command/deployments/fork.rs similarity index 81% rename from src/command/deployments/fork.rs rename to src/bin/command/deployments/fork.rs index 056920b..1c23fe3 100644 --- a/src/command/deployments/fork.rs +++ b/src/bin/command/deployments/fork.rs @@ -2,27 +2,14 @@ use anyhow::Result; use clap::Args; -use graphql_client::{GraphQLQuery, Response}; +use slot::graphql::deployments::fork_deployment::ForkDeploymentForkDeployment::KatanaConfig; +use slot::graphql::deployments::{fork_deployment::*, ForkDeployment}; +use slot::graphql::{GraphQLQuery, Response}; +use slot::{api::Client, credential::Credentials}; use starknet::providers::{jsonrpc::HttpTransport, JsonRpcClient, Provider}; use url::Url; -use crate::{ - api::Client, - command::deployments::fork::fork_deployment::{ - DeploymentTier, ForkDeploymentForkDeployment::KatanaConfig, Variables, - }, - credential::Credentials, -}; - -use super::{services::ForkServiceCommands, Long, Tier}; - -#[derive(GraphQLQuery)] -#[graphql( - schema_path = "schema.json", - query_path = "src/command/deployments/fork.graphql", - response_derives = "Debug" -)] -pub struct ForkDeployment; +use super::{services::ForkServiceCommands, Tier}; #[derive(Debug, Args)] #[command(next_help_heading = "Fork options")] @@ -57,7 +44,7 @@ impl ForkArgs { let user = Credentials::load()?; let client = Client::new_with_token(user.access_token); - let res: Response = client.query(&request_body).await?; + let res: Response = client.query(&request_body).await?; if let Some(errors) = res.errors.clone() { for err in errors { println!("Error: {}", err.message); diff --git a/src/command/deployments/list.rs b/src/bin/command/deployments/list.rs similarity index 83% rename from src/command/deployments/list.rs rename to src/bin/command/deployments/list.rs index b8a5c93..bfd19fd 100644 --- a/src/command/deployments/list.rs +++ b/src/bin/command/deployments/list.rs @@ -2,19 +2,11 @@ use anyhow::Result; use clap::Args; -use graphql_client::{GraphQLQuery, Response}; -use crate::{api::Client, credential::Credentials}; - -use self::list_deployments::{ResponseData, Variables}; - -#[derive(GraphQLQuery)] -#[graphql( - schema_path = "schema.json", - query_path = "src/command/deployments/list.graphql", - response_derives = "Debug" -)] -pub struct ListDeployments; +use slot::graphql::deployments::list_deployments::{ResponseData, Variables}; +use slot::graphql::deployments::ListDeployments; +use slot::graphql::{GraphQLQuery, Response}; +use slot::{api::Client, credential::Credentials}; #[derive(Debug, Args)] #[command(next_help_heading = "List options")] diff --git a/src/command/deployments/logs.rs b/src/bin/command/deployments/logs.rs similarity index 86% rename from src/command/deployments/logs.rs rename to src/bin/command/deployments/logs.rs index 1bafa68..0cef3f6 100644 --- a/src/command/deployments/logs.rs +++ b/src/bin/command/deployments/logs.rs @@ -7,30 +7,16 @@ use std::{ time::Duration, }; +// use tokio::selectV use anyhow::Result; use clap::Args; -use graphql_client::{GraphQLQuery, Response}; -use tokio::time::sleep; - -use crate::{ - api::Client, command::deployments::logs::deployment_logs::DeploymentService, - credential::Credentials, -}; - -use self::deployment_logs::{DeploymentLogsDeploymentLogs, ResponseData, Variables}; +use slot::credential::Credentials; +use slot::graphql::deployments::deployment_logs::DeploymentService; +use slot::graphql::{deployments::deployment_logs::*, GraphQLQuery, Response}; +use slot::{api::Client, graphql::deployments::DeploymentLogs}; use super::services::Service; -#[derive(GraphQLQuery)] -#[graphql( - schema_path = "schema.json", - query_path = "src/command/deployments/logs.graphql", - response_derives = "Debug" -)] -pub struct DeploymentLogs; - -type Time = String; - #[derive(Debug, Args)] #[command(next_help_heading = "Deployment logs options")] pub struct LogsArgs { @@ -135,7 +121,7 @@ impl LogReader { let mut since = logs.until; while running.load(Ordering::SeqCst) { - sleep(Duration::from_millis(1000)).await; + tokio::time::sleep(Duration::from_millis(1000)).await; logs = self.query(Some(since.clone()), 25).await?; if !printed_logs.contains(&logs.content) { diff --git a/src/command/deployments/mod.rs b/src/bin/command/deployments/mod.rs similarity index 98% rename from src/command/deployments/mod.rs rename to src/bin/command/deployments/mod.rs index b418f3d..c4ab81e 100644 --- a/src/command/deployments/mod.rs +++ b/src/bin/command/deployments/mod.rs @@ -16,8 +16,6 @@ mod logs; mod services; mod update; -type Long = u64; - #[derive(Subcommand, Debug)] pub enum Deployments { #[command(about = "Create a new deployment.")] diff --git a/src/command/deployments/services/katana.rs b/src/bin/command/deployments/services/katana.rs similarity index 100% rename from src/command/deployments/services/katana.rs rename to src/bin/command/deployments/services/katana.rs diff --git a/src/command/deployments/services/madara.rs b/src/bin/command/deployments/services/madara.rs similarity index 100% rename from src/command/deployments/services/madara.rs rename to src/bin/command/deployments/services/madara.rs diff --git a/src/command/deployments/services/mod.rs b/src/bin/command/deployments/services/mod.rs similarity index 100% rename from src/command/deployments/services/mod.rs rename to src/bin/command/deployments/services/mod.rs diff --git a/src/command/deployments/services/torii.rs b/src/bin/command/deployments/services/torii.rs similarity index 100% rename from src/command/deployments/services/torii.rs rename to src/bin/command/deployments/services/torii.rs diff --git a/src/command/deployments/update.rs b/src/bin/command/deployments/update.rs similarity index 85% rename from src/command/deployments/update.rs rename to src/bin/command/deployments/update.rs index 2a5b1a1..d1cc06c 100644 --- a/src/command/deployments/update.rs +++ b/src/bin/command/deployments/update.rs @@ -2,31 +2,19 @@ use anyhow::Result; use clap::Args; -use graphql_client::{GraphQLQuery, Response}; - -use self::update_deployment::UpdateServiceInput; -use crate::{ - api::Client, - command::deployments::update::update_deployment::{ - DeploymentService, DeploymentTier, - UpdateDeploymentUpdateDeployment::{KatanaConfig, MadaraConfig, ToriiConfig}, - UpdateKatanaConfigInput, UpdateServiceConfigInput, Variables, - }, - credential::Credentials, +use slot::api::Client; +use slot::credential::Credentials; +use slot::graphql::deployments::update_deployment::UpdateDeploymentUpdateDeployment::{ + KatanaConfig, MadaraConfig, ToriiConfig, +}; +use slot::graphql::deployments::update_deployment::{ + self, UpdateKatanaConfigInput, UpdateServiceConfigInput, UpdateServiceInput, }; +use slot::graphql::deployments::{update_deployment::*, UpdateDeployment}; +use slot::graphql::{GraphQLQuery, Response}; use super::services::UpdateServiceCommands; -type Long = u64; - -#[derive(GraphQLQuery)] -#[graphql( - schema_path = "schema.json", - query_path = "src/command/deployments/update.graphql", - response_derives = "Debug" -)] -pub struct UpdateDeployment; - #[derive(clap::ValueEnum, Clone, Debug, serde::Serialize)] pub enum Tier { Basic, diff --git a/src/command.rs b/src/bin/command/mod.rs similarity index 100% rename from src/command.rs rename to src/bin/command/mod.rs diff --git a/src/command/teams/members.rs b/src/bin/command/teams/members.rs similarity index 73% rename from src/command/teams/members.rs rename to src/bin/command/teams/members.rs index 1969a33..5e19a5b 100644 --- a/src/command/teams/members.rs +++ b/src/bin/command/teams/members.rs @@ -1,25 +1,21 @@ use anyhow::Result; use clap::Args; -use graphql_client::{GraphQLQuery, Response}; - -use crate::{api::Client, credential::Credentials}; - -#[derive(GraphQLQuery)] -#[graphql( - schema_path = "schema.json", - query_path = "src/command/teams/members.graphql", - response_derives = "Debug" -)] -pub struct TeamMembersList; +use slot::api::Client; +use slot::credential::Credentials; +use slot::graphql::team::{ + team_member_add, team_member_remove, team_members_list, TeamMemberAdd, TeamMemberRemove, + TeamMembersList, +}; +use slot::graphql::{GraphQLQuery, Response}; #[derive(Debug, Args, serde::Serialize)] #[command(next_help_heading = "Team list options")] -pub struct TeamListArgs {} +pub struct TeamListArgs; impl TeamListArgs { pub async fn run(&self, team: String) -> Result<()> { let request_body = - TeamMembersList::build_query(self::team_members_list::Variables { team: team.clone() }); + TeamMembersList::build_query(team_members_list::Variables { team: team.clone() }); let user = Credentials::load()?; let client = Client::new_with_token(user.access_token); @@ -50,14 +46,6 @@ impl TeamListArgs { } } -#[derive(GraphQLQuery)] -#[graphql( - schema_path = "schema.json", - query_path = "src/command/teams/members.graphql", - response_derives = "Debug" -)] -pub struct TeamMemberAdd; - #[derive(Debug, Args, serde::Serialize)] #[command(next_help_heading = "Team add options")] pub struct TeamAddArgs { @@ -67,7 +55,7 @@ pub struct TeamAddArgs { impl TeamAddArgs { pub async fn run(&self, team: String) -> Result<()> { - let request_body = TeamMemberAdd::build_query(self::team_member_add::Variables { + let request_body = TeamMemberAdd::build_query(team_member_add::Variables { team, accounts: self.account.clone(), }); @@ -88,14 +76,6 @@ impl TeamAddArgs { } } -#[derive(GraphQLQuery)] -#[graphql( - schema_path = "schema.json", - query_path = "src/command/teams/members.graphql", - response_derives = "Debug" -)] -pub struct TeamMemberRemove; - #[derive(Debug, Args, serde::Serialize)] #[command(next_help_heading = "Team remove options")] pub struct TeamRemoveArgs { @@ -105,7 +85,7 @@ pub struct TeamRemoveArgs { impl TeamRemoveArgs { pub async fn run(&self, team: String) -> Result<()> { - let request_body = TeamMemberRemove::build_query(self::team_member_remove::Variables { + let request_body = TeamMemberRemove::build_query(team_member_remove::Variables { team, accounts: self.account.clone(), }); diff --git a/src/command/teams/mod.rs b/src/bin/command/teams/mod.rs similarity index 100% rename from src/command/teams/mod.rs rename to src/bin/command/teams/mod.rs diff --git a/src/main.rs b/src/bin/main.rs similarity index 55% rename from src/main.rs rename to src/bin/main.rs index 984f0a2..f0e9c26 100644 --- a/src/main.rs +++ b/src/bin/main.rs @@ -1,15 +1,17 @@ -mod api; -mod browser; -mod cli; mod command; -mod constant; -mod credential; -mod server; +use crate::command::Command; use clap::Parser; -use cli::Cli; use log::error; +/// Slot CLI for Cartridge +#[derive(Parser, Debug)] +#[command(author, version, about, long_about = None)] +pub struct Cli { + #[command(subcommand)] + pub command: Command, +} + #[tokio::main] async fn main() { env_logger::init(); diff --git a/src/cli.rs b/src/cli.rs deleted file mode 100644 index 377725d..0000000 --- a/src/cli.rs +++ /dev/null @@ -1,10 +0,0 @@ -use crate::command::Command; -use clap::Parser; - -/// Slot CLI for Cartridge -#[derive(Parser, Debug)] -#[command(author, version, about, long_about = None)] -pub struct Cli { - #[command(subcommand)] - pub command: Command, -} diff --git a/src/command/deployments/create.graphql b/src/command/deployments/create.graphql deleted file mode 100644 index bdf49e0..0000000 --- a/src/command/deployments/create.graphql +++ /dev/null @@ -1,30 +0,0 @@ -mutation CreateDeployment( - $project: String! - $service: CreateServiceInput! - $tier: DeploymentTier! - $wait: Boolean -) { - createDeployment( - name: $project - service: $service - tier: $tier - wait: $wait - ) { - __typename - ... on KatanaConfig { - rpc - } - ... on ToriiConfig { - graphql - grpc - rpc - world - startBlock - indexPending - } - ... on MadaraConfig { - rpc - name - } - } -} diff --git a/src/credential.rs b/src/credential.rs index 231de80..57fa7d6 100644 --- a/src/credential.rs +++ b/src/credential.rs @@ -3,7 +3,7 @@ use std::fs; use std::io::{self}; use std::path::{Path, PathBuf}; -use crate::command::auth::info::me::MeMe; +use crate::graphql::auth::me::MeMe; const SLOT_DIR: &str = "slot"; const CREDENTIALS_FILE: &str = "credentials.json"; diff --git a/src/command/auth/info.graphql b/src/graphql/auth/info.graphql similarity index 100% rename from src/command/auth/info.graphql rename to src/graphql/auth/info.graphql diff --git a/src/graphql/auth/mod.rs b/src/graphql/auth/mod.rs new file mode 100644 index 0000000..545f12d --- /dev/null +++ b/src/graphql/auth/mod.rs @@ -0,0 +1,9 @@ +use graphql_client::GraphQLQuery; + +#[derive(GraphQLQuery)] +#[graphql( + schema_path = "schema.json", + query_path = "src/graphql/auth/info.graphql", + response_derives = "Debug, Clone, Serialize" +)] +pub struct Me; diff --git a/src/command/deployments/accounts.graphql b/src/graphql/deployments/accounts.graphql similarity index 100% rename from src/command/deployments/accounts.graphql rename to src/graphql/deployments/accounts.graphql diff --git a/src/graphql/deployments/accounts.rs b/src/graphql/deployments/accounts.rs new file mode 100644 index 0000000..dafc571 --- /dev/null +++ b/src/graphql/deployments/accounts.rs @@ -0,0 +1,9 @@ +use graphql_client::GraphQLQuery; + +#[derive(GraphQLQuery)] +#[graphql( + response_derives = "Debug", + schema_path = "schema.json", + query_path = "src/graphql/deployments/accounts.graphql" +)] +pub struct KatanaAccounts; diff --git a/src/graphql/deployments/create.graphql b/src/graphql/deployments/create.graphql new file mode 100644 index 0000000..70a9032 --- /dev/null +++ b/src/graphql/deployments/create.graphql @@ -0,0 +1,30 @@ +mutation CreateDeployment( + $project: String! + $service: CreateServiceInput! + $tier: DeploymentTier! + $wait: Boolean +) { + createDeployment( + name: $project + service: $service + tier: $tier + wait: $wait + ) { + __typename + ... on KatanaConfig { + rpc + } + ... on ToriiConfig { + graphql + grpc + rpc + world + startBlock + indexPending + } + ... on MadaraConfig { + rpc + name + } + } +} diff --git a/src/graphql/deployments/create.rs b/src/graphql/deployments/create.rs new file mode 100644 index 0000000..2b08055 --- /dev/null +++ b/src/graphql/deployments/create.rs @@ -0,0 +1,10 @@ +use crate::graphql::deployments::Long; +use graphql_client::GraphQLQuery; + +#[derive(GraphQLQuery)] +#[graphql( + response_derives = "Debug", + schema_path = "schema.json", + query_path = "src/graphql/deployments/create.graphql" +)] +pub struct CreateDeployment; diff --git a/src/command/deployments/delete.graphql b/src/graphql/deployments/delete.graphql similarity index 59% rename from src/command/deployments/delete.graphql rename to src/graphql/deployments/delete.graphql index 31a9bc1..9015d7e 100644 --- a/src/command/deployments/delete.graphql +++ b/src/graphql/deployments/delete.graphql @@ -1,3 +1,3 @@ mutation DeleteDeployment($project: String!, $service: DeploymentService!) { - deleteDeployment(name: $project, service: $service) + deleteDeployment(name: $project, service: $service) } diff --git a/src/graphql/deployments/delete.rs b/src/graphql/deployments/delete.rs new file mode 100644 index 0000000..0f3b15a --- /dev/null +++ b/src/graphql/deployments/delete.rs @@ -0,0 +1,9 @@ +use graphql_client::GraphQLQuery; + +#[derive(GraphQLQuery)] +#[graphql( + response_derives = "Debug", + schema_path = "schema.json", + query_path = "src/graphql/deployments/delete.graphql" +)] +pub struct DeleteDeployment; diff --git a/src/command/deployments/describe.graphql b/src/graphql/deployments/describe.graphql similarity index 100% rename from src/command/deployments/describe.graphql rename to src/graphql/deployments/describe.graphql diff --git a/src/graphql/deployments/describe.rs b/src/graphql/deployments/describe.rs new file mode 100644 index 0000000..55ddd9e --- /dev/null +++ b/src/graphql/deployments/describe.rs @@ -0,0 +1,10 @@ +use crate::graphql::deployments::Long; +use graphql_client::GraphQLQuery; + +#[derive(GraphQLQuery)] +#[graphql( + response_derives = "Debug", + schema_path = "schema.json", + query_path = "src/graphql/deployments/describe.graphql" +)] +pub struct DescribeDeployment; diff --git a/src/command/deployments/fork.graphql b/src/graphql/deployments/fork.graphql similarity index 100% rename from src/command/deployments/fork.graphql rename to src/graphql/deployments/fork.graphql diff --git a/src/graphql/deployments/fork.rs b/src/graphql/deployments/fork.rs new file mode 100644 index 0000000..cf774cd --- /dev/null +++ b/src/graphql/deployments/fork.rs @@ -0,0 +1,10 @@ +use crate::graphql::deployments::Long; +use graphql_client::GraphQLQuery; + +#[derive(GraphQLQuery)] +#[graphql( + response_derives = "Debug", + schema_path = "schema.json", + query_path = "src/graphql/deployments/fork.graphql" +)] +pub struct ForkDeployment; diff --git a/src/command/deployments/list.graphql b/src/graphql/deployments/list.graphql similarity index 100% rename from src/command/deployments/list.graphql rename to src/graphql/deployments/list.graphql diff --git a/src/graphql/deployments/list.rs b/src/graphql/deployments/list.rs new file mode 100644 index 0000000..49cd99b --- /dev/null +++ b/src/graphql/deployments/list.rs @@ -0,0 +1,9 @@ +use graphql_client::GraphQLQuery; + +#[derive(GraphQLQuery)] +#[graphql( + response_derives = "Debug", + schema_path = "schema.json", + query_path = "src/graphql/deployments/list.graphql" +)] +pub struct ListDeployments; diff --git a/src/command/deployments/logs.graphql b/src/graphql/deployments/logs.graphql similarity index 100% rename from src/command/deployments/logs.graphql rename to src/graphql/deployments/logs.graphql diff --git a/src/graphql/deployments/logs.rs b/src/graphql/deployments/logs.rs new file mode 100644 index 0000000..d9ad40b --- /dev/null +++ b/src/graphql/deployments/logs.rs @@ -0,0 +1,10 @@ +use crate::graphql::deployments::Time; +use graphql_client::GraphQLQuery; + +#[derive(GraphQLQuery)] +#[graphql( + response_derives = "Debug", + schema_path = "schema.json", + query_path = "src/graphql/deployments/logs.graphql" +)] +pub struct DeploymentLogs; diff --git a/src/graphql/deployments/mod.rs b/src/graphql/deployments/mod.rs new file mode 100644 index 0000000..381dc3f --- /dev/null +++ b/src/graphql/deployments/mod.rs @@ -0,0 +1,22 @@ +#![allow(clippy::enum_variant_names)] + +pub type Long = u64; +pub type Time = String; + +mod accounts; +mod create; +mod delete; +mod describe; +mod fork; +mod list; +mod logs; +mod update; + +pub use accounts::*; +pub use create::*; +pub use delete::*; +pub use describe::*; +pub use fork::*; +pub use list::*; +pub use logs::*; +pub use update::*; diff --git a/src/command/deployments/update.graphql b/src/graphql/deployments/update.graphql similarity index 100% rename from src/command/deployments/update.graphql rename to src/graphql/deployments/update.graphql diff --git a/src/graphql/deployments/update.rs b/src/graphql/deployments/update.rs new file mode 100644 index 0000000..e262090 --- /dev/null +++ b/src/graphql/deployments/update.rs @@ -0,0 +1,10 @@ +use crate::graphql::deployments::Long; +use graphql_client::GraphQLQuery; + +#[derive(GraphQLQuery)] +#[graphql( + response_derives = "Debug", + schema_path = "schema.json", + query_path = "src/graphql/deployments/update.graphql" +)] +pub struct UpdateDeployment; diff --git a/src/graphql/mod.rs b/src/graphql/mod.rs new file mode 100644 index 0000000..922fdc8 --- /dev/null +++ b/src/graphql/mod.rs @@ -0,0 +1,5 @@ +pub mod auth; +pub mod deployments; +pub mod team; + +pub use graphql_client::{GraphQLQuery, Response}; diff --git a/src/command/teams/members.graphql b/src/graphql/team/members.graphql similarity index 100% rename from src/command/teams/members.graphql rename to src/graphql/team/members.graphql diff --git a/src/graphql/team/mod.rs b/src/graphql/team/mod.rs new file mode 100644 index 0000000..6a3794c --- /dev/null +++ b/src/graphql/team/mod.rs @@ -0,0 +1,25 @@ +use graphql_client::GraphQLQuery; + +#[derive(GraphQLQuery)] +#[graphql( + response_derives = "Debug", + schema_path = "schema.json", + query_path = "src/graphql/team/members.graphql" +)] +pub struct TeamMembersList; + +#[derive(GraphQLQuery)] +#[graphql( + response_derives = "Debug", + schema_path = "schema.json", + query_path = "src/graphql/team/members.graphql" +)] +pub struct TeamMemberAdd; + +#[derive(GraphQLQuery)] +#[graphql( + response_derives = "Debug", + schema_path = "schema.json", + query_path = "src/graphql/team/members.graphql" +)] +pub struct TeamMemberRemove; diff --git a/src/lib.rs b/src/lib.rs new file mode 100644 index 0000000..0f3430c --- /dev/null +++ b/src/lib.rs @@ -0,0 +1,6 @@ +pub mod api; +pub mod browser; +pub mod constant; +pub mod credential; +pub mod graphql; +pub mod server; diff --git a/src/server.rs b/src/server.rs index 1ed64be..34a7715 100644 --- a/src/server.rs +++ b/src/server.rs @@ -17,12 +17,12 @@ use tokio::sync::mpsc::{Receiver, Sender}; use crate::{ api::Client, - command::auth::info::{ + constant, + credential::Credentials, + graphql::auth::{ me::{ResponseData, Variables}, Me, }, - constant, - credential::Credentials, }; pub struct LocalServer {