DonationCoder.com Software > Find And Run Robot
how do i.. with an alias?
lanux128:
this should be easy for regex pros.. i have this alias here to eject removable drives and i want the semi-colon to be added automatically after the drive letter. e.g. if i type "eject e" --> "eject e:"; "eject e f" --> "eject e: f:" (minus quotes).. can someone give me a hand.. :)
RegEx Pattern: ^eject (.*)
EjectCD $$1 | "C:\Program Files\SysTools\EJECT.EXE" $$1
--- End quote ---
another type of alias that i'm looking for is to link a path with the keyword, say "games" then whenever i type "games <abc>", Farr will be searching <abc> in the path only.. something like the "cpanel" that is available right now..
jgpaiva:
For the first one...
--- ---RegEx Pattern: ^eject (.*):?
EjectCD $$1 | "C:\Program Files\SysTools\EJECT.EXE" $$1:(notice the ':' after '$$1')
As for the second part, see 'Keyword Modifiers' in the advanced section of the help file. ;)
lanux128:
jgpaiva, sorry it doesn't seem to work.. see the screenshots..
Defining the alias
and the result..
as for the 2nd request, thanks for pointing in the correct direction.. :Thmbsup:
mouser:
actually jgpaiva's solution is basically correct -- you just need to update your alias result to SHOW YOU the : as well:
i.e. change
ejectCD $$1 | "C:\Program Files\SysTools\EJECT.EXE" $$1:
to
ejectCD $$1: | "C:\Program Files\SysTools\EJECT.EXE" $$1:
keep in mind this will not work on your example of "eject e f" since it will only add one : at the end of the f
but you could solve this by making another ejectcd alias which matches 2 drive letters and adds a : to both, but that would require a separate regular expression alias.
in this case, a better thing might be to launch a kind of batch file or script to invoke and do the replacement after the launch by this script. i urge people to use this kind of approach.
lanux128:
keep in mind this will not work on your example of "eject e f" since it will only add one : at the end of the f
but you could solve this by making another ejectcd alias which matches 2 drive letters and adds a : to both, but that would require a separate regular expression alias.-mouser (April 27, 2007, 05:34 AM)
--- End quote ---
thanks for the explanation, mouser.. so, how do i go about the alias that matches two drive letters?
Navigation
[0] Message Index
[#] Next page
Go to full version