14 Replies Latest reply: Apr 28, 2010 12:10 AM by Rob Ryan
ruel Level 1 (35 points)

How can I ensure that podcasts will auto-delete after a complete play-through?


Macbook3,1, Mac OS X (10.6.3)
  • Chris CA Level 9 (78,235 points)
    Click Podcasts at the top left of iTunes.
    Click Settings... at the bottom of the window.

    Set *Episodes to keep:* to *All unplayed episodes*.
    You can set it the same for all or set it different for each podcast series.
  • Rob Ryan Level 2 (485 points)
    Chris tells you how to set it up to keep only unplayed podcasts, but I personally find that occasionally I download podcasts where they mysteriously are flagged as "do not allow auto delete". In those cases, you have to manually change them to "allow auto delete" (control-clicking on the tracks), or else regardless of what you do with Chris's procedure, they won't automatically remove themselves.

    I find it very annoying that sometimes podcast downloads are flagged as "do not allow auto delete" (I'd guess it happens less than 5% of the time, but still annoying). But, I personally listen to my podcasts on my iPhone, so in addition to the setting Chris talks about, I also flag my iPhone to only transfer unplayed podcasts. That way, regardless of the "allow auto delete" setting in iTunes, even if they're not auto deleted from iTunes, at least they're removed from my iPhone.

    But if you're listening to podcasts on iTunes on your computer, if you have podcasts that sometimes come through as "do not allow auto delete", you have to manually switch them to "allow auto delete" (or just manually delete them).

    This may be too complicated for you to contemplate, but I also have written a AppleScript that removes podcasts that have been played (in case they're set as "do not allow auto delete"). I have that script run at a scheduled time every day (it also updates my podcasts so they're ready for me when I get up), and that takes care of it for me. So I now no longer have to worry about whether the podcast was downloaded with "allow auto delete" flagged as on or off. Worst case, they're cleaned up for me once a day. AppleScripting (or Windows COM VB scripting) isn't hard, but it isn't for the faint of heart, either. But I mention it as an option. But realistically, we really should have to deal with this silliness.
  • ruel Level 1 (35 points)
    Chris: I had those setting selected already. Thank you though!

    Rob: This is the problem I've been experience (especially with NPR's 'Talk of the Nation').

    It seems this is a problem w/o an easy solution. It's not so bad though.
  • Rob Ryan Level 2 (485 points)
    Yeah, I've seen this with Talk of the Nation, too. A few of my other NPR podcasts occasionally suffer from the same symptom.

    In terms of making life easier, the only thing I can say is that whenever you find a played podcast that isn't getting deleted, you can just highlight all of the podcasts (command-A) and select "Allow Auto Delete". That won't affect the ones that are already flagged as "Allow Auto Delete", but saves you the effort of going through the list and figuring out which ones are appropriately flagged and which ones aren't. This is, of course, assuming that you don't have some downloads where you want to turn off auto delete...
  • Ratbat Level 1 (0 points)
    ctrl A and mark as allow doesn't work in IT9.1, nor does selecting the subscribed podcast and telling it to allow auto delete, you have to now select each and every episode separately and allow it.

    this is REALLY annoying!!
  • Rob Ryan Level 2 (485 points)
    Another 9.1 "feature". I just did 9.1 and am starting to regret it. Some cool features, but some new bugs, too.
  • Doctor Smith Level 1 (0 points)
    Many of the podcasts I listen to are also afflicted with the "Do Not Auto Delete" flag. Losing the ability to do a bulk "Allow Auto Delete" is deeply annoying.

    I tried to throw together an Automator service as work-around, but got stuck. Anyone here have ideas how to create a stop-gap solution?
  • Rob Ryan Level 2 (485 points)
    You can have an AppleScript that deletes played podcasts. I have my machine do this automatically every morning (after it downloads podcasts, so it's ready to go first thing in the morning):

    tell application "iTunes"
        set nothingDeleted to false

        repeat until nothingDeleted
            set nothingDeleted to true
            repeat with podTrack in file tracks of user playlist "Podcasts"
                if played count of podTrack > 0 then
                    delete podTrack
                    set nothingDeleted to false
                    exit repeat
                end if
            end repeat
        end repeat
    end tell

    You can either use osascript to create a cron job to run this in the morning. Or you can invoke it manually from the iTunes AppleScript menus. A variety of options. If you're interested in specifics, let me know.

    (By the way, I'll apologize in advance as I'm an AppleScript newbie, but this does the job for me...)
  • Doctor Smith Level 1 (0 points)
    I gave your script a try, but it seems to only remove the entries for the played podcasts from iTunes, the actual file seems to remain on disk.

    But, thanks for giving it a try! I'll try to build on it to see if I can get it to also delete the file (or at least move it to the Trash).
  • Doctor Smith Level 1 (0 points)
    Hey Rob,

    I built an Automator service based on your AppleScript and posted my solution up at http://zkwarl.blogspot.com/2010/04/remove-played-podcasts.html

    It does contain your sample AppleScript, admittedly republished without your permission, so let me know if you want me to take it down.

    The service I put together first moves the files to the Trash, and then runs the deletion loop on the podcast list. This seems to successfully clean up the list in iTunes and takes care of the file on disk.

    It's a Snow Leopard service, I don't know if it will run on earlier versions of OS X.

    Message was edited by: Doctor Smith
  • Rob Ryan Level 2 (485 points)
    That's great. If you incorporated my AppleScript in your Automator service, I'd only ask that you give me appropriate credit where you've used my script. But you certainly have permission to use it and integrate it into your Automator service. That's why I posted it here, so people would be free to use it as they see fit. Glad to see that it was helpful.

    By the way, I've discovered that the context sensitive menu for "Allow Auto Delete" will appear if you select multiple podcast downloads (even across multiple podcast subscriptions) if and only if the first item selected is an actual download, not the subscription. So, while this does not work:

    But this does:
  • Rob Ryan Level 2 (485 points)
    FYI, I've updated my AppleScript to not only delete played podcasts, but also move the underlying media file (e.g., the mp3 file) to your Trash. You may find the updated script here.
  • wldcrdace Level 1 (0 points)
    found an easy solution from the reverse situation in post http://discussions.apple.com/thread.jspa?messageID=11391993&#11391993
    and tried it out.

    If you switch to grid view, then select all, the options to allow/don't allow auto update is still available and work.

    For some reason it is just broken in list view which is what I think most people use.

    I have too many podcasts to have to select the podcasts with the subscription title in order to fix it every so often.
  • Rob Ryan Level 2 (485 points)
    This bug was fixed in 9.1.1!

    Thanks, Apple!