Copy Selected Tracks

Amarok 2.x Scripts

Source i (link to git-repo or to original if based on someone elses unmodified work):

Add the source-code for this project on opencode.net

0
Become a Fan
6.5

Description:
'Copy Selected Tracks' to device or local path.
All further updates have been frozen. This code is free with no license, please feel free to take and update as your own...

Features:
• This script will copy tracks that have been highlighted (aka selected) from a playlist to a destination folder.
• Added feature to convert flac files to mp3 - as long as you have flac.soundforge.net and lame.soundforge.net installed (currently does not work in windows platforms).

Selecting Tracks:
In Amarok, tracks can be selected by clicking on the track, holding ctrl and adding each additionally clicked track to the selection or by holding shift and clicking on a range of tracks.

Copy Tracks:
When imported, the "Copy Selected Tracks..." menu item will be added to the tools menu.

Importing Scripts into Amarok:
Amarok looks for scripts in the ~/$KDEHOME/share/apps/amarok/script/yourscriptname/ directory. $KDEHOME is likely .kde, .kde4 or .amarok-nightly if you use Neon.

Pending Updates:
None at the moment, I generally wrote this for myself to copy songs to my media device (mp3 player). But I wanted to share if this is useful to anyone. If you have any ideas, I'd love to hear them.

• Additional languages easily added. Current language found in en.js. If you can translate this file, i'd gladly add additional languages.

Outstanding Issues:
• tbd...

Tags: copy songs, copy tracks, copy files, amarok, media device.
Last changelog:

0.1 - released to public
0.2 - added convert flac to mp3 feature and artist/album folder structure. Conversion requires installation of flac and lame (lame.sourceforge.net and flac.soundforge.net). Not compatible with windows platforms yet.


Ratings & Comments

14 Comments

spiritofelric

Hi everyone... Sorry i haven't updated the code in months. I've been on other projects and wrote this to copy music to my mp3 player back when I used Amarak. I hope you found it useful. I have no plans to update this further. Anyone can feel free to take the ownership for the script and update their own version. This is free code and I have no claims or even a need for my signature on it...

e1nste1n

is it possible to save flac tags into converted mp3's?

marcs

I lately make heavy use of this tool, thanks. However, I have different folders in which I copy and always have to click through the directory structure. It would be great if the last 5 folders could be remembered.

DenisSeidel

Thanks for this very useful script. I'm wondering about this isn't almost part of Amarok.However, I'm looking forward for ogg/oga-support for the converting-functionality of your script, because my Mp3-Players only support mp3, wav or wma. Will it come?

Kirilo

For my home use I translate all Amarok scripts I have into German. I'm glad I can share it in this case: http://www.cyrilbrosch.net/de.js

spiritofelric

Amazing! Thank you so much. I'll definitely add this.

DenisSeidel

Danke dafür ^^

spiritofelric

Okay... It's in a very beta stage, but it will make a mp3 copy of your flac file on the destination specified. You will need http://flac.sourceforge.net/ and http://lame.sourceforge.net/ installed on your system (you probably already have flac - they're small command line programs). It takes a while to convert each file - 30seconds approximately. Let me know if you have any issues.

jabster

Ooh! Just saw this yesterday! Awesome! Works great for the FLAC files! However (you know there's gotta be a however) ;-) ....I wanted it to convert OGG's as well. But, now that I have a starting point, I am able to use my Amazing Programming Skills(tm) to modify your code! :-) So, I have now modified it to convert FLAC and OGG to MP3s! I also modified your code to stop using flac and lame, and to use ffmpeg instead. Not really sure what's better for general distribution tho. Both lame and ffmeg (with mp3 support) need to be installed from outside the "official" repos. But ffmpeg seems to be much quicker. I will try send the updated files over to you later today. I'll try and make diff files for you. Thanks again! -john

jabster

Ok...I'm having trouble with the diff files...so the files are here: http://www.jabster.net/amarok/ main.js & en.js en.js: changed to "const LANG_CTconvert="Convert FLAC/OGG files to MP3 (slow)";" main.js: -changed function name from "convertFlacToMp3" to "convertToMp3" since it does both now -test program lines: added check for ffmpeg; changed error messages a bit. -relevant function conversion line: "pConvert.start("ffmpeg -y -ab 128k -ac 2 -i \"" + strSource + "\" \"" + strDest + "\"");" Seems to be working fine. Let me know what you think. Thanks, -john

tifff

Using sox as a flac/ogg/... decoder allows to change more attributes. I use it e.g. for tempo control (additionally added to Dialog.js) to adjust tempo for dance competitions. To play using different tempo (without file conversion) I prefer the dbus-monitor together with dbus-send to stop/pause/restart amarok during playing with sox.

jabster

Hi. Would it be possible to add a "Convert to MP3 and Copy" option? Problem is that my wife's MP3 player only plays OGG & MP3, not flac, which is a hefty part of my collection. So if she could just create a playlist in amarok, and then select convert & copy, she would have a really easy time of loading up her mp3 player. Just hard-code to 128 bitrate probably. If you need "encouragement" let me know, and I'll see what I can do. (I'd try and do it myself but I have very limited programming ability.) thanks, john

spiritofelric

Hi John, There are no tools within Amarok for conversion, however, it is still a possibility if I call on an external tool. What OS are you running on? I could do some research on getting this done... but i'd like to look into your platform first ;). Cheers, Elric

jabster

Hi. I'm running Mandriva 2010.0 with the PLF repos. KDE SC 4.4 and amarok 2.2.0. thanks again, john

Pling
0 Affiliates
Details
license
version 0.2
updated
added
downloads 24h 0
mediaviews 24h 0
pageviews 24h 0

Other Amarok 2.x Scripts:

raya
raya1234
last update date: 15 years ago

Score 5.0

Partition Assistant
shiny521
last update date: 15 years ago

Score 5.0

google-clone
jenifferhomes
last update date: 15 years ago

Score 5.6

Quran Audio Library
boubakr92
last update date: 12 years ago

Score 4.4

Remove Current Track
alexoleshkevich
last update date: 14 years ago

Score 4.7

indoLyrics
cyrus007
last update date: 14 years ago

Score 4.7



System Tags