Showing posts with label linux. Show all posts
Showing posts with label linux. Show all posts

Tuesday, April 3, 2012

set vlc as default media application in Ubuntu, Fedora (and probably other Linux distros) from command line

Given that Totem is the default media player in Ubuntu, one can set VLC as default media player by replacing every instance of "totem.desktop" in the file /usr/share/applications/defaults.list by "vlc.desktop" as follows.
1. sudo cp /usr/share/applications/defaults.list /usr/share/applications/defaults.list.backup
2. sed 's/totem.desktop/vlc.desktop/g' /usr/share/applications/defaults.list > tempfile
3. sudo mv tempfile /usr/share/applications/defaults.list 


References: VLC wiki page

Saturday, November 26, 2011

efficient/productive computer user, keyboard shortcuts, tip #1

Do Alt+Tab to switch between program windows quickly.

Wednesday, March 23, 2011

Netflix in Linux?

Netflix is based on silverlight (codec?) thing which is designed for windows. Well, if they don't bother to support linux, then I will not bother to use netflix. Here is a good alternative to netflix: the Google Chrome app Cracle.

It is easy to use and install. Do the following:

  1. Install Google Chrome: http://www.google.com/chrome/index.html
  2. Install the Chrome App Crackle: https://chrome.google.com/webstore/detail/ibfamoapbmmmlknoopmmfofgladlinic
  3. If you connect anywhere outside of USA, movie & TV show selection is not great. So consider getting an highspeed USA proxy. Foxyproxy is the best one for the job I think: http://getfoxyproxy.org/
  4. After getting it, set it up withing the Google Chrome. Do: Google Chrome setup -> under the hood
  5. Enjoy!

Thursday, December 2, 2010

Ubuntu 10.10 on Sony Vaio Netbook (VPCM111AX)

I just recently purchased a Sony Vaio netbook (VPCM111AX). Initially, I was hesitant to buy a netbook since I wasn't sure if its computational power would be sufficient for me. It turns out it is not really true that you cannot do more than a few things at a time. I so far haven't experienced any slowness due to opening many applications. To be clear, I am not an average Joe laptop user, thus the apps that I use go way beyond internet browsers.

I think if one doesn't do hard-core gaming or hard-core numerical simulations, netbook is a perfect match for your daily computing needs. Also I find the screen size is really perfect for me. After using this netbook, I consider any laptop bigger than 12" screen as an unmobile piece of product.

Netbook thing is really practical, I don't really think twice if my backpack will be heavy etc. It is substantially lighter than my previous 15" laptop which gave me serious shoulder problems when I go to conferences etc.

Speaking of Ubuntu, I have the 10.10 Maverick Meerkat version installed on my netbook. Everything works out of the box: keyboard, function keys, power management, wireless, mic (int & ext), bluetooth, graphics (vga and associated function key works out of the box), and suspend mode. Though I haven't tested the memory card reader yet. Additionally, battery lasts 4.5 hours with wireless is on half the time.

One reason why I post this is that this netbook is not listed in the ubuntu compatible netbook list. So I took some chances however I knew before the purchasing the netbook that linux works nicely on Sony laptops. I hope some others who want to purchase this netbook and use withubuntu will find this post useful

Saturday, November 13, 2010

Save more than 10% battery life with adblock

As I mentioned before, I bought a netbook recently. Naturally I was experimenting with ways of getting the most out of the built-in battery. I just realized that blocking flash based moving ads on websites can enable you to save more than 10% battery life.

Here is the main result.
the power consumption of the netbook is:
  1. 11.2 Watts before blocking, and
  2. 9.5 Watts after.
So, if you are on the go and doing web browsing, and would like save some battery power, block ads.

Notes:
1. link to adblock: http://addons.mozilla.org/en-US/firefox/addon/1865/
2. in order to see power stats, use the linux command "gnome-power-statistics".

Friday, November 12, 2010

how to switch/reassign keyboard keys in linux / ubuntu / fedora

I recently bought a netbook which came with a good size keyboard. However, due to the space constraint, the netbook producer, turns out, combined the Page-up and Home, and Page-Down and End keys. Well, as a touch typist and a programmer, I often use Home and End keys, and it is certainly a pain to be able to access them only via a Function key like Fn+Page-up=Home. So I did some googling, and here is the result.

1. Install Xmodmap
in ubuntu do: sudo apt-get install xmodmap
in fedora do: sudo yum install xmodmap

2. get the "keysym" name of the keys using xev
keysym of "home" key is "Home"
xev
press the Home key
KeyRelease event, serial 33, synthetic NO, window 0x1800001,
root 0xaa, subw 0x0, time 3028114, (288,433), root:(289,515),
state 0x0, keycode 110 (keysym 0xff50, Home), same_screen YES,
XLookupString gives 0 bytes:
XFilterEvent returns: False


via xev: keysym of "Page up" key is "Prior"
xev
press the Page up key
KeyRelease event, serial 33, synthetic NO, window 0x1800001,
root 0xaa, subw 0x0, time 2825051, (322,253), root:(323,335),
state 0x0, keycode 112 (keysym 0xff55, Prior), same_screen YES,
XLookupString gives 0 bytes:
XFilterEvent returns: False


4. switch keys by doing two assignments
xmodmap -e "keysym Home = Prior" -e "keysym Prior = Home"