wakatime / vim-wakatime

Vim plugin for automatic time tracking and metrics generated from your programming activity.
https://wakatime.com/vim
BSD 3-Clause "New" or "Revised" License
1.04k stars 70 forks source link

Not Showing on my dashboard #170

Closed FkLalita closed 1 year ago

FkLalita commented 1 year ago

i can't see my time on the dashboard but i can see my time on vscode on it, i check the logs but i can't seem to find any error related to vim, but i can see numbers on my vim_shared_state which changes if i code, i assumed that is my code time, but it is not showing on my dashboard, if i try WakaTimeToday or the other cmd i get wakatime-cli is not recognised as an internal or external command.

alanhamlett commented 1 year ago

i can't see my time on the dashboard but i can see my time on vscode on it

Your dashboard is missing vim stats, but has vscode stats?

if i try WakaTimeToday or the other cmd i get wakatime-cli is not recognised as an internal or external command.

Sounds like vim-wakatime plugin can't find ~/.wakatime/wakatime-cli. Can you make sure it's in that location?

alanhamlett commented 1 year ago

Ok, please enable debug mode with :WakaTimeDebugEnable then share the error message printed at the bottom of your Vim after editing a file inside Vim.

FkLalita commented 1 year ago
Error detected while processing BufEnter Autocommands for "*"..function <SNR>60_InitAndHandleActivity[4]..<SNR>60_HandleActivity[10]..<SNR>60_AppendHeartbeat
[21]..<SNR>60_SendHeartbeats:
line  121:
[WakaTime] Command: "C:/Users/DSRC/.wakatime/wakatime-cli.exe" "--entity" "C:\Users\DSRC\Desktop\Go\hello\now.go" "--time" "1697498160" "--plugin" "vim/900 v
im-wakatime/11.0.0" "--alternate-language" "go"^@[WakaTime] Error: '"C:/Users/DSRC/.wakatime/wakatime-cli.exe"' is not recognized as an internal or external
command,^@operable program or batch file.^@    
alanhamlett commented 1 year ago

And if you relaunch vim?

FkLalita commented 1 year ago

I relaunch vim but it is not working

alanhamlett commented 1 year ago

With debug enabled you should see some logs printed when Vim first starts. When it's working it should print:

[WakaTime Install] Current wakatime-cli version is v1.85.2
[WakaTime Install] Checking for updates to wakatime-cli...
[WakaTime Install] GitHub API Response 304
[WakaTime Install] wakatime-cli is up to date.
Press ENTER or type command to continue

But there might be an error message telling us why it's not able to execute C:/Users/DSRC/.wakatime/wakatime-cli.exe on your machine.

FkLalita commented 1 year ago

So I find the error though, I think vim is looking for wakatime-cli.exe but I have wakatime-windows-386-cli.exe, so I renamed to wakatime-cli.exe and I no longer see the error but vscode keep showing wakatime error, so I copy the wakatime-cli.exe and rename it to the default one, so both are working fine I guess, I can now see vim on my dashboard.............. though it is showing unknown project for vim I guess it has to do with my file path.....but I can now see vim on my dashboard 😌

FkLalita commented 1 year ago

i keep getting unknown project on my dashboard anytime i use vim though

alanhamlett commented 1 year ago

Are you using a Git repo for your project?

https://wakatime.com/faq#projects

FkLalita commented 1 year ago

No

alanhamlett commented 1 year ago

Without a Git repo the plugin has no way to detect a project. Please set a project using one of the supported methods.

FkLalita commented 1 year ago

so i will have to have a github repo for the project before the plugin detect it what if i don't want to publish the project on github

alanhamlett commented 1 year ago

There's other ways besides Git. Please read the FAQ link.