feat(tokenizer): string tokenizing

This commit is contained in:
Khaïs COLIN 2025-05-24 13:28:56 +02:00
parent f259b079b7
commit 00e9bc3b60
Signed by: logistic-bot
SSH key fingerprint: SHA256:3zI3/tx0ZpCLHCLPmEaGR4oeYCPMCzQxXhXutBmtOAU
4 changed files with 72 additions and 11 deletions

View file

@ -1,6 +1,6 @@
use std::path::PathBuf;
use rustyline::{history::FileHistory, Editor};
use rustyline::{Editor, history::FileHistory};
fn xdg_state_dir() -> Option<PathBuf> {
if let Ok(dir) = std::env::var("XDG_STATE_DIR") {
@ -31,7 +31,9 @@ pub fn history_file() -> Option<std::path::PathBuf> {
Some(state.join("cli_history"))
} else {
eprintln!("Warning: failed to find or create XDG_STATE_DIR for osdb.");
eprintln!("Warning: either set XDG_STATE_DIR or HOME, and ensure osdb has write permissions to that directory.");
eprintln!(
"Warning: either set XDG_STATE_DIR or HOME, and ensure osdb has write permissions to that directory."
);
None
}
}