It is a spoon for hammerspoon
Copy and change from Here
cd ~
cd .hammerspoon/Spoons
git clone https://github.com/northleafup/Caffeine.spoon.git
Then:
If you use my config, please refer this.
else:
Update init.lua file ,add content as follow
hs.loadSpoon("Caffeine")
If there is no directory "~/.hammerspoon/private", please make it
cd ~
cd .hammerspoon
mkdir private
If you want to update the active
and inactive
image, you can redefine it .
Copy example config:
cd ~
cp .hammerspoon/Spoons/Caffeine.spoon/caffeine.lua .hammerspoon/private/caffeine.lua
Then update the activeIcon
or inactiveIcon
value
activeIcon = "caffeine-on.pdf"
inActiveIcon = "caffeine-off.pdf"
Next you shoud place the image file to folder ~/.hammerspoon/Spoons/Caffeine.spoon/