April 26, 2009

How-To: Enable Last.fm Song Submission in CMus in Debian and Ubuntu

CMus is a very powerful audio player for the console with a ncurses-based interface, support for themes and highly configurable.

Although (at least in Debian) CMus does not come with Last.fm song submission support by default, there is a script available here as a patch, which you can apply to the source, compile CMus again and enable Last.fm support.

Here's what you have to do:

1. Enable sources repositories
Edit the /etc/apt/sources.list file as root with your favourite text editor (e.g. nano /etc/apt/sources.list or kdesu /etc/apt/sources.list) and make sure you have a line which starts with deb-src, as in the example below:

deb-src ftp://ftp.ro.debian.org/debian/ lenny main contrib non-free

You can replace the TLD with the one of your country (e.g. instead of ro use fi for Finland, de for Germany etc.) Next, update the packages list as root:

apt-get update


2. Get the CMus source code
Type, as normal user:

apt-get install git-core

Now issue the command:

git clone git://repo.or.cz/cmus.git

3. Get the Last.fm patch
Go here and download the patch (direct link here). Save it inside the cmus directory. The file is called as.patch

4. Apply the patch
To apply the patch, make sure the current working directory is cmus and type:


patch < as.patch

5. Install CMus dependencies
To install the needed libraries for the compilation, type as root:

apt-get install libncurses5-dev
apt-get build-dep cmus

6. Compile and install CMus
Just type the usual:

./configure
make
make install

The last one as root.

7. Enable the Last.fm song submission script
You can either copy the following three lines inside the ~/.cmus/rc file:

set as_enable=true
set as_user=Lastfm_USER
set as_pass=Lastfm_PASS

Or run the same commands in CMUS like this:

:set as_enable=true
:set as_user=Lastfm_USER
:set as_pass=Lastfm_PASS


Just make sure to replace Lastfm_USER and Lastfm_PASS with the appropiate values.

March 30, 2009

Review: Amarok 2.0.2 - Better Than 1.4?

Amarok always had the reputation of being the most popular and powerful audio player available on the Linux platform, and it really deserved that position. I myself am a fan of Amarok for over three years now, and there was nothing I could think of which Amarok 1.4 did not have.

Usual instance of Amarok 2.0.2 playing

For this review I used Amarok 2.0.2 (which was released to the public on March 5), included in Kubuntu 9.04 Beta (with all the upgrades to date) and I scanned several Ogg Vorbis and FLAC albums, all of them with correctly filled-in tags. I also included a compilation with several artists, which from the start messed up the entire playlist. That is, the albums from a single artist were correctly displayed, while the compilation album was spread in the entire playlist (see the screenshots below). In fact, Amarok only tries to organise tracks on the compilation depending on the artist. So if we have three artists with two songs each, they will be spread in the playlist, sorted by artist's name. Although I like how the single-artist albums are displayed in the playlist, when it comes to compilation this approach tends to mess things up and look inconsistent.

A compilation album including several different artists is spread in the entire playlist

The current version of Amarok 2 does not include all the features 1.4 had, like the equalizer, statistics or queue manager, however it is a new foundation for the releases which will follow. The introduction of widgets is very useful if you ask me, and I also liked the new interface. I know there were a lot of people complaining that the central widget space is a waste and takes up too much of the area when the playlist could have been, but I think it's useful this way. The new approach gives Amarok a more organised look and a logical way of finding all the information one needs at any given time.

Last.fm configuration


Another thing which I miss from Amarok 1.4 series is the ability to go directly to the next and previous tracks in the tag editor. That was a cool feature which made Amarok my audio tag editor of choice. Still, it allows for mass-tagging, which is a good thing. Of course, I'm sure these things will be implemented in the future.

Amarok correctly auto-detected the covers inside the albums' directories and displayed them in the middle panel, which proves to be very useful if used with a lyrics widget, for example.


The collection tab resembles pretty much the one in 1.4, however instead of organizing artists from the compilation albums inside that album's title, they are spread all over the place. This can get extremely annoying if you have large compilations of, say, 50 or more artists, and only a few songs from each of them. Or at least, I liked more the approach in 1.4. After an application restart Amarok did not remember the position of the left tabs, which were disabled (the Collection, Internet, Playlist and Files tabs).

The Add Media... option in the Playlist menu will only allow to add files to the playlist, so I had to use the right-click menu option Load (or Append to Playlist) from the Collection or the file manager tabs.

Some of the old features are still available, like the cover manager (which hasn't changed a bit) and the file manager. I was happy to see the old bug which froze Amarok (at least on Debian Lenny - stable) when right-clicking on a song and going to Edit Track Details in the file manager disappeared. Well, since it was rewritten it is normal to be this way.

A whole bunch of other features are now included in Amarok. Except for the widgets, the Internet tab provides access to no less than seven services, like Last.fm song submission and integration, music from Magnatune.com and Jamendo.com, OpmlDirectory (for lists of podcasts) or Shoutcast Directory (for lists of online radio stations). The script manager also allows to download other scripts from the Internet directly from within Amarok, and they are installed automatically, just like in 1.4 (and with a refined interface, cutting off the additional - and useless - steps when you had to click twice OK - once when the script was downloaded and the second time to notify you that the script was successfully installed).

Amarok now uses only QtScript, so all the scripts for 1.4 had to be rewritten. No more support for languages like Perl, Python or Bash.

Conclusion
As an Amarok 1.4 fan, I must say I also liked Amarok 2 a lot, but there are a lot of things which really need to be fixed and features to be added. What I like the best is the new approach (yeah I know there are a *lot* of people who don't like the new look), but it seems to me the way the widgets are organised and the space management is much more compact and useful now. The playlist is definitely another plus, since it looks twice as good as that simple list in Amarok 1.4 and offers a more clear view on which album belongs to which artist. It is visually more appealing. Instead, it really needs a fast way to jump to song using the keyboard.

Amarok 2.0.2 and KDE desktop effects enabled

I'm looking forward to Amarok 2.1 and I hope only for the best from the team behind this loved and popular player.

Additional screenshots

Cover manager - nothing new or changed here

The new splash screen

Last.fm integration, together with song submission and radio stations access

Magnatune.com music

New and improved script manager

January 14, 2009

Round-up: Most Popular Posts in 2008

9 File Managers for Linux
A brief review containing no less than nine file managers for Linux, from Konqueror or Nautilus to PCManFM, Xfe or Midnight Commander.

25 Essential KDE3 Applications - Review
Started as a review of 20 applications for KDE3, reached the number of no less than 25 applications which I considered essential for daily use.

What Makes Amarok the Most Popular Audio Player for Linux?
Although Amarok has far more features, this article lists 7 reasons why Amarok is the most popular audio player on the Linux platform.

Why Is It So Hard for Windows Users to Understand That Linux Is Not Windows?
A short essay (if you like) on the Linux vs. Windows debate. I tried to keep it clean and "non-laming".

Top 10 Best GTK Applications Not Included in GNOME
A review of 10 applications built in GTK which do not come with GNOME.

10 Reasons to Love Debian
What makes Debian such a loved and popular distribution? Here are 10 reasons from my point of view.

11 Video Players for Linux - Review
A review of 11 video players for the Linux platform: from SMPlayer or Kaffeine to Totem or VLC.

10 Best KDE Applications Not Included in KDE
A review of 10 applications built using Qt but which do not come by default with the K Desktop Environment. Note: Only KDE3 applications in this review.

12 Web Browsers for Linux - Review
An article which briefly reviews 12 web browsers for Linux, both with graphical or CLI interfaces. Firefox, Opera, Konqueror, Kazehakase, w3m, lynx... they are all here.

Xfe Review - Wonderful File Manager
Review of the lightweight but powerful enough file manager, Xfe.

One of My Favourites - Wolfenstein: Enemy Territory
A review of the beautiful and popular online shooter, Wolfenstein: Enemy Territory.

SMPlayer Review - One of the Most Powerful Video Players for Linux

As the title suggests, this article reviews SMPlayer, a popular video player built in Qt 4 with lots of features and highly configurable.

October 26, 2008

Test Firefox 3.1 Beta 1 in Debian Without Changing Your Existing Installation

Firefox 3.1 Beta 1 was released on October 14, 2008 and it currently comes in 36 fully-localised languages. This beta is based on Gecko 1.9.1 layout engine and according to the official website, this release features "significant changes to improve web compatibility, performance and ease of use". You can read the release notes on the official website, here.

Debian Lenny comes with Iceweasel 3.0.3, which is actually Firefox with a changed name and a few minor changes. If you have Iceweasel 3.0.3 installed but want to test this new beta without changing anything to your system, just follow the steps below.

Download Firefox 3.1 Beta 1
Get the Firefox .tar.bz2 archive from here, then uncompress it using:

tar -xjf firefox-3.1b1.tar.bz2

Next, move the firefox directory wherever you want it, for example in your home directory, or in ~/apps etc.

Run it using a new profile
Firefox uses the default profile whenever you run it without specifying another profile using a parameter. To run it using a different profile than the default one, use this command after making sure your current working directory is firefox:

./firefox --no-remote -P new_profile

As you can see, we used the name new_profile for our profile. The --no-remote parameter will not connect Firefox to a running instance, so you will be able to run both your current version and 3.1 Beta 1.


Select new_profile (or whatever the name of your profile is) and click on Start Firefox:


You will be prompted to accept the EULA, then Firefox 3.1 Beta 1 will start and you will be able to test it.


A small window should appear prompting you to choose the profile to use. Click on the Create Profile... button, then follow the instructions as in the screenshots below. You will notice you won't even have to close Iceweasel 3.0.3 if you have it running.


Currently there are no available themes for Firefox 3.1, so you'll have to use the default until they are updated.

October 25, 2008

Wine 1.1.7 Review - First Steps of Direct3D 10 Implementation

I think Wine is one of the most promising and useful applications, especially for those who need to run Windows programs in a Linux environment. A new development release is put up every two weeks or so, and improvements are visible from each version to another.

Wine is the project which makes possible to run games like World of WarCraft, Counter-Strike, Half-Life 2, WarCraft III and so on. And Wine is also the project which makes possible for web developers to test how their web page is viewed under Internet Explorer. Not to mention hundreds of other applications which work very well or well enough with it.

Ever since the first release tagged as 'stable' was put out for the public after 15 years of development, the Wine project continued development and now the latest version is 1.1.7, which brings numerous improvements and additions.

According to the official announcement, one of the highlights for this release is that the first steps were taken to implement the Direct3D technology, which is part of the DirectX API from Microsoft. The open and widespread competitor for Direct3D is OpenGL, the Open Graphics Library.

It's well-known that Wine works awesome with games like WoW, Counter-Strike or Half-Life 2.

A while ago I ran and installed the new Google Chrome web browser through Wine, since a Linux port is not available yet, and the result was very satisfying: with the exception of a little interface slowness, it behaved very well.


For this release, I installed Google Chrome following the tutorial I wrote for 1.1.6. I had to run it as:

wine ~/.wine/drive_c/windows/profiles/USERNAME/Local\ Settings/Application\ Data/Google/Chrome/Application/chrome.exe --new-http --in-process-plugins

And replaced USERNAME with my username. Chrome displayed all the web pages I tried, including this blog, Digg.com, YouTube.com (with the Flash plugin too) and the WineHQ homepage, but scrolling a page is extremely slow and choppy until the web page is completely loaded. I never tested Google Chrome on Windows so I can't compare exactly the behaviour.


I also installed Adobe Flash Player using the browser instead of winetricks. Below are some screenshots running Chrome through Wine. As you can see, Flash is enabled:


Wine provides an application database on their homepage, which classifies applications depending on how well they run and perform: platinum, gold, silver. The nice thing is that each application has detailed information on how to set it up in order to work best, in what conditions it was tested and it also includes user comments. Usually, if a game or application is known to work through Wine but you couldn't set it up, have a look at the comments posted and a solution will surely be provided.

As I already mentioned, one of the most popular games which worked perfectly for me in Wine is World of WarCraft:

World of WarCraft

I was glad to see the mIRC scripts editor does not crash the application anymore, but instead I couldn't make it connect to another network but the default QuakeNet, so you will have to use the /server command. Otherwise, mIRC 6.35 works pretty well, and if you really really need it and can't re-write your scripts for a native Linux client you can use it through Wine. Still, I suggest using a native IRC client like XChat, Konversation or Irssi.


I also tried the last version of Winamp, 5.541, and I installed the Lite version. It works very well, although I did not test it for long. It plays music.


It's true, I don't think Linux needs to run a player like Winamp, when we have powerful and full-featured, native and open-source audio players like Amarok, Banshee, Rhythmbox, Songbird or XMMS. But maybe someone still finds a use for it, or it can help those who just switched from Windows and can't get used to another player.


Also, here is a top 25 applications/games which run in Wine, by votes.

Overall, the Wine project does what it has always done, bringing Windows games and applications to Linux. It's great to see games like WoW, HL2, CoD4, StarCraft, WarCraft III running very well.

October 12, 2008

Sometimes It Won't Work

A few annoyances, and I really hope this will be fun. I wrote it last night. Some things which don't work as they are supposed to, or some things which may be annoying - Linux forever, I love it, but sometimes it's not so funny fun as it should be.

Things which you mustn't do
- don't open 3 tabs in firefox in less than 5 seconds
- don't install linux on a system with one sata and one ide drive (adding a hard disk will confuse it even more)
- don't try to install linux on a computer without an internet connection - don't believe me? try installing sarge on a pc without internet, after selecting don't configure network at this time
- movie subtitles must be green, pink, red or yellow, no matter if it's a DVD or a SRT/SUB subtitle
- don't run a task which would take 30 minutes then leave. an error will occure
(if an error doesn't occure, a warning will be issued)
(if the error doesn't occure, are you sure you didn't do something wrong?)
- no, they don't have games on linux
- ...and quake too
- complain if it's closed-source, don't use it if they changed the license to GPL
- a font size of 7 looks normal, but 8 is bold and big. for 6 you will need KMag.
-
open-source projects, use Flash for the homepage; also make sure Firefox uses 100% CPU when browsing your homepages
- ask questions twice, notify a user of some update and newly installed script twice

Particular Private License #0:
I don't want to show you my code!
Particular Private License #1:
It's mine!
Particular Private License #2:
I really hate my neighbour :-)
Particular Private License #3:
Where is my money?

- don't complain, for you did something wrong like not editing some config file of an app which had a bug filed since 2005 and which can't be fixed unless somebody rewrites a whole library which was licensed under a proprietary license and now is free but still wait for a new version to appear and when it's out test it for two more years and you'll find the bug fixed but guess what? the feature is not there anymore

CLI applications are as follows:
- the ones from GNU, which are standard
- the ones from other projects, some of which are great
- the ones which give an error when ran as 'app --version' or 'app --help'
(they all are included in heavy distros)

Who or what is evil?
- Microsoft is evil
- Apple is evil
- Since Canonical offers Linux support for money, I'm sure they are evil too
- Mono, Java too

Bug fixing squad:
If you decide to fix bugs, first put them there so you know what to fix
Choose carefully the bugs you will fix, for some of them you won't know the fix

Start a new distribution, the rules:
- use packages from an older distribution
- do not ever fix bugs
- choose a desktop environment, then start 3 more distros using other desktop environments
- add great features to applications, which will act as follows:
1. use an infinite loop no matter if the user clicks yes/no
2. make it impossible to close the application
3. teach the user how to use ps
- high hopes: 10 goals in a short time, come up with 1 which is terribly done anyway
- yeah, a new wallpaper and an iso image makes a new distro - burn fire burn, evil inside etc

- handle with care - that is: don't start an application unless you know it previously worked before
- an error means you did it wrong
(no, it's not a bug, you just have to configure it 2 hours in order to make it work)

September 12, 2008

How-To: Compile and Install xine-lib 1.1.15 in Debian Lenny and Ubuntu 8.04

Xine is an engine which allows to play audio CDs, DVDs, VCDs, various audio and video formats like AVI, WMV, MOV to list a few. The last version of xine-lib is 1.1.15, released on August 14, 2008.

Installation in Debian Lenny
To compile from source and install xine-lib 1.1.15 in Debian Lenny you'll have to follow the steps below.

1. Enable the sources repositories
Make sure you have a line like the following in your /etc/apt/sources.list file:

deb-src http://ftp.ro.debian.org/debian/ lenny main contrib non-free

Then update the packages list as root:

apt-get update

2. Install the dependencies
As root, type:

apt-get build-dep libxine1

This will install the development packages and the tools needed to compile Xine.

3. Download the source, compile and install
Download the last xine-lib version from here, uncompress it and compile as usual:

./configure
make
make install

Last one as root.

xine-lib should be now installed in /usr/local/lib/.

Installation in Ubuntu 8.04
Ubuntu Hardy comes with libxine 1.1.11, so if you want to update to the latest version, you need to follow the steps above, with the exception of preceding the commands which need root privileges with sudo. For example:

sudo apt-get build-dep libxine1

./configure
make
sudo make install

With your user's password.

Video players using Xine
I can recommend Kaffeine and Xine-UI, both these players use the Xine engine.

Kaffeine 0.8.6

Updated: Sep 12, 2008