
Copy Selected Tracks
Source (link to git-repo or to original if based on someone elses unmodified work): Add the source-code for this project on opencode.net
'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.
9 years ago
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.
9 years ago
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.
spiritofelric
9 years ago
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...
Report
e1nste1n
9 years ago
Report
marcs
9 years ago
Report
DenisSeidel
10 years ago
Will it come?
Report
Kirilo
10 years ago
I'm glad I can share it in this case: http://www.cyrilbrosch.net/de.js
Report
DenisSeidel
10 years ago
Report
spiritofelric
10 years ago
Thank you so much. I'll definitely add this.
Report
spiritofelric
10 years ago
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.
Report
jabster
10 years ago
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
Report
tifff
10 years ago
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.
Report
jabster
10 years ago
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
Report
jabster
11 years ago
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
Report
spiritofelric
11 years ago
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
Report
jabster
11 years ago
I'm running Mandriva 2010.0 with the PLF repos. KDE SC 4.4 and amarok 2.2.0.
thanks again,
john
Report