alias issue
how can i use 2 words for alias
example alias kuku kuak 'bla bla bla' |
DoME69,
I don't think that's possible, you may have to make do with an under-score -- kuku_kuak |
In bash, you can't.
|
Quote:
|
I don't think the shell is relevant.
*nix works with: <cmd> <args> So, kuak is always going to be an argument. You'll have to frig it, save the following as kuku: Code:
#!/bin/bash Code:
$ chmod +x kuku Code:
kuku kuak |
Quote:
Suppose I type "pwd dog". since pwd does not take any arguments, "dog" is simply ignored. If I then enter "dog pwd", it tells me that "dog" is not a valid command. I tried to create a two-word alias: Code:
[mherring@Ath ~]$ alias one two="ls -l" In the second case, alias does the right thing and refuses to create the two-word alias. So---try this on cshell and see if it's any different. |
What the second word is intended to be? Please, can you provide a practical example of what do you want to achieve? In other words, why two separate words are a requirement and prevent the usage of the underscore instead of the blank space? If the second word is intended as an argument, I've already shown the usage of alias arguments in C-shell in your previous thread.
|
|
|
All times are GMT -5. The time now is 05:09 AM. |