Persistent Transcode

Amarok 1.x Scripts

Source (link to git-repo or to original if based on someone elses unmodified work): Add the source-code for this project on

Score 50%


A simple perl script to transcode files (reduce size and quality) when transferring to a portable device. The persistent storage feature allows to save converted files to a user specified directory. Next time Amarok asks for the same file the script will point to the proper location instead of transcoding it again.

Currently the script can transcode:
- FLAC to Ogg Vorbis
- Ogg Vorbis to Ogg Vorbis
- MP3 to Ogg Vorbis

Simply run this script and select "Transcode before transferring to device" and "Whenever possible" in the Configure Media Device window.

To take advantage of the persistent transcoding feature you have to edit the script and set the source and target variables. For example when you are transcoding ~/audio/collection/Artist/Album/Track.flac and you set:

my $source_dir = $ENV{HOME}."/audio/collection";
my $target_dir = $ENV{HOME}."/audio/portable";

the converted file will be saved as ~/audio/portable/Artist/Album/Track.ogg

If you don't want to store transcoded files for further use simply select "Remove transcoded files after transfer" and leave source/target directory configuration at default values.

You must have:
- Perl with URI::Escape and String::ShellQuote modules (on Debian/Ubuntu look for libstring-shellquote-perl and liburi-perl packages)
- oggenc (vorbis-tools package)

You might also need:
for Ogg Vorbis to Ogg Vorbis conversion:
- oggdec
- vorbiscomment

for MP3 to Ogg Vorbis conversion:
- mp32ogg with --quality option support (transcoding mp3 to ogg)

Inspired by Jose Jorge's Transcogg.

This is my first Perl scripting attempt. You have been warned.
Last changelog:

11 years ago

* Persistent Transcode 0.1
- initial release

Be the first to comment

11 years ago

* Persistent Transcode 0.1
- initial release

File (click to download) Version Description Packagetype Architecture Downloads Date Filesize DL OCS-Install
updated Oct 14 2007
added Oct 14 2007
downloads today
page views today 3
System Tags addon