natureco-cli 5.7.8 → 5.7.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "natureco-cli",
|
|
3
|
-
"version": "5.7.
|
|
3
|
+
"version": "5.7.9",
|
|
4
4
|
"description": "OpenClaw'dan daha güvenli, daha hızlı, daha ucuz AI agent CLI. Multi-agent, self-evolving skills, audit log, maliyet optimizasyonu ve NatureCo platform-native.",
|
|
5
5
|
"bin": {
|
|
6
6
|
"natureco": "bin/natureco.js"
|
package/src/commands/repl.js
CHANGED
|
@@ -728,11 +728,12 @@ async function startRepl(args) {
|
|
|
728
728
|
const line = restoreNewlines(input).trim();
|
|
729
729
|
if (!line) { rl.prompt(); return; }
|
|
730
730
|
|
|
731
|
-
// Çok satırlı paste
|
|
732
|
-
//
|
|
731
|
+
// Çok satırlı paste: placeholder'lar output'tan gizlendiği için
|
|
732
|
+
// terminalde tek satırda birikmiş olan paste ekosunu temizle,
|
|
733
|
+
// yerine özet yaz.
|
|
733
734
|
const newlineCount = (line.match(/\n/g) || []).length;
|
|
734
735
|
if (newlineCount > 0) {
|
|
735
|
-
process.stdout.write(`\x1b[
|
|
736
|
+
process.stdout.write(`\x1b[1A\x1b[J[Pasted ~${newlineCount + 1} lines]\n`);
|
|
736
737
|
}
|
|
737
738
|
|
|
738
739
|
// Slash komutlar
|
|
@@ -182,9 +182,12 @@ function restoreNewlines(line) {
|
|
|
182
182
|
|
|
183
183
|
/**
|
|
184
184
|
* createOutputFilter — Readline'ın output'unda dolaşan placeholder
|
|
185
|
-
* karakterlerini (NEWLINE_PLACEHOLDER)
|
|
186
|
-
*
|
|
187
|
-
*
|
|
185
|
+
* karakterlerini (NEWLINE_PLACEHOLDER) TAMAMEN gizleyen bir wrapper.
|
|
186
|
+
* Kullanıcı terminalde ne placeholder yazılarını ne de satır sonlarını
|
|
187
|
+
* görür — paste içeriği terminal ekosunda yer kaplamaz.
|
|
188
|
+
*
|
|
189
|
+
* Paste'in içeriği terminalde görünmez; repl.js line handler'ı paste
|
|
190
|
+
* algılandığında "[Pasted ~N lines]" gibi kısa bir özet yazar.
|
|
188
191
|
*
|
|
189
192
|
* Kullanım:
|
|
190
193
|
* const outFilter = createOutputFilter(process.stdout);
|
|
@@ -194,10 +197,10 @@ function restoreNewlines(line) {
|
|
|
194
197
|
* Readline, echo mekanizmasıyla her karakteri output.write() ile
|
|
195
198
|
* terminale yazar. Placeholder karakterleri de tek tek yazılır.
|
|
196
199
|
* Bu fonksiyon bir state machine tutar: karakterleri placeholder
|
|
197
|
-
* ile eşleştirir, tam eşleşme olursa
|
|
198
|
-
* olduğu gibi geçirir. Kısmi
|
|
199
|
-
*
|
|
200
|
-
* buffer'da bekletilir.
|
|
200
|
+
* ile eşleştirir, tam eşleşme olursa placeholder'ı ATAR (terminalde
|
|
201
|
+
* hiçbir iz kalmaz), olmazsa karakteri olduğu gibi geçirir. Kısmi
|
|
202
|
+
* eşleşmeler (chunk sınırında bölünmüş placeholder) sonraki
|
|
203
|
+
* write()'da tamamlanmak üzere partial buffer'da bekletilir.
|
|
201
204
|
*/
|
|
202
205
|
function createOutputFilter(output = process.stdout) {
|
|
203
206
|
let partial = '';
|
|
@@ -217,7 +220,7 @@ function createOutputFilter(output = process.stdout) {
|
|
|
217
220
|
partial += ch;
|
|
218
221
|
i++;
|
|
219
222
|
if (partial === NEWLINE_PLACEHOLDER) {
|
|
220
|
-
|
|
223
|
+
// Placeholder'ı terminalde gösterme — output'tan tamamen çıkar
|
|
221
224
|
partial = '';
|
|
222
225
|
}
|
|
223
226
|
} else {
|