csvlens icon indicating copy to clipboard operation
csvlens copied to clipboard

To use crossterm

Open elferherrera opened this issue 2 years ago • 4 comments

Hi. I just found your crate and it seems that it could work very well with nushell. One little issue is the fact that it does use crossterm. Do you think it is possible to have an implementation with crossterm?

elferherrera avatar Jun 15 '22 19:06 elferherrera

Thanks for reporting! The latest version now uses crossterm. Curious to see how it can be used with nushell.

YS-L avatar Jul 17 '22 10:07 YS-L

In nushell is needed some sort of data visualiser and csvlens works really nice for it. The fact that it uses crossterm is nice because it can be used in multiple platforms.

elferherrera avatar Jul 17 '22 16:07 elferherrera

I'm wondering how we can use this. I mean do we shell out and call an external from nushell or is there a crate we can use? I'll have to investigate a bit more. Or, here's an idea, maybe we turn csvlens into an internal command so we can do some | big | pipeline | lens or some such thing?

fdncred avatar Jul 17 '22 19:07 fdncred

It's indeed possible. I often combine ripgrep and csvlens like the following:

$ rg (header|value) my.csv | csvlens

fMeow avatar Oct 19 '22 05:10 fMeow