hangxingliu / vscode-coding-tracker

:clock10: A coding activities tracker(time, file, type)
GNU General Public License v3.0
171 stars 34 forks source link

[Question] csv extracts? #19

Closed mwmcode closed 6 years ago

mwmcode commented 6 years ago

Hello,

Thanks for the awesome plugin!

Is it in your plans to add support for csv extracts option? i.e. when on a project page one could extract the files worked on and the amount of time spent on them for that project.

hangxingliu commented 6 years ago

Yes. But not so soon to add this function into. maybe it will appear in next version of vscode-coding-tracker-server.

Actually, The CSV format is my first thought about data storage. But I replace it to a custom format for less size and easy operation without third party libraries.

And if you want export data into CSV just now but not after next version. You can write a small script to convert data files in $HOME/.coding-tracker/.

Although this format is flexible and extendable. but it is very fixed like this:

4.0
0 1519923466129 11536 javascript server.js %2Fhome%2Fuser%2FProjects ubuntuLaptop :: 17 0 0 0
0 1519923466129 11536 javascript server.js %2Fhome%2Fuser%2FProjects ubuntuLaptop :: 17 0 0 0
...

Reference: STORAGE_SYNTAX_V4.md

just read file and split lines and then split space character to get each part of a record item. (remember decodeURIComponent for string and ignore first line of file)

hangxingliu commented 6 years ago

added into server side. it will be release in next version 0.6.0