Rinomina: crate akode-*, cartelle akode-rs/ e akode-cli/, binario akode, ~/.akode, AKODE_* (A)
Riapplica la fase 5 di aKode (86e7c72e) sulla base ripulita:
- crate codex-* -> akode-*, codex-rs -> akode-rs, codex-cli -> akode-cli, binario e ausiliari akode;
- ~/.codex -> ~/.akode, CODEX_HOME -> AKODE_HOME, variabili CODEX_* -> AKODE_*, .codex/ -> .akode/ di progetto;
nessun fallback a ~/.codex o a CODEX_*;
- testi per l'utente "Codex" -> "aKode"; testi verso il modello e istruzioni di sistema invariati;
- snapshot insta rinominati (non ancora rigenerati).
I conflitti con la base ripulita sono stati risolti riapplicando la rinomina ai file senza le
funzioni di imeAI (script di mappa dei token per file).
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
22
akode-rs/core/src/utils/json.rs
Normal file
22
akode-rs/core/src/utils/json.rs
Normal file
@@ -0,0 +1,22 @@
|
||||
#[derive(Default)]
|
||||
struct JsonByteCounter(usize);
|
||||
|
||||
impl std::io::Write for JsonByteCounter {
|
||||
fn write(&mut self, bytes: &[u8]) -> std::io::Result<usize> {
|
||||
self.0 = self.0.saturating_add(bytes.len());
|
||||
Ok(bytes.len())
|
||||
}
|
||||
|
||||
fn flush(&mut self) -> std::io::Result<()> {
|
||||
Ok(())
|
||||
}
|
||||
}
|
||||
|
||||
/// Counts serialized JSON bytes without retaining the serialized output.
|
||||
pub(crate) fn serialized_json_bytes<T: serde::Serialize + ?Sized>(
|
||||
value: &T,
|
||||
) -> serde_json::Result<usize> {
|
||||
let mut counter = JsonByteCounter::default();
|
||||
serde_json::to_writer(&mut counter, value)?;
|
||||
Ok(counter.0)
|
||||
}
|
||||
2
akode-rs/core/src/utils/mod.rs
Normal file
2
akode-rs/core/src/utils/mod.rs
Normal file
@@ -0,0 +1,2 @@
|
||||
pub(crate) mod json;
|
||||
pub mod path_utils;
|
||||
1
akode-rs/core/src/utils/path_utils.rs
Normal file
1
akode-rs/core/src/utils/path_utils.rs
Normal file
@@ -0,0 +1 @@
|
||||
pub use akode_utils_path::*;
|
||||
Reference in New Issue
Block a user