How can I display the remaining time of a Spotify song on my Touch Bar?How much does the Spotify app use the...

Can compressed videos be decoded back to their uncompresed original format?

How to Prove P(a) → ∀x(P(x) ∨ ¬(x = a)) using Natural Deduction

If a warlock makes a Dancing Sword their pact weapon, is there a way to prevent it from disappearing if it's farther away for more than a minute?

how do we prove that a sum of two periods is still a period?

Bullying boss launched a smear campaign and made me unemployable

How can I deal with my CEO asking me to hire someone with a higher salary than me, a co-founder?

Notepad++ delete until colon for every line with replace all

Can I hook these wires up to find the connection to a dead outlet?

How badly should I try to prevent a user from XSSing themselves?

How to compactly explain secondary and tertiary characters without resorting to stereotypes?

Solving an equation with constraints

Is it a bad idea to plug the other end of ESD strap to wall ground?

One verb to replace 'be a member of' a club

Rotate ASCII Art by 45 Degrees

How can a day be of 24 hours?

my venezuela girlfriend wants to travel the USA where i live.what does she need to do and how expensive will it become or how difficult?

Finding the reason behind the value of the integral.

What Exploit Are These User Agents Trying to Use?

What is the opposite of "eschatology"?

How obscure is the use of 令 in 令和?

What is a Samsaran Word™?

Fair gambler's ruin problem intuition

Why didn't Boeing produce its own regional jet?

Do creatures with a listed speed of "0 ft., fly 30 ft. (hover)" ever touch the ground?



How can I display the remaining time of a Spotify song on my Touch Bar?


How much does the Spotify app use the network?how can I save the layout of my open apps on osx?How can I make my DisplayLinked monitor display WPF apps correctly?on Spotify, how can I block all rap and r&b music?How can I hide the Box SimpleShare preferences pane when the app starts?How can I open a folder in the current finder window?How to control Spotify via another computer on the same network?How do I filter in a playlist in the new Spotify interface (on mac)?How to test volume levels on Macbook Pro with Touch BarOn Spotify, can I tell it to 'after the current song finishes, start playing this album'?













0















Currently, I'm using BetterTouchTool (BTT) to automate tasks.
I was wanting to make a script that would display the time a song has left (in MM: SS format) as a label on my Touch Bar.



Here's what I tried doing to achieve this goal (have a button set up to trigger this script):



if application "Spotify" is running then
tell application "Spotify"
return (duration of current track) - (player position)
end tell
else
return ""
end if



It's not giving me the output I was expecting. Does anyone know how to fix it?










share|improve this question



























    0















    Currently, I'm using BetterTouchTool (BTT) to automate tasks.
    I was wanting to make a script that would display the time a song has left (in MM: SS format) as a label on my Touch Bar.



    Here's what I tried doing to achieve this goal (have a button set up to trigger this script):



    if application "Spotify" is running then
    tell application "Spotify"
    return (duration of current track) - (player position)
    end tell
    else
    return ""
    end if



    It's not giving me the output I was expecting. Does anyone know how to fix it?










    share|improve this question

























      0












      0








      0








      Currently, I'm using BetterTouchTool (BTT) to automate tasks.
      I was wanting to make a script that would display the time a song has left (in MM: SS format) as a label on my Touch Bar.



      Here's what I tried doing to achieve this goal (have a button set up to trigger this script):



      if application "Spotify" is running then
      tell application "Spotify"
      return (duration of current track) - (player position)
      end tell
      else
      return ""
      end if



      It's not giving me the output I was expecting. Does anyone know how to fix it?










      share|improve this question














      Currently, I'm using BetterTouchTool (BTT) to automate tasks.
      I was wanting to make a script that would display the time a song has left (in MM: SS format) as a label on my Touch Bar.



      Here's what I tried doing to achieve this goal (have a button set up to trigger this script):



      if application "Spotify" is running then
      tell application "Spotify"
      return (duration of current track) - (player position)
      end tell
      else
      return ""
      end if



      It's not giving me the output I was expecting. Does anyone know how to fix it?







      macbook-pro applescript spotify






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked 34 mins ago









      Brayden HermannBrayden Hermann

      113




      113






















          0






          active

          oldest

          votes












          Your Answer








          StackExchange.ready(function() {
          var channelOptions = {
          tags: "".split(" "),
          id: "3"
          };
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function() {
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled) {
          StackExchange.using("snippets", function() {
          createEditor();
          });
          }
          else {
          createEditor();
          }
          });

          function createEditor() {
          StackExchange.prepareEditor({
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: true,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: 10,
          bindNavPrevention: true,
          postfix: "",
          imageUploader: {
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          },
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          });


          }
          });














          draft saved

          draft discarded


















          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f1420680%2fhow-can-i-display-the-remaining-time-of-a-spotify-song-on-my-touch-bar%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown

























          0






          active

          oldest

          votes








          0






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes
















          draft saved

          draft discarded




















































          Thanks for contributing an answer to Super User!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid



          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.


          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f1420680%2fhow-can-i-display-the-remaining-time-of-a-spotify-song-on-my-touch-bar%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          VNC viewer RFB protocol error: bad desktop size 0x0I Cannot Type the Key 'd' (lowercase) in VNC Viewer...

          Tribunal Administrativo e Fiscal de Mirandela Referências Menu de...

          looking for continuous Screen Capture for retroactivly reproducing errors, timeback machineRolling desktop...