Created
August 15, 2011 16:05
-
-
Save dtinth/1147065 to your computer and use it in GitHub Desktop.
Get currently playing track.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <stdlib.h> | |
#include <unistd.h> | |
int main() { | |
execl("/usr/bin/osascript", "osascript", | |
"-e", "tell the application \"iTunes\" to get (the name of current track) & \" ----- \" & (the artist of current track) as string", NULL); | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment