added edit command, fixed set -o -

This commit is contained in:
2024-12-22 17:46:44 +01:00
parent fe3951f3c2
commit 66d6bd2a41
8 changed files with 366 additions and 154 deletions

View File

@@ -76,6 +76,13 @@ func (entry *DbEntry) Normalize() {
entry.Size = len(entry.Bin)
}
if strings.Contains(entry.Value, "\n") {
parts := strings.Split(entry.Value, "\n")
if len(parts) > 0 {
entry.Value = parts[0]
}
}
if len(entry.Value) > MaxValueWidth {
entry.Value = entry.Value[0:MaxValueWidth] + "..."
}