|
Jah Wanderer
Joined: 11 Oct 2000 Posts: 52 Location: Sweden
|
Posted: Tue Jul 29, 2003 1:18 am
Erm, crash boom bang.. |
alias : bash
#if (%1 = %null) {bash @target} {
bash %1
var target %1
}
That crash zmud for me. Strangeness. |
|
|
|
Jah Wanderer
Joined: 11 Oct 2000 Posts: 52 Location: Sweden
|
Posted: Tue Jul 29, 2003 1:21 am |
Duh, sometimes im to stupid.. forgot about ~
Should still mention infinite loop i think... hmm.. |
|
|
|
LightBulb MASTER
Joined: 28 Nov 2000 Posts: 4817 Location: USA
|
Posted: Tue Jul 29, 2003 2:54 am |
What's strange about it. You named your alias "bash", then had both sides of the #IF use "bash", which means it loops back to the alias and checks #IF again, get another "bash", loops back to the alias again...Worse than that, since you put the #VAR command after the "bash", unless @target is empty you'll be stacking up another #VAR command every time through, all waiting for the infinite "bash"ing to finish...
The ~ is essential if you intend to use the name of an existing command as your alias name, while simultaneously using that command within the alias. I'm assuming you have "var" instead of "#var" because of a typo.
alias : bash
#if (%1 = %null) {~bash @target} {
~bash %1
#var target %1
} |
|
|
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|