SWEATSHOP 11×4: THE HORROR EXPRESS TO ART COLLEGE

Sweatshop, the live art show I produce with the artist E.G. Gauger, returns this Sunday, February 27th with live art commissions, answer to questions about doing art, and the 1973 classic HORROR EXPRESS starring Christopher Lee, Peter Cushing and Telly Savalas. We start early (around 12pm PST), run late (midnight?!), and want you to come. Yeah, you.

Show up, chat with our filthy regulars, buy some art if you’ve got cash and the will to support the arts.

Senate Bill Would Make Leaks a Felony

If the government does it, it can’t be a crime:

Legislation introduced in the Senate this week would broadly criminalize leaks of classified information.  The bill (S. 355) sponsored by Sen. Benjamin Cardin (D-MD) would make it a felony for a government employee or contractor who has authorized access to classified information to disclose such information to an unauthorized person in violation of his or her nondisclosure agreement.

Nixon would’ve been happy about this. Just declare your illegal activities classified and you’re safe. Who wants to get thrown in Federal prison for doing the right thing and snitching? Even if you’re right and you literally save the world from an illegal war you’ll be legally culpable.

Using Applescript to Populate Nicecast’s NowPlaying.txt File

Rogue Amoeba has been a big name in consumer audio software for Mac OS X since their inception. One of their biggest apps is an application for streaming audio to the web from your Mac called Nicecast. I sometimes use Nicecast to stream audio to friends and relatives, and it’s very good software.

There’s one thing that annoys me, though: Nicecast doesn’t automatically update the stream you send with the artist and track title, so your listeners don’t know what they’re hearing unless they’ve either heard it before or ask you. Luckily for us, this is OS X, and that means we have access to Applescript.

Cutting to the chase: copy and paste the code below into Applescript Editor (Located in the ApplicationsUtilities folder on your hard drive) and save it somewhere. Line-wraps are marked ¬, which should be removed from your copy/pasted code.

property sleepTime : 10

repeat
    tell application "iTunes"
        try
            if not (exists current track) then return
            set this_artist to (get artist of current track)
            set this_track to (get name of current track)
        end try
    end tell

    tell application "Finder"
        try
            set current_user to do shell script "whoami"
            set the_file to "/Users/" & current_user & ¬ 
            "Library/Application Support/Nicecast/NowPlaying.txt"

            set eof of the_file to 0
            write ("Artist: " & this_artist & return & "Title: " & ¬ 
            this_track) to the_file

        end try
    end tell
    do shell script "/bin/sleep " & sleepTime
end repeat

The script updates your NowPlaying.txt file every 10 seconds (you can change that setting by modifying the sleepTime property), until you tell it to stop by hitting the “Stop” button in Applescript Editor.

If you found this script useful, a donation would make me feel pretty good about this use of my time.