achristmascarl / rainfrog

🐸 a database management tui for postgres
https://crates.io/crates/rainfrog
MIT License
2.87k stars 57 forks source link

Show entire column for large values #80

Open elipp opened 2 months ago

elipp commented 2 months ago

description

I couldn't figure out a way to view the entire contents of a jsonb column, for instance. Also, the "yank" command doesn't seem to end up in the clipboard, at least not on wayland...?

Also, rainfrog can be crashed when selecting+copying a row from the results tab, and pasting it to the query editor :D Should probably make a separate bug report about this...

proposed solution

Add (if possible) some kind of popup window to show the JSON column in a (preferably) pretty-printed fashion. Like yazi previews .json files!

achristmascarl commented 2 months ago

thanks for the report; i'm tracking the wayland clipbaord issues here if you're interested: https://github.com/achristmascarl/rainfrog/issues/79

i like the idea of a preview popup for larger json/other values 👍

bjesus commented 2 months ago

I think it would be cool and perhaps a more general solution if we could pipe the value to some app. for example, you press some key and then type fx and now you have your JSONB column inside fx. you type bat and you can scroll through it using bat. essentially, instead of trying to support all the uses cases, let the user choose their desired tool and have rainfrog pipe the value to it. when you quit the app you piped to, you're back in rainfrog.