Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Request: export table #107

Open
DerWeh opened this issue Nov 19, 2016 · 6 comments
Open

Request: export table #107

DerWeh opened this issue Nov 19, 2016 · 6 comments
Assignees

Comments

@DerWeh
Copy link

DerWeh commented Nov 19, 2016

Would it be possible, to export the table-mode tables to html? It looks like a simple replacement for Excel, less feature rich but way faster to just write small tables. The only thing I am missing, is getting it in a printable format.

Sadly I have to admit I have no idea of such things, hence I don't know if I am asking the impossible. I just saw the feature in vimwiki and thought it would be awesome. You already stat:

For Markdown-compatible tables use

let g:table_mode_corner="|"

I think this should then be easily be possible to convert to html.

@dhruvasagar
Copy link
Owner

Hi,

Yes it would be possible, and fairly easy to convert the tables to html tables, however I am not entirely sure how to close that loop, as in where to place the html tables etc.

@dhruvasagar dhruvasagar self-assigned this Jan 4, 2017
@k33nice
Copy link

k33nice commented Jan 11, 2017

Hi,
I'm think ability to convert table into CSV data would be a cool feature. CSV is on of the most common ways to store tables. Thus it'll be possible to export it in DB, xls, etc. Also ability to convert CSV to table already implemented, so command that toggle it would be amazing.
I'm not very familiar with VimL, but i can try to make PR if it'll demand.

@NicolasWebDev
Copy link

Exporting to CSV would be much more portable indeed.

@dhruvasagar
Copy link
Owner

Should we exported it to a user defined path or just in a new buffer ?

@k33nice
Copy link

k33nice commented Jan 17, 2018

IMO, buffer would be better. User may not want to save it to fs, on the other hand buffer can be easily saved if needed. Thus it will be more flexible.

@unsigned-nerd
Copy link

unsigned-nerd commented Apr 14, 2018

I understand that you want to export vim-table-mode table into CSV through VimL. I need that feature too as I use vim-table-mode to keep a log of expenses while I work as a tour guide for a group of people. After each trip, I have to convert it into LibreOffice Calc file and add spreadsheet formulas in order to charge the expenses to each of them. My customers expect to get the report in Microsoft Excel format, which I then have to convert it again from LibreOffice Calc. It's like using vim-table-mode while I work, then export it into a spreadsheet format for end-users who don't quite understand text file (!). So, while waiting for you to add this feature into vim-table-mode, I have written a small Python script to do just that so I would like to share it just in case someone needs to use it now.

https://github.com/unsigned-nerd/vim-table-mode-to-csv/blob/master/src/vtmtc.py

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants