[ale] alias? or script?

Geoffrey esoteric at 3times25.net
Tue Jul 9 09:06:02 EDT 2002


You can do this in ksh with a function in your .env file as follows:

function findit {
	find / -name $1 -print
}

You then use it as follows:

findit foo

A couple of things here, first it works for only one argument, you 
assignment is to make if work for multiple arguments.

As someone else noted, locate would be faster, but then you could write 
a function that does the following:

locate foo || find foo

pseudo coded, but you get the point.



Stephen Turner wrote:
> hey say i wanted to do something like, 'find gzip /' i think thats the
> order, anyways just as an example :-p but i wanted to like change the
> word, find to search or what ever, some other word or letter combination
> :-p do i do that in alias? or a script? like can i just say " alias search
> = find" and everytime i type search it use the find command instead?
> 
> 
> __________________________________________________
> Do You Yahoo!?
> Sign up for SBC Yahoo! Dial - First Month Free
> http://sbc.yahoo.com
> 
> ---
> This message has been sent through the ALE general discussion list.
> See http://www.ale.org/mailing-lists.shtml for more info. Problems should be 
> sent to listmaster at ale dot org.
> 
> 
> 


-- 
Until later: Geoffrey		esoteric at 3times25.net

I didn't have to buy my radio from a specific company to listen
to FM, why doesn't that apply to the Internet (anymore...)?


---
This message has been sent through the ALE general discussion list.
See http://www.ale.org/mailing-lists.shtml for more info. Problems should be 
sent to listmaster at ale dot org.






More information about the Ale mailing list