Aliases in Ubuntu

Fred A. Miller fmiller at lightlink.com
Tue Mar 23 23:43:21 UTC 2010


On 03/23/2010 05:33 PM, zongo saiba wrote:
> Hi,
>
> Two questions about creating aliases in Ubuntu
> 1) is it best practice to create an alias in ~/.bashrc or is it
> preferable to create the alias in ".bash_aliases" ? If so, how do you
> create an alias in ".bash_aliases" ? I can vim into ~/.bashrc but can't
> seem to be able to vim into ~/.bash_aliases. I can cd into that
> directory but it is empty since I have created my aliases into ~/.basrc.
> 2) Is it best to use single or double quote when creating aliases.
> ex: would alias dirA="echo Working directory is $PWD" be similar to
> alias dirB='echo Working directory is $PWD'
>    

Single quote and alias's work fine in .bashrc, which you can create in
any editor like nano.

Fred

-- 
A REVOLUTIONARY IDEA! 'Time to put Nana Pelosi in a home!'





More information about the ubuntu-users mailing list