DonationCoder.com forum
 
Read-only archive. This is a static copy of the DonationCoder.com forum. Reading and searching work as before; logging in, posting and private messages do not.
Archive of 2026-10-21 · About this archive · Main site

Author Topic: I need simple alias help  (Read 9,134 times)

kartal

  • Supporting Member
  • Joined in 2008
  • **
  • Posts: 1,529
I need simple alias help
« on: April 04, 2008, 03:43 AM »
I am trying to convert my launchy commands to FARR. I tried to read the doc and look at the forum but yet I cannot achieve what I need.

I have a command line timer that I can pass a timecode like 00:15:00 that is use to countdown. I am using this with launchy however I cannot do it withFARR

here is what I have

alias name = countdown
Results = countdown $$1 | E:\INCELENECEK_YAZILIMLAR\yardimci yazilimlar\1Time\1Time.exe /t"$$1" /n  (t and n are 1time.exe arguments)

Farr finds the alias but when I put my time code in FARR line, program does not launch at all. It looks like I cannot pass the arguments to 1time.exe
« Last Edit: April 04, 2008, 03:45 AM by kartal »

lanux128

  • Global Moderator
  • Joined in 2005
  • *****
  • Posts: 6,277
    • Coding Snacks
    • Volunteers/Staff
    • Gathering Badge
    • Participated in NANY Challenge Once
    • Linux User
Re: I need simple alias help
« Reply #1 on: April 04, 2008, 03:53 AM »
enclose the path in quotes. try it like this:
Results = countdown $$1 | "E:\INCELENECEK_YAZILIMLAR\yardimci yazilimlar\1Time\1Time.exe" /t"$$1" /n

or

Results = countdown $$1 | "E:\INCELENECEK_YAZILIMLAR\yardimci yazilimlar\1Time\1Time.exe" /t$$1 /n

kartal

  • Supporting Member
  • Joined in 2008
  • **
  • Posts: 1,529
Re: I need simple alias help
« Reply #2 on: April 04, 2008, 04:01 AM »
Lanux that does not work either.

In Farr input line if I type " countdown 00:15:00 " does not even start the program. But in  launchy same arguments would start timer that will countdown from 15 min.

here is the screenshot

http://stashbox.org/98781/1083323231-Edit-Group-Alias.jpg
« Last Edit: April 04, 2008, 04:04 AM by kartal »

kartal

  • Supporting Member
  • Joined in 2008
  • **
  • Posts: 1,529
Re: I need simple alias help
« Reply #3 on: April 04, 2008, 05:41 AM »
It says that "regular expression pattern" is optional but, it seems like nothing works without them ?

lanux128

  • Global Moderator
  • Joined in 2005
  • *****
  • Posts: 6,277
    • Coding Snacks
    • Volunteers/Staff
    • Gathering Badge
    • Participated in NANY Challenge Once
    • Linux User
Re: I need simple alias help
« Reply #4 on: April 04, 2008, 06:18 AM »
It says that "regular expression pattern" is optional but, it seems like nothing works without them ?

i'm not sure about that but just in case put these in the "reg-ex pattern" box: ^countdown (.*)

kartal

  • Supporting Member
  • Joined in 2008
  • **
  • Posts: 1,529
Re: I need simple alias help
« Reply #5 on: April 04, 2008, 06:19 AM »
Yes I figured that. But it says optional with capitals. It does not make sense really. Once that box is filled everything works fine

tinjaw

  • I'm so glad breakbeat techno isn't an illegal drug
  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 1,927
    • Participated in NANY Challenge Twice
    • Coding Snacks
    • Military Service Badge - US Army
    • Linux User
Re: I need simple alias help
« Reply #6 on: April 04, 2008, 10:23 AM »
I'm guessing here but...

I think you should be using

countdown $$1 | E:\INCELENECEK_YAZILIMLAR\yardimci yazilimlar\1Time\1Time.exe /t$$1 /n

and I would suggest trying

countdown $$1 | E:\INCELENECEK_YAZILIMLAR\yardimci yazilimlar\1Time\1Time.exe /t$$1

and see if that works. Mouser's code may be interpreting the /n as a newline.

mouser

  • First Author
  • Administrator
  • Joined in 2005
  • *****
  • Posts: 40,931
    • Gathering Badge
    • Plugin Coding Medal
    • Participated in NANY Challenge Seventeen Times
    • Cody Award
    • Coding Snacks
    • Volunteers/Staff
Re: I need simple alias help
« Reply #7 on: April 04, 2008, 10:28 AM »
regular expression is optional in the sense that if you make an alias which doesnt take any expressions, you don't need it.
as soon as you want to have it match what you type with some parameters then you need to use a regular expression.

you might think that FARR could simply be smart enough to know that when you type "countdown BLAH" that the "BLAH" part should be treated like a parameter -- but FARR can't tell if the BLAH is supposed to be a parameter or more words to narrow down the search more, which is what it is assuming.

one thing we could add which addresses someone else's request for a way to easily pass commandline arguments is to add a special character meaning everything after this should be considered an argument, like if you type: "notepad & test.text"
then FARR would know that everything after the & should not be used for searching but should be passed as an argument to the triggered program.

kartal

  • Supporting Member
  • Joined in 2008
  • **
  • Posts: 1,529
Re: I need simple alias help
« Reply #8 on: April 04, 2008, 02:56 PM »
Mouser thanks for explanation. Since I use Launchy a lot I can tell you that "tab" works as command line starter in Launchy. So if you are searcjing for 2 words you would not use tab to start your second word, most likely you would type your 1st word then space and type your second word.

Your suggestion sounds fine as well. At the end of the day I personally would like FARR to pass arguments to any executable even if they are not defined as alias

d4ni

  • Supporting Member
  • Joined in 2008
  • **
  • Posts: 129
Re: I need simple alias help
« Reply #9 on: April 05, 2008, 06:52 PM »
one thing we could add which addresses someone else's request for a way to easily pass commandline arguments is to add a special character meaning everything after this should be considered an argument, like if you type: "notepad & test.text"
then FARR would know that everything after the & should not be used for searching but should be passed as an argument to the triggered program.

That would be nice.

Original address: https://www.donationcoder.com/forum/index.php?topic=12932.0