From fbc5ebe4cebc94a1ac63b52788087c9dfbc46e0f Mon Sep 17 00:00:00 2001 From: Jeff Carr Date: Fri, 22 Aug 2025 06:12:47 -0500 Subject: [PATCH] wtf. this should work --- argv.go | 1 + doOutput.go | 4 ++++ main.go | 5 +++++ prettyFormat.go | 4 ++-- 4 files changed, 12 insertions(+), 2 deletions(-) create mode 100644 doOutput.go diff --git a/argv.go b/argv.go index 7bc1c87..3b68ffc 100644 --- a/argv.go +++ b/argv.go @@ -13,6 +13,7 @@ type args struct { Add string `arg:"--add" help:"add a new chat"` Format *EmptyCmd `arg:"subcommand:format" help:"add a conversation"` Playback *PlaybackCmd `arg:"subcommand:playback" help:"dump your prior conversations to the terminal'"` + Output string `arg:"--output" help:"should get a string from gemini-cli"` Force bool `arg:"--force" help:"try to strong arm things"` Verbose bool `arg:"--verbose" help:"show more output"` Bash bool `arg:"--bash" help:"generate bash completion"` diff --git a/doOutput.go b/doOutput.go new file mode 100644 index 0000000..0ec3053 --- /dev/null +++ b/doOutput.go @@ -0,0 +1,4 @@ +package main + +func doOutput(s string) { +} diff --git a/main.go b/main.go index 8d5b67a..40811a1 100644 --- a/main.go +++ b/main.go @@ -53,6 +53,11 @@ func main() { me.chats.ConfigSave() } + if argv.Output != "" { + doOutput(argv.Output) + okExit("") + } + if argv.Add != "" { newChats, err := addFile(argv.Add) if err != nil { diff --git a/prettyFormat.go b/prettyFormat.go index 513fe10..8d7ecbd 100644 --- a/prettyFormat.go +++ b/prettyFormat.go @@ -95,7 +95,7 @@ func printLeftAligned(author, timestamp, content string) { func printRightAligned(author, timestamp, content string) { prefix := fmt.Sprintf("(%s) %s ✦", timestamp, author) - + // Print the prefix first, right-aligned. fmt.Printf("%*s\n", termWidth, prefix) @@ -143,7 +143,7 @@ func printCodeSnippet(snippet *chatpb.CodeSnippet) { language := filepath.Base(snippet.GetFilename()) // Still useful for display fmt.Println() // Add extra line feed for spacing - + // --- Top Border --- topBorder := fmt.Sprintf("┌─[ Code Snippet: %s ]", language) fmt.Printf("%s%s┐\n", topBorder, strings.Repeat("─", termWidth-len(topBorder)-1))