Thursday, July 17, 2014

#! CrunchBang Post Installation Tips

Since I'm bored with a long time usage of Manjaro Linux( nearly 8 months) and minor problems like Huawei USB modem detection and update issues trigger me to look for another Linux Distro. I started my exploration with Distrowatch.com and reading couple of other distro reviews from various other blogs and finally came to conclusion to install a new lightweight Linux distribution called #! Crunchbang.
Crunchbang Info(Source:Distrowatch.com)
I'd started with downloading the latest 64-bit version of Crunchbang Linux 11 "Waldorf" and used UNetbootin to create a live USB to install it in my machine.

1. #! Post Installation Script

The nifty feature of Crunchbang I noticed on the startup is the Post installation script. The Post installation script provides the user with options to perform update, install drivers for printer support, Java etc.,
a) Post Installation Script
Suppose if you have quit/skipped the Post Installation script, use 'cb-welcome' command to start the script again. If you have some kind of proxy to be configured use the Post-install script: Proxy issue to resolve.

2. Install Essential Applications

Waldorf offers links to install Chromium, Google-Chrome, IceWeasel, Opera, Dropbox, VLC etc., install your favorite applications.
If you want to remove iceweasel and install Mozilla FireFox follow the below steps:

$sudo apt-get remove iceweasel
$sudo echo -e "\ndeb http://downloads.sourceforge.net/project/ubuntuzilla/mozilla/apt all main" | sudo tee -a /etc/apt/sources.list > /dev/null
$sudo apt-key adv --recv-keys --keyserver keyserver.ubuntu.com C1289A29
$sudo apt-get update
$sudo apt-get install firefox-mozilla-build


Some other packages you may wish to install  are xchm-CHM reader, libreoffice-pdfimport - PDF support for Libreoffice, pcmanFM - Tabbed File manager an alternative to Thunar (Default File Manager), banshee (Music Player), xpad (Sticky Notes).


$sudo apt-get install xchm libreoffice-pdfimport pcmanfm banshee xpad

Use link to add applications to startup.

3. Setting Custom Time Format  

Customize the TimeFormat displayed in the status bar, initially the clock displays only hour and minutes. To customize it 
  • Goto Openbox > Preferences > tint2 Panel Config > Edit config file.
  • Find entry for "# Clock" and change the  "time1_format" to "#time1_format".(You are just commenting the old entry, in-case if you want to rollback uncomment it later).
  • Add the new "time1_format = %a %b %d, %I:%M %p" to display time as "Wed Jul 09,12:03 AM". 

    'man date' is your companion utility to find the appropriate flags suited for your needs.


4. Customize Themes and Workspaces

Goto Settings > Openbox > GUI Config tool > Desktops > Number of Desktops 4

b) Openbox Configuration Manager
Use the Openbox Configuration manager to configure other settings such as Theme, Appearance and behavior etc., 

Use "Settings->User Interface Settings" to change the Icon theme, Cursor theme etc., 

5. Set Custom Keyboard Shortcuts for Workspaces

By default Crunchbang provides user with "Ctrl+Alt+Left/Right Arrow" shortcut to navigate between various workspaces. To set a custom keyboard shortcut, You can directly go and edit the Settings > Openbox > Edit rc.xml file and add/change an entry like this below, I'm using Alt+{1,2,3,4} for workspace switch and Win+{1,2,3,4} to move a particular window to desired workspace.



 <keybind key="A-1">
      <action name="GoToDesktop">
        <to>1</to>
      </action>
    </keybind>
    <keybind key="A-2">
      <action name="GoToDesktop">
        <to>2</to>
      </action>
    </keybind>
    <keybind key="A-3">
      <action name="GoToDesktop">
        <to>3</to>
      </action>
    </keybind>
    <!-- keybind key="W-F4" -->
    <keybind key="A-4">
      <action name="GoToDesktop">
        <to>4</to>
      </action>
    </keybind>
    
    #Send To Desktop
       <keybind key="W-1">
      <action name="SendToDesktop">
        <to>1</to>
        <wrap>no</wrap>
      </action>
    </keybind>
    <keybind key="W-2">
      <action name="SendToDesktop">
        <to>2</to>
        <wrap>no</wrap>
      </action>
    </keybind>
    <keybind key="W-3">
      <action name="SendToDesktop">
        <to>3</to>
        <wrap>no</wrap>
      </action>
    </keybind>
    <keybind key="W-4">
      <action name="SendToDesktop">
        <to>4</to>
        <wrap>no</wrap>
      </action>
    </keybind>
Take a look at #! Desktop Edit Keyboard Shortcuts article for detailed understanding.

6. Set Custom wallpaper 

  • To set custom wallpaper, move the image you want to set as wallpaper to /home/{username}/images/wallpapers.
  • Right-click on your Desktop > Settings > Choose Wallpaper.
  • The custom wallpaper will be visible inside Nitrogen, select  the image and click Apply.

c) Nitrogen(Wallpaper manager)

For Android Developers Only

1. "Error executing aapt: Cannot run program "**/bin/sdk/build-tools/19.0.1/aapt": java.io.IOException: error=2"
blizzard@crunchbang:~$ sudo apt-get install ia32-libs [sudo] password for blizzard: Reading package lists... Done Building dependency tree Reading state information... Done Some packages could not be installed. This may mean that you have requested an impossible situation or if you are using the unstable distribution that some required packages have not yet been created or been moved out of Incoming. The following information may help to resolve the situation: The following packages have unmet dependencies: ia32-libs : Depends: ia32-libs-i386 but it is not installable

Solution:
 blizzard@crunchbang:~$ sudo dpkg --add-architecture i386
 blizzard@crunchbang:~$ sudo apt-get update
 blizzard@crunchbang:~$ sudo apt-get install ia32-libs

Other useful Sites 

  1. Crunchbang Forums
  2. IRC Channel - #crunchbang on freenode
  3. Crunchbang Tips,Tricks & Scripts