sobolevn / wakatime-zsh-plugin

🕒Track how much time you have spent in your terminal!
https://wakatime.com/terminal
MIT License
91 stars 10 forks source link

Fixed Issue With The Plugin Not Finding The Wakatime Executable #17

Closed h4ckitt closed 2 years ago

h4ckitt commented 2 years ago

After Following The Install Steps On The Wakatime WIKI (Installed With Antigen), The Plugin Kept Returning Error:

wakatime cli is not installed, run:
$ pip install wakatime
OR:
Option 1: Check that wakatime is in PATH
Option 2: Set a custom path with $ export ZSH_WAKATIME_BIN=/path/to/wakatime-cli
Time is not tracked for now.

I Tracked It Down To The Initialization Of The wakatime_bin Variable Which Was Being Set To A String Literal 'wakatime' Instead Of wakatime So The Type Command Couldn't Resolve Command 'wakatime'.

Although Resetting The ZSH_WAKATIME_BIN Environment Variable Might've Worked (It Didn't For Me), I Just Thought It'd Be Easier To Fix It Out Of The Box Which This PR Does.