diff --git a/internal/cliio/printer.go b/internal/cliio/printer.go index 8e463fb..a2e0f39 100644 --- a/internal/cliio/printer.go +++ b/internal/cliio/printer.go @@ -43,6 +43,7 @@ type Printer interface { SetErrOut(errOut io.Writer) SetPagerMode(mode string) error Print(str string) + Println(str string) PrintError(err error) PrintTime(time time.Duration) PrintViaPager(str string) @@ -120,7 +121,11 @@ func (p *pgxPrinter) SetPagerMode(mode string) error { // Print writes regular output to the configured output stream. func (p *pgxPrinter) Print(str string) { - printInfo(p.out, str) + printInfo(p.out, Detail.Render(str)) +} + +func (p *pgxPrinter) Println(str string) { + printInfo(p.out, Detail.Render(str)+"\n") } // PrintError writes an error message to the configured error stream. diff --git a/main.go b/main.go index dcceedd..282bc5d 100644 --- a/main.go +++ b/main.go @@ -29,4 +29,7 @@ func main() { printer.PrintError(err) os.Exit(1) } + + printer.Println("Thanks for using Pgxcli.") + printer.Println("see you next time.") }