It's most likely due to the VLC RC client wanting an Xterm interactive shell instead of a non-interactive shell, or some weirdness with the VLC OS X app still attempting to launch (It's bouncing in my dock while it runs).
In any case, a simple work around is to have automator launch a script to run in terminal.
The script would be simply:
#/bin/bash
/Applications/VLC.app/Contents/MacOS/VLC -I rc http://open.live.bbc.co.uk/mediaselector/5/select/mediaset/http-icy-mp3-a/vpid/bbc_radio_fourfm/format/pls.pls --sout '#standard{mux=raw,access=file{overwrite},dst=/Users/person/Documents/scripts/r4.mp3,display=novideo}' --run-time=1800 --stop-time=1800
It should have execute permissions (chmod +x)
Then from Automator, you launch it like you normally would. In this case, I had Automator "Run Shell Script" of
open -a Terminal /path/to/script.sh
Note you may want to add the --play-and-exit
option, otherwise VLC will stay open even after the 1800 seconds. By default, it will stop at the end of the playlist and wait. --play-and-exit
will tell it to quit when the playlist ends (in this case a single file).
Alternatively, you can directly launch the script with a double click, skipping Automator completely, if you change the suffix to .command. That may be more direct, depending on your actual goal.
Best Answer
As you've likely discovered,
touch
ing a nonexistent file will create a zero-byte file with the name you specify. (touch
is also used to update the modification time on an existing file. Seeman touch
for further details.)The problem you're running into is that though a completely empty file is valid HTML, text, or Markdown, it is not valid RTF—this is true of many file formats, actually, which are structured in a particular way and require some data to be present be valid.
Based on my experimentation, the bare minimum RTF file appears to be
If you'd like to create a blank RTF file from the shell, try this:
Note the above will overwrite
Foo.rtf
if it exists.