Results 1 to 4 of 4
I was doing research and found out that alias can not be run from scripts. I want to know how would I go about allowing myself to run alias from ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 01-09-2010 #1
setting up alias
I was doing research and found out that alias can not be run from scripts. I want to know how would I go about allowing myself to run alias from scripts. For slax I was told to just append my .bash_rc or profile but I can not find it on it slax.
So any ideas for turning this on? Or alternatives to automating my alias commands?
- 01-12-2010 #2Just Joined!
- Join Date
- Jan 2010
- Posts
- 7
You can create one(.bashrc ) in your home directory.
code: touch ./bashrc
Then use a text editor to add your aliases.
What do you mean `run alias' from scripts anyway?
- 01-14-2010 #3
Well I wanted to just do this from a script.
alias rm="rm -iv"
alias mv="mv -iv"
alias ..="cd .."
alias .="pwd"
alias ls="ls -lF --group-directories-first --color=always"
alias la="ls -lAF --group-directories-first --color=always"
alias cls="clear"
alias cp="cp -iv"
alias rmdir="rmdir -iv"
- 01-17-2010 #4Just Joined!
- Join Date
- Jan 2010
- Posts
- 7
hi sonicx059. Well there are a few ways to do this. The most common would be to create a .bashrc in your home directory, edit it and paste your aliases. These will be read by bash every time u open a terminal. And yeah this is how i did it, unlike other versions of linux like ubuntu, slakware doesn't come with the default scripts in your home directory so whenever you need them you simply create and edit them.
Hope this helps.


Reply With Quote
