adding a nautilus script



I just found out about the virtues of nautilus scripts.
I copied one of the scripts in .gnome2/nautilus-scripts and 
adapted it to convert a .wav into a .ogg.
I don't know if this is the right/safe way to make a script however.
And i'm not sure if it doesn't contain stupid things.
It works for me however; I can now right click on a .wav file and choose
to convert it to a ogg file instantly.

Maybe it would be nice to add scripts to convert to and from ogg/mp3 to
the standard nautilus verstion.

One question.
Would it be possible to show the option only on .wav files? (i.e. you
can't attempt to convert a .txt file to .ogg)

--Tino Meinen


#!/bin/sh

quoted=$(echo -e "$NAUTILUS_SCRIPT_SELECTED_FILE_PATHS" | awk 'BEGIN {
FS = "\n" } { printf "\"%s\" ", $1 }' | sed -e s#\"\"##)

eval "oggenc -q 5 $quoted"





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]