.bashrc file

My customized .bashrc file follows:

alias l='ls -lh --color'
alias la='ls -lah --color'
alias download='curl -c - -O'
#PS1='\[\e[0;32m\]\u\[\e[m\] \[\e[1;34m\]\w\[\e[m\] \[\e[1;32m\]\$\[\e[m\] \[\e[1;37m\]'

#Blue prompt
PS1='\[\e[1;34m\][\u@\h \W]\$\[\e[0m\]'

#Green prompt
#PS1='\[\e[1;32m\][\u@\h \W]\$\[\e[0m\] '
PATH=$PATH:~/bash-advanced-scripts:~/toolchains/linux-x86/bin:/home/droidzone/android/adb

#Path to SDK
PATH=$PATH:~/android/envt/SoftwareDevelopmentKit/sdk/tools:~/android/envt/SoftwareDevelopmentKit/sdk/platform-tools

#Path to javac and java
PATH=$PATH:~/android/java/jdk1.7.0_09/bin

#apktool
PATH=$PATH:~/android/Apktool

#Java envt
JAVA_HOME=~/android/java/jdk1.7.0_09
export GREP_OPTIONS="--color -i -n"

d=.dircolors
test -r $d && eval "$(dircolors $d)"

My root bashrc /root/.bashrc is:

alias l='ls -l --color'                                                                                                                
alias download='curl -c - -O'                                                                                                          
#PS1='\[\e[0;32m\]\u\[\e[m\] \[\e[1;34m\]\w\[\e[m\] \[\e[1;32m\]\$\[\e[m\] \[\e[1;37m\]'                                               
PS1='\[\e[1;31m\][\u@\h \W]\$\[\e[0m\]'                                                                                                
#'\[\e[1;32m\][\u@\h \W]\$\[\e[0m\] '                                                                                                  
PATH=$PATH:~/bash-advanced-scripts:~/toolchains/linux-x86/bin:/home/droidzone/android/adb                                              

#Path to SDK                                                                                                                           
PATH=$PATH:~/android/envt/SoftwareDevelopmentKit/sdk/tools:~/android/envt/SoftwareDevelopmentKit/sdk/platform-tools                    

#Path to javac and java                                                                                                                
PATH=$PATH:~/android/java/jdk1.7.0_09/bin                                                                                              

#apktool                                                                                                                               
PATH=$PATH:~/android/Apktool                                                                                                           

#Java envt                                                                                                                             
JAVA_HOME=~/android/java/jdk1.7.0_09

 


You are reading this post on Joel G Mathew’s tech blog. Joel's personal blog is the Eyrie, hosted here.
A better shell existence – Changing ls colors

A better shell existence – Changing ls colors

I wasnt satisfied with the default blue color shades for ls, and was exploring ways to change them. I happened to come across the dircolor resources.

To get the default ouput, do this:

dircolors -p > ~/.dircolorsrc

Once this is done, you get a modifiable file with colors for everything. Edit it to your whim.

Then to make sure that the codes get loaded, add the following to your ~/.bashrc:

d=.dircolors
test -r $d && eval "$(dircolors $d)"

More info can be found by:

info coreutils 'dircolors invocation'

coloredls

 

I finally decided on the following colors:

color1

I am attaching my .dircolor file.

Download “Roms” – Downloaded 0 times –

I chose

Dir-Orange Underline

Symlinks-Cyan

Pictures-Pink

Executables-Blue

Color chart:

# Below are the color init strings for the basic file types. A color init
# string consists of one or more of the following numeric codes:
# Attribute codes:
# 00=none 01=bold 04=underscore 05=blink 07=reverse 08=concealed
# Text color codes:
# 30=black 31=red 32=green 33=yellow 34=blue 35=magenta 36=cyan 37-39=white
# 
# Background color codes:
# 40=black 41=red 42=green 43=yellow 44=blue 45=magenta 46=cyan 47=white

 


You are reading this post on Joel G Mathew’s tech blog. Joel's personal blog is the Eyrie, hosted here.