vifm: Improve file preview for tabular data
Slightly improved display of csv files and added tsv to same preview. Added nice previews for json and excel files.
This commit is contained in:
parent
b0bcb9dd60
commit
8c9a233a8b
1 changed files with 8 additions and 4 deletions
|
@ -215,7 +215,7 @@ set viewcolumns=-{name}..,6{}.
|
||||||
|
|
||||||
" Filter-out build and temporary files
|
" Filter-out build and temporary files
|
||||||
"
|
"
|
||||||
" filter! /^.*\.(lo|o|d|class|py[co])$|.*~$/
|
filter! /^.*\.(lo|o|d|class|py[co])$|.*~$/
|
||||||
|
|
||||||
" }}}
|
" }}}
|
||||||
" Mappings {{{
|
" Mappings {{{
|
||||||
|
@ -471,13 +471,17 @@ filetype *.sqlite,*.db
|
||||||
\ sqlite3 %f,
|
\ sqlite3 %f,
|
||||||
|
|
||||||
" tabular data
|
" tabular data
|
||||||
filextype *.csv
|
filextype *.csv, *.xlsx, *.tsv, *.json
|
||||||
\ {Open with visidata}
|
\ {Open with visidata}
|
||||||
\ vd %f,
|
\ vd %f,
|
||||||
fileviewer *.csv
|
fileviewer *.tsv,*.csv
|
||||||
\ tidy-viewer
|
\ tidy-viewer --color-always --title %c
|
||||||
" \ xsv sample 100 %c | xsv table -c8 -p1 -w1,
|
" \ xsv sample 100 %c | xsv table -c8 -p1 -w1,
|
||||||
" \ {cat %c | sed -e 's/,,/, ,/g' | column -s, -t | less -#5 -N -S; }
|
" \ {cat %c | sed -e 's/,,/, ,/g' | column -s, -t | less -#5 -N -S; }
|
||||||
|
fileviewer *.xlsx
|
||||||
|
\ xlsx2csv %c | tidy-viewer --color-always --title %c
|
||||||
|
fileviewer *.json
|
||||||
|
\ jq '.' --color-output %c
|
||||||
|
|
||||||
" Mindmap
|
" Mindmap
|
||||||
filextype *.vym
|
filextype *.vym
|
||||||
|
|
Loading…
Reference in a new issue