From Amarok Wiki

Sorry, but Amarok-svn is on hiatus until I'm able to use Amarok 2.0. (Kinda means 'when there are good KDE 4 packages for Kubuntu'...). I don't have the time to fiddle on it right now. The Amarok 2.0 edition should be rewritten i ruby, though. :)

Due to a cleanup in KDE's SVN, Amarok-svn 3.2 can't download unsermake anymore. Solution: Upgrade to Amarok-svn 3.2.1. If you have unsermake installed system wide, you don't need to upgrade.

This script installs the current 1.x version of Amarok (what will be 1.4.8) (from SVN) on your computer. If you've run it once, and then run it again, it will update your version of Amarok and only compile the new files.

(Amarok-svn was earlier known as amaroK-svn and (even earlier) get-amarok-svn.sh.)

The latest version needs some KDE applications (installing KDE is recommended) and "svn" (subversion, 1.1 or higher!) to work.

Made by Jocke "Firetech" Andersson. Idea and inspiration from a small script by Greg "oggb4mp3" Meyer.

NOTE: I'm not responsible for any data loss etc. that can be blamed on this script. Use it at your own risk! (3.X has some code that might, but shouldn't, do bad things. See the ChangeLog for details.)

Screenshots: (Version 3.0) 1 2 3

Amarok-svn is also available at www.kde-apps.org. (The latest version is also uploaded to their server, in case the server linked to here is down.)

Contents

Getting the script

The latest stable version of Amarok-svn is 3.2.1' (The development version is available in KDE SVN (Amarok's script folder) and links to some usable older versions are available in the ChangeLog below.)

1) Click on this link to download the script. (You probably want to right click and select "Save link as" or something like that.)

2) Open up a terminal window. (For example Konsole.)

3) "cd" to the directory where you put the file (E.G. "cd /home/you/amarok")

4) Run the following command:

  • chmod +x amarok-svn.sh

5) To download and install Amarok from SVN, run the following command:

  • ./amarok-svn.sh

If you've upgraded to 3.2 from any old version, you will need to remove the build directory (amarok-svn) before running the script!

Notes

  • When you start the script for the first time, you will be asked some questions. The answers to these will be saved, and you will not be asked for the answers again (unless you want to)
  • To change the settings run the script with either -r or --reset. E.G:
  • ./amarok-svn.sh -r
  • The first time you run the script it will take some time to finish. (On my computer it takes about 15 minutes, but my computer is a bit slow...)
  • You might want to run this script at least once a week or so to always have the newest version of Amarok. (This will not take as long time as the first run.)

TODO

Feel free to add your own suggestions (or comment others) here, but please attach your signature (--~~~~) to your stuff. (Stuff with no signature are written by Firetech)

4.0 Goals:

  • Rewrite the script in Ruby (maybe python, but markey promised to help me with ruby ;) )
  • Since the script now also is in the SVN repository (Amarok script folder), create a simple downloading script and make the main script update itself. (This probably means splitting the script into smaller parts)
  • Add an uninstall option (easier to make after splitting the script)
  • Add a CLI option, which bypasses the KDialog windows and does command line configuration etc.
  • Allow specific revisions to be checked out - handy for going backwards! --Danglewtf 04:23, 30 May 2006 (EDT)
  • Add an option to select another config file.

ChangeLog

Version 3.2.1 (2007-10-03)

  • FIX: unsermake was moved in KDE's SVN. If you let Amarok-svn download unsermake before, you'll have to remove your amarok-svn/unsermake directory before running the script. If you have unsermake installed system wide, you don't need this patch.

Version 3.2 (2007-02-03)

  • FIX: Some minor string changes
  • CHG: checkout data from branches/stable instead of trunk, since trunk now is Amarok 2.0 (b0rked atm). This means you have to remove your build directory (amarok-svn) before running the script if you've upgraded from an older version.

Version 3.1.1 (2006-06-14)

  • FIX: Amarok-svn would continue to installation even if compilation failed, due to an "echo" call in the wrong place. (The "clean compilation on error" feature was tested before the "echo" was added...)
  • FIX: Avoid forgotten files to be compiled when running unsermake install by running unsermake twice (doesn't hurt).

Version 3.1 (2006-06-08)

  • NEW: Two "stopwatches" that shows the time taken to compile Amarok, and the total time of the entire process (in minutes and seconds).
  • NEW: If compilation fails, give the user an option to retry with a clean source tree.
  • FIX: If configuration fails due to unmet dependencies, the script should also fail.
  • FIX: A lot of under-the-hood improvements.
  • CHG: KDialog windows now use the Amarok icon.
  • CHG: Renamed to Amarok-svn, because of the recent name change of Amarok itself. File name is unchanged (since it's only lower case letters).

Version 3.0 (2005-12-31)

  • NEW: Checks for and removes files that will be unused after updating. (Saves the old set of uninstall commands and runs them if they differ from the new set of commands.) This feature can behave a bit strange sometimes, but it shouldn't do any harm. If you want to be safer, use version 2.9.
  • NEW: Added support for kdesu, which now is the default tool for getting root privileges.
  • NEW: An optional build ID feature, it adds date and time (without punctuation) to the version number.
  • NEW: Command line help (-h or --help)!
  • NEW: Option to make a clean build (-c or --clean)!
  • NEW: Option to select which svn server to use (-s or --select-server).
  • NEW: Run it with a folder as an argument, and it will download and build Amarok in that folder. (Defaults to '[current directory]/amarok-svn', just like before.) The script warns if the chosen directory already exists and isn't "watermarked" (just answer yes on the warning if you upgrade to this version from an older one), and errors out if exists but isn't a directory.
  • FIX: Code cleanups, more error handling and better command-line options handling.
  • FIX: Better handling of incomplete config files.
  • FIX: If auto-language isn't found (equals ""), don't show the "I detected ..." dialog, just go right to the manual language selection.
  • CHG: Displays the configuration help in a kdialog window instead of console.
  • CHG: Doesn't check for standard tools anymore. (The tools that Kate highlight as standard tools, that is. In other words: things like tr, diff and sed.)
  • CHG: Added a --dontagain flag to the running-as-root warning dialog, so if you're insisting on staying as root, you can get rid of the warning.
  • CHG: Redesigned the settings display (echo)
  • CHG: Moved the config file to kreadconfig's default location ('`kde-config --localprefix`/share/config/amarok-svnrc', which usually means '~/.kde/share/config/amarok-svnrc'), you should remove the old config file ([script directory]/.amarok-svnrc).
  • CHG: Removed the "Ask the friendly people in #amarok on freenode for help" messages, not all people know IRC.
  • CHG: New ChangeLog syntax ;)

Version 2.9 (2005-11-17)

  • Now uses functions for errors, dialogs, config readings/writings and requirements checking.
  • Error outputs are now both made to console and with a kdialog.
  • Moved the (hidden) server setting to the config file. To change server, set the "svn_server" variable in the ".amarok-svnrc" file ("Settings" section). (Default is "svn://anonsvn.kde.org".)
  • The configure help "command" (writing "help" as configure settings) is now case insensitive, thanks to "tr".
  • Added check for diff, which has been needed all the time...

Version 2.8.2 (2005-11-16)

  • Use anonsvn by default, not my own account.

Version 2.8.1 (2005-11-15)

  • "tempfile" wasn't as standard as I thought. Now uses "mktemp" instead.
  • Changed the name of the rc file for the script. If you upgrade, either move ".gassrc" to ".amarok-svnrc" or remove ".gassrc"

Version 2.8 (2005-11-15)

  • Renamed the script from get-amarok-svn.sh to Amarok-svn (file renamed to amarok-svn.sh).
  • Non-critical ERROR: outputs renamed to WARNING:
  • More kdialog usage, critical errors are now outputed via kdialog instead, along with some other stuff. This makes the script able to run without a console. Some cases will still require a console, though.
  • Fixed some messages, some spelling and/or gramatical errors.
  • Now uses a randomized temp file name (using the "tempfile" command) for the localization file.

Version 2.7.1 (2005-11-05)

  • Removed --ignore-externals flag on the update Amarok command. The bksys external was just removed.

Version 2.7 (2005-11-05)

  • Added a way of running ./configure --help within the script.
  • Now asks the user IF he/she want's to supply any extra flags to ./configure, not acting like he/she is expected to add any...
  • Added a hidden setting (inside the script) for which server to use. Usable for those who have SVN accounts.
  • The SVN output now is in English, just like the rest of the script.
  • Added a warning if the user is running the script as root.
  • Now starts "svn up amarok" with the --ignore-externals flag, to prevent recently started bksys breakage.
  • Changed some messages, as usual.

Version 2.5 (2005-08-09)

  • Added a check for kde-config, which I didn't realize was required, and apparently has a tendency to fall out of the PATH...
  • Removed the "Probably a network issue." text on the SVN error messages.
  • Added note about SVN 1.1 required when updating the Amarok files fail.

Version 2.4 (2005-08-08)

  • Now updates unsermake if installed locally for the script only.
  • Fixed a pretty serious bug with checking if localization and/or documentation exists. (Discovered by "soulfly", and only affects version 2.3).
  • If the user specifies no language, the script will revert to en_US directly.

Version 2.3 (2005-08-08)

  • Changed the looks of some messages (localization).
  • Added messages about two earlier hidden processes.
  • (Looked into using unsermake -p for process information during compilation and installation, but the output wasn't very clean, so I changed it back.)

Version 2.2 (2005-08-06)

  • As of this version, the script no longer supports automake, as using automake often results in breakage. Instead, the script uses unsermake exclusively. If unsermake isn't found, it is downloaded for use with this script ONLY.
  • Changed the looks of some messages.

Version 2.1 (2005-08-05)

  • Now outputs which step the process is on ("# X/10 - [What we're doing]").
  • Error messages are now prefixed with "ERROR:" instead of the others' "#".
  • Changed some messages . (Mostly added more information.)

Version 2.0.2 (2005-08-03)

  • Fixed a cosmetic bug in my bug fix for 2.0.1. The first space between the configure flags got cropped at output... No error in the configure call though. This only affected 2.0.1.

Version 2.0.1 (2005-08-03)

  • Fixed a pretty serious bug in the configure flags handling... The first time the script ran after changing the settings, the configure call went bad. This only affected 2.0, though.

Version 2.0 (2005-08-02)

  • Finally, graphical settings and a settings file (requires kdialog, kreadconfig and kwriteconfig).
  • Checks for all (most) required applications on start. svn, sed, kdialog, kreadconfig and kwriteconfig.
  • Language is now first autodetected, then if the user doesn't like the autodetected language, it can be changed.
  • Changed some messages to match the graphical settings.

Version 1.5 (2005-08-02)

  • Checks for svn, sed and kreadconfig before starting script.
  • Changed the behavior of GET_LANG. "" is now equal to "auto", and American English got changed to "en_US".
  • Now outputs some about info on start. (version and credits)
  • Fixed some spelling mistakes.
  • If localized documentation doesn't exist, the American English one is downloaded instead of no documentation at all.
  • The script now lies on a separate server instead of here in this otherwise bloated wiki page...

Version 1.4 (2005-08-01)

  • Added automatic language selection (from the KDE setting), it can be overridden. (Needs kreadconfig and sed to work.)
  • More post command error checks (after SVN, Makefile.cvs and ./configure).
  • Now checks if localization exists before downloading it. (If it doesn't, the script reverts to American English.)
  • Now checks if localized documentation exists before downloading it. (If it doesn't, the script skips the documentation.)
  • Modified some messages. (One had a bug, the rest were changed to be, hopefully, more helpful.)

Version 1.0 (2005-07-05 + some fixes afterwards)

  • First released version of the script.