Hi. Tried to install istats but get an error message saying I don't have permission to write to the ruby folder?
Hello,
can you please fix the Beats battery script? It does not work properly: it is shown in this way.
The correct battery % is 60, but it show also another number.
Thank you so much
@wesbar
try
sudo gem install iStats
Let me know how this goes. I've had trouble with it on catalina
@sacco
Would you mind helping me out with this?
Visit this thread I just made:
Fixing AQT's Bluetooth Widgets
Try follow this guide, specifically the one about "Gem Errors"
Careful to follow them closely and search up anything you doubt
https://medium.com/faun/macos-catalina-xcode-homebrew-gems-developer-headaches-cf7b1edf10b7
I'm not too experienced with the Terminal so I bet that'll help more than I can. It appears II got mine working purely by chance after tearing several files and stuff apart
Running Mojave here. Getting an issue while trying to install Gem iStats for game mode widget that I don't have root permissions. Very strange since I have an admin account. Any recommendations?
this happens with spotify but the album cover and song name appears when i use spotify connect to play on another device, tried reinstalling spotify and the preset, no luck
Open "Script Editor" on your mac, and make a new document.
Put this script in and run, tell me what number shows up
if application "Spotify" is running then
tell application "Spotify"
try
if player state is playing then
set sName to (get name of current track)
set sArtist to (get artist of current track)
if (length of sName) > 25 then
set sName to text 1 thru 22 of sName & "..."
else
set sName to (get name of current track)
end if
if (length of sArtist) > 25 then
set sArtist to text 1 thru 22 of sArtist & "..."
else
set sArtist to (get artist of current track)
end if
if sArtist is not "" then
set nowPlaying to sName & " — " & sArtist
else
set nowPlaying to sName
end if
--fix JSON-Breaking Double Quotes
set aString to nowPlaying
set astid to AppleScript's text item delimiters
set AppleScript's text item delimiters to quote
set aString to text items of aString
set AppleScript's text item delimiters to "\\" & quote
set aString to aString as text
set AppleScript's text item delimiters to astid
-- Quotes have been vanquished
set nowPlaying to aString
set artworkURL to artwork url of current track
set fileName to ((((path to application support folder from user domain) as text) & "BetterTouchTool:" as text) & "spotify_cover.png")
set sNamePlist to ""
set sArtistPlist to ""
set plistfile_path to ((((path to application support folder from user domain) as text) & "BetterTouchTool:" as text) & "spotify_playing.plist")
set returnText to "{\"text\":\"" & nowPlaying & "\",\"font_color\": \"255,255,255,255\", \"icon_path\":\"" & (POSIX path of fileName as text) & "\" }"
-- read the plist file
tell application "System Events"
try
if file plistfile_path exists then
tell property list file plistfile_path
tell contents
set sNamePlist to value of property list item "sName"
set sArtistPlist to value of property list item "sArtist"
end tell
end tell
end if
if (sName is sNamePlist) and (sArtist is sArtistPlist) then
--return "Found it!"
tell application "BetterTouchTool" to set_string_variable "ShowNotPlayingMsg1" to "false"
--return returnText
return "1"
end if
on error
tell application "BetterTouchTool" to set_string_variable "ShowNotPlayingMsg1" to "true"
--return "{\"text\":\" Spotify \",\"font_color\": \"255,255,255,255\"}"
return "2"
end try
end tell
if (sName is not sNamePlist) or (sArtist is not sArtistPlist) then
tell application "System Events"
try
-- create an empty property list dictionary item
set the parent_dictionary to make new property list item with properties {kind:record}
-- create new property list file using the empty dictionary list item as contents
set this_plistfile to ¬
make new property list file with properties {contents:parent_dictionary, name:plistfile_path}
make new property list item at end of property list items of contents of this_plistfile ¬
with properties {kind:string, name:"sName", value:sName}
make new property list item at end of property list items of contents of this_plistfile ¬
with properties {kind:string, name:"sArtist", value:sArtist}
on error
tell application "BetterTouchTool" to set_string_variable "ShowNotPlayingMsg1" to "true"
--return "{\"text\":\" Spotify \",\"font_color\": \"255,255,255,255\"}"
return "3"
end try
end tell
do shell script "curl " & artworkURL & " -o ~/Library/Application\\ Support/BetterTouchTool/spotify_cover.png"
tell application "BetterTouchTool" to set_string_variable "ShowNotPlayingMsg1" to "false"
--return returnText
return "4"
end if
else
tell application "BetterTouchTool" to set_string_variable "ShowNotPlayingMsg1" to "false"
--return "{\"text\":\" Spotify \",\"font_color\": \"255,255,255,255\"}"
return "5"
end if
on error
tell application "BetterTouchTool" to set_string_variable "ShowNotPlayingMsg1" to "false"
--return "{\"text\":\" Spotify \",\"font_color\": \"255,255,255,255\"}"
return "6"
end try
end tell
else
tell application "BetterTouchTool" to set_string_variable "ShowNotPlayingMsg1" to "true"
return "7"
end if
After installing the latest BTT update I ran into the same issue as @platterfoot. I tried the script you posted and it returned "1". Also, now the "current song" is gone entirely on the Spotify app set.
song playing it returned 1, song paused it returned 5
Hi, im new here, im having trouble when enter to YouTube the stock Touch Bar appears and can't use de YouTube widget that you made, unless go yo the AquaTouch button then YouTube, but every time I change tabs, when go I back to the YouTube tab again the stock Touch Bar appears
to create a toggle button for sidecar , this script work perfectly on and off. no need to go to setting anymore :):
tell application "System Preferences"
activate
set the current pane to pane id "com.apple.preference.sidecar"
get the name of every anchor of pane id "com.apple.preference.sidecar"
delay 1
tell application "System Events"
set target_button to a reference to (first button whose name is "Disconnect") of (window "Sidecar" of application process "System Preferences")
if target_button exists then
click target_button
else
click menu button "Select Device" of window "Sidecar" of application process "System Preferences"
count menu items of menu of menu button "Select Device" of window "Sidecar" of application process "System Preferences"
select item 1 of menu button "Select Device" of window "Sidecar" of application process "System Preferences"
key code 125
key code 76
end if
end tell
quit
end tell
I can't tell exactly whats wrong with the spotify widget but I can definitely tell that something is wrong.
Results helped, I'll probably rewrite the script as it looks a mess. will @mention again once I do but for now I'm quite busy with assessments
ok thank you for the reply and look forward to seeing more of your work
We can get support for Microsoft Edge?
I'm having an issue going right a tab on chrome. Going left a tab is fine. Safari works fine with both. I'm on the newest version 3.5.8a on Mac 10.15.4 and Chrome Version 81.0.4044.138 (Official Build) (64-bit) with a MacBook Pro 16.
Received! will look into it though I'm quite busy right now.
So sorry for the late reply too!
Really loving this. One thing GoldenChaos has that I love is the 1Password button for fast access to 1password. I wonder if there's a way to add it to AquaTouch somehow/somewhere. Or is there a way I could add it myself manually so it's there sitting next to the TouchID button ready and waiting?
Also, and forgive me if this is already an option and I'm just missing it; is there a way to set the default behaviour when in an app that isn't supported to not show the gesture bar and just show the stock Touch Bar options? I'd rather not have to tap that little area before I see the stock options, especially since most of the apps I currently use don't have AT presets, but do have their own Touch Bar buttons.
Thanks!
Again, really impressed with this thing!!