wakatime / eclipse-wakatime

Eclipse plugin for automatic time tracking and metrics generated from your programming activity.
https://wakatime.com/eclipse
BSD 3-Clause "New" or "Revised" License
174 stars 16 forks source link

DBeaver log time spent in DB properties, data, diagram #44

Closed pire closed 1 year ago

pire commented 1 year ago

At the moment it only tracks time spent in the query editor.

Unsure if this is possible, but would be amazing if the plugin could also track the time spent in the other database views Properties, Data, ER Diagram.

alanhamlett commented 1 year ago

Do those views have an associated filename? There's ways around that by changing the heartbeat type to something other than file, but having a filename is best for project detection, branch detection, and language detection.

pire commented 1 year ago

🤔 I'm unsure about a filename tbh! Probably not since they represent tables in databases?

In DBeaver we can create Projects, which contain Connections, and each Connection will have its databases.

At the moment the Project name is sent to Wakatime, and if you are writing SQL, which can be saved as an sql file, as well; By default the filename is Script.sql even if you haven't saved the file.

image

I assume the plugin requires a file to be open to measure time spent on it?

alanhamlett commented 1 year ago

This line might be preventing it from tracking Diagrams:

https://github.com/wakatime/eclipse-wakatime/blob/1c11b623e1b94d28c734558f13cdada91badeb3c/com.wakatime.eclipse.plugin/src/com/wakatime/eclipse/plugin/WakaTime.java#L143

pire commented 1 year ago

I aaaaaaaaaaaaaaaaaaaaaaam clueless about .java!

Would this be something I can find locally, change and try out for you without building the plugin?

Am on MacOS Monterey 12.6

alanhamlett commented 1 year ago

Added support for DBeaver properties, diagrams, and other editor types with 66888a07db5afe7397943b86d4d99bf1fbb0c80f.