Parakeet is a Rust-based Bluesky AppServer aiming to implement most of the functionality required to support the Bluesky client
appview atproto bluesky rust appserver
66
fork

Configure Feed

Select the types of activity you want to include in your feed.

start on the little lexgen cli

Mia 927d2032 6cb50fa1

+370 -2
+335
Cargo.lock
··· 3 3 version = 3 4 4 5 5 [[package]] 6 + name = "anstream" 7 + version = "0.6.18" 8 + source = "registry+https://github.com/rust-lang/crates.io-index" 9 + checksum = "8acc5369981196006228e28809f761875c0327210a891e941f4c683b3a99529b" 10 + dependencies = [ 11 + "anstyle", 12 + "anstyle-parse", 13 + "anstyle-query", 14 + "anstyle-wincon", 15 + "colorchoice", 16 + "is_terminal_polyfill", 17 + "utf8parse", 18 + ] 19 + 20 + [[package]] 21 + name = "anstyle" 22 + version = "1.0.10" 23 + source = "registry+https://github.com/rust-lang/crates.io-index" 24 + checksum = "55cc3b69f167a1ef2e161439aa98aed94e6028e5f9a59be9a6ffb47aef1651f9" 25 + 26 + [[package]] 27 + name = "anstyle-parse" 28 + version = "0.2.6" 29 + source = "registry+https://github.com/rust-lang/crates.io-index" 30 + checksum = "3b2d16507662817a6a20a9ea92df6652ee4f94f914589377d69f3b21bc5798a9" 31 + dependencies = [ 32 + "utf8parse", 33 + ] 34 + 35 + [[package]] 36 + name = "anstyle-query" 37 + version = "1.1.2" 38 + source = "registry+https://github.com/rust-lang/crates.io-index" 39 + checksum = "79947af37f4177cfead1110013d678905c37501914fba0efea834c3fe9a8d60c" 40 + dependencies = [ 41 + "windows-sys", 42 + ] 43 + 44 + [[package]] 45 + name = "anstyle-wincon" 46 + version = "3.0.7" 47 + source = "registry+https://github.com/rust-lang/crates.io-index" 48 + checksum = "ca3534e77181a9cc07539ad51f2141fe32f6c3ffd4df76db8ad92346b003ae4e" 49 + dependencies = [ 50 + "anstyle", 51 + "once_cell", 52 + "windows-sys", 53 + ] 54 + 55 + [[package]] 56 + name = "clap" 57 + version = "4.5.26" 58 + source = "registry+https://github.com/rust-lang/crates.io-index" 59 + checksum = "a8eb5e908ef3a6efbe1ed62520fb7287959888c88485abe072543190ecc66783" 60 + dependencies = [ 61 + "clap_builder", 62 + "clap_derive", 63 + ] 64 + 65 + [[package]] 66 + name = "clap_builder" 67 + version = "4.5.26" 68 + source = "registry+https://github.com/rust-lang/crates.io-index" 69 + checksum = "96b01801b5fc6a0a232407abc821660c9c6d25a1cafc0d4f85f29fb8d9afc121" 70 + dependencies = [ 71 + "anstream", 72 + "anstyle", 73 + "clap_lex", 74 + "strsim", 75 + ] 76 + 77 + [[package]] 78 + name = "clap_derive" 79 + version = "4.5.24" 80 + source = "registry+https://github.com/rust-lang/crates.io-index" 81 + checksum = "54b755194d6389280185988721fffba69495eed5ee9feeee9a599b53db80318c" 82 + dependencies = [ 83 + "heck", 84 + "proc-macro2", 85 + "quote", 86 + "syn", 87 + ] 88 + 89 + [[package]] 90 + name = "clap_lex" 91 + version = "0.7.4" 92 + source = "registry+https://github.com/rust-lang/crates.io-index" 93 + checksum = "f46ad14479a25103f283c0f10005961cf086d8dc42205bb44c46ac563475dca6" 94 + 95 + [[package]] 96 + name = "colorchoice" 97 + version = "1.0.3" 98 + source = "registry+https://github.com/rust-lang/crates.io-index" 99 + checksum = "5b63caa9aa9397e2d9480a9b13673856c78d8ac123288526c37d7839f2a86990" 100 + 101 + [[package]] 6 102 name = "consumer" 7 103 version = "0.1.0" 8 104 9 105 [[package]] 106 + name = "eyre" 107 + version = "0.6.12" 108 + source = "registry+https://github.com/rust-lang/crates.io-index" 109 + checksum = "7cd915d99f24784cdc19fd37ef22b97e3ff0ae756c7e492e9fbfe897d61e2aec" 110 + dependencies = [ 111 + "indenter", 112 + "once_cell", 113 + ] 114 + 115 + [[package]] 116 + name = "heck" 117 + version = "0.5.0" 118 + source = "registry+https://github.com/rust-lang/crates.io-index" 119 + checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" 120 + 121 + [[package]] 122 + name = "indenter" 123 + version = "0.3.3" 124 + source = "registry+https://github.com/rust-lang/crates.io-index" 125 + checksum = "ce23b50ad8242c51a442f3ff322d56b02f08852c77e4c0b4d3fd684abc89c683" 126 + 127 + [[package]] 128 + name = "is_terminal_polyfill" 129 + version = "1.70.1" 130 + source = "registry+https://github.com/rust-lang/crates.io-index" 131 + checksum = "7943c866cc5cd64cbc25b2e01621d07fa8eb2a1a23160ee81ce38704e97b8ecf" 132 + 133 + [[package]] 134 + name = "itoa" 135 + version = "1.0.14" 136 + source = "registry+https://github.com/rust-lang/crates.io-index" 137 + checksum = "d75a2a4b1b190afb6f5425f10f6a8f959d2ea0b9c2b1d79553551850539e4674" 138 + 139 + [[package]] 140 + name = "memchr" 141 + version = "2.7.4" 142 + source = "registry+https://github.com/rust-lang/crates.io-index" 143 + checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" 144 + 145 + [[package]] 146 + name = "once_cell" 147 + version = "1.20.2" 148 + source = "registry+https://github.com/rust-lang/crates.io-index" 149 + checksum = "1261fe7e33c73b354eab43b1273a57c8f967d0391e80353e51f764ac02cf6775" 150 + 151 + [[package]] 10 152 name = "parakeet" 11 153 version = "0.1.0" 12 154 13 155 [[package]] 14 156 name = "parakeet-lexgen" 15 157 version = "0.1.0" 158 + dependencies = [ 159 + "clap", 160 + "eyre", 161 + "serde", 162 + "serde_json", 163 + "walkdir", 164 + ] 165 + 166 + [[package]] 167 + name = "proc-macro2" 168 + version = "1.0.93" 169 + source = "registry+https://github.com/rust-lang/crates.io-index" 170 + checksum = "60946a68e5f9d28b0dc1c21bb8a97ee7d018a8b322fa57838ba31cc878e22d99" 171 + dependencies = [ 172 + "unicode-ident", 173 + ] 174 + 175 + [[package]] 176 + name = "quote" 177 + version = "1.0.38" 178 + source = "registry+https://github.com/rust-lang/crates.io-index" 179 + checksum = "0e4dccaaaf89514f546c693ddc140f729f958c247918a13380cccc6078391acc" 180 + dependencies = [ 181 + "proc-macro2", 182 + ] 183 + 184 + [[package]] 185 + name = "ryu" 186 + version = "1.0.18" 187 + source = "registry+https://github.com/rust-lang/crates.io-index" 188 + checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" 189 + 190 + [[package]] 191 + name = "same-file" 192 + version = "1.0.6" 193 + source = "registry+https://github.com/rust-lang/crates.io-index" 194 + checksum = "93fc1dc3aaa9bfed95e02e6eadabb4baf7e3078b0bd1b4d7b6b0b68378900502" 195 + dependencies = [ 196 + "winapi-util", 197 + ] 198 + 199 + [[package]] 200 + name = "serde" 201 + version = "1.0.217" 202 + source = "registry+https://github.com/rust-lang/crates.io-index" 203 + checksum = "02fc4265df13d6fa1d00ecff087228cc0a2b5f3c0e87e258d8b94a156e984c70" 204 + dependencies = [ 205 + "serde_derive", 206 + ] 207 + 208 + [[package]] 209 + name = "serde_derive" 210 + version = "1.0.217" 211 + source = "registry+https://github.com/rust-lang/crates.io-index" 212 + checksum = "5a9bf7cf98d04a2b28aead066b7496853d4779c9cc183c440dbac457641e19a0" 213 + dependencies = [ 214 + "proc-macro2", 215 + "quote", 216 + "syn", 217 + ] 218 + 219 + [[package]] 220 + name = "serde_json" 221 + version = "1.0.136" 222 + source = "registry+https://github.com/rust-lang/crates.io-index" 223 + checksum = "336a0c23cf42a38d9eaa7cd22c7040d04e1228a19a933890805ffd00a16437d2" 224 + dependencies = [ 225 + "itoa", 226 + "memchr", 227 + "ryu", 228 + "serde", 229 + ] 230 + 231 + [[package]] 232 + name = "strsim" 233 + version = "0.11.1" 234 + source = "registry+https://github.com/rust-lang/crates.io-index" 235 + checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" 236 + 237 + [[package]] 238 + name = "syn" 239 + version = "2.0.96" 240 + source = "registry+https://github.com/rust-lang/crates.io-index" 241 + checksum = "d5d0adab1ae378d7f53bdebc67a39f1f151407ef230f0ce2883572f5d8985c80" 242 + dependencies = [ 243 + "proc-macro2", 244 + "quote", 245 + "unicode-ident", 246 + ] 247 + 248 + [[package]] 249 + name = "unicode-ident" 250 + version = "1.0.14" 251 + source = "registry+https://github.com/rust-lang/crates.io-index" 252 + checksum = "adb9e6ca4f869e1180728b7950e35922a7fc6397f7b641499e8f3ef06e50dc83" 253 + 254 + [[package]] 255 + name = "utf8parse" 256 + version = "0.2.2" 257 + source = "registry+https://github.com/rust-lang/crates.io-index" 258 + checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" 259 + 260 + [[package]] 261 + name = "walkdir" 262 + version = "2.5.0" 263 + source = "registry+https://github.com/rust-lang/crates.io-index" 264 + checksum = "29790946404f91d9c5d06f9874efddea1dc06c5efe94541a7d6863108e3a5e4b" 265 + dependencies = [ 266 + "same-file", 267 + "winapi-util", 268 + ] 269 + 270 + [[package]] 271 + name = "winapi-util" 272 + version = "0.1.9" 273 + source = "registry+https://github.com/rust-lang/crates.io-index" 274 + checksum = "cf221c93e13a30d793f7645a0e7762c55d169dbb0a49671918a2319d289b10bb" 275 + dependencies = [ 276 + "windows-sys", 277 + ] 278 + 279 + [[package]] 280 + name = "windows-sys" 281 + version = "0.59.0" 282 + source = "registry+https://github.com/rust-lang/crates.io-index" 283 + checksum = "1e38bc4d79ed67fd075bcc251a1c39b32a1776bbe92e5bef1f0bf1f8c531853b" 284 + dependencies = [ 285 + "windows-targets", 286 + ] 287 + 288 + [[package]] 289 + name = "windows-targets" 290 + version = "0.52.6" 291 + source = "registry+https://github.com/rust-lang/crates.io-index" 292 + checksum = "9b724f72796e036ab90c1021d4780d4d3d648aca59e491e6b98e725b84e99973" 293 + dependencies = [ 294 + "windows_aarch64_gnullvm", 295 + "windows_aarch64_msvc", 296 + "windows_i686_gnu", 297 + "windows_i686_gnullvm", 298 + "windows_i686_msvc", 299 + "windows_x86_64_gnu", 300 + "windows_x86_64_gnullvm", 301 + "windows_x86_64_msvc", 302 + ] 303 + 304 + [[package]] 305 + name = "windows_aarch64_gnullvm" 306 + version = "0.52.6" 307 + source = "registry+https://github.com/rust-lang/crates.io-index" 308 + checksum = "32a4622180e7a0ec044bb555404c800bc9fd9ec262ec147edd5989ccd0c02cd3" 309 + 310 + [[package]] 311 + name = "windows_aarch64_msvc" 312 + version = "0.52.6" 313 + source = "registry+https://github.com/rust-lang/crates.io-index" 314 + checksum = "09ec2a7bb152e2252b53fa7803150007879548bc709c039df7627cabbd05d469" 315 + 316 + [[package]] 317 + name = "windows_i686_gnu" 318 + version = "0.52.6" 319 + source = "registry+https://github.com/rust-lang/crates.io-index" 320 + checksum = "8e9b5ad5ab802e97eb8e295ac6720e509ee4c243f69d781394014ebfe8bbfa0b" 321 + 322 + [[package]] 323 + name = "windows_i686_gnullvm" 324 + version = "0.52.6" 325 + source = "registry+https://github.com/rust-lang/crates.io-index" 326 + checksum = "0eee52d38c090b3caa76c563b86c3a4bd71ef1a819287c19d586d7334ae8ed66" 327 + 328 + [[package]] 329 + name = "windows_i686_msvc" 330 + version = "0.52.6" 331 + source = "registry+https://github.com/rust-lang/crates.io-index" 332 + checksum = "240948bc05c5e7c6dabba28bf89d89ffce3e303022809e73deaefe4f6ec56c66" 333 + 334 + [[package]] 335 + name = "windows_x86_64_gnu" 336 + version = "0.52.6" 337 + source = "registry+https://github.com/rust-lang/crates.io-index" 338 + checksum = "147a5c80aabfbf0c7d901cb5895d1de30ef2907eb21fbbab29ca94c5b08b1a78" 339 + 340 + [[package]] 341 + name = "windows_x86_64_gnullvm" 342 + version = "0.52.6" 343 + source = "registry+https://github.com/rust-lang/crates.io-index" 344 + checksum = "24d5b23dc417412679681396f2b49f3de8c1473deb516bd34410872eff51ed0d" 345 + 346 + [[package]] 347 + name = "windows_x86_64_msvc" 348 + version = "0.52.6" 349 + source = "registry+https://github.com/rust-lang/crates.io-index" 350 + checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec"
+5
parakeet-lexgen/Cargo.toml
··· 4 4 edition = "2021" 5 5 6 6 [dependencies] 7 + clap = { version = "4.5.26", features = ["derive"] } 8 + eyre = "0.6.12" 9 + serde = { version = "1.0.217", features = ["derive"] } 10 + serde_json = "1.0.136" 11 + walkdir = "2.5.0"
+30 -2
parakeet-lexgen/src/main.rs
··· 1 - fn main() { 2 - println!("Hello, world!"); 1 + use clap::Parser; 2 + use walkdir::WalkDir; 3 + 4 + #[derive(Debug, Parser)] 5 + struct Cli { 6 + sources: Vec<String>, 7 + #[clap(short, long)] 8 + out: String, 9 + } 10 + 11 + fn main() -> eyre::Result<()> { 12 + let args = Cli::parse(); 13 + 14 + let lexicon_files = args 15 + .sources 16 + .iter() 17 + .flat_map(|source| WalkDir::new(source).into_iter()) 18 + .filter_map(|entry| entry.ok()) 19 + .filter_map(|entry| { 20 + let path = entry.path(); 21 + 22 + // attempt filtering down to json files 23 + // ends_with matching isn't the greatest, but it should get us most of the way 24 + match path.is_file() && entry.file_name().to_string_lossy().ends_with(".json") { 25 + true => Some(path.to_path_buf()), 26 + false => None, 27 + } 28 + }).collect::<Vec<_>>(); 29 + 30 + Ok(()) 3 31 }