ratpoison-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [RP] Re: poundbang


From: twb
Subject: Re: [RP] Re: poundbang
Date: Fri Mar 5 01:26:01 2004

For the record, I don't care about this feature.  In fact, I have never
used my script on <wiki>/ratpoison-script.

I was going to point out that most of the arguments from Ryan's epistle
are still valid for <wiki>/ratpoison-script, then I thought of a way to
implement what Ryan wants and I want.

We break everybody's scripts.

    if next argument doesn't begin with a '-', join in on to the last
    argument (with a " " between).

e.g.

    ratpoison -c first cmd                 -c another cmd
    ratpoison -c "cmd with leading -minus" -c another cmd
    ratpoison -c cmd with "leading -minus" -c another cmd
    ratpoison -c "this still works"        -c another\ cmd

Then you just write 

    #!/path/ratpoison -c source

rationale:

    * Saves an escapement whenever the colon-cmd takes an arg, and most
      commands outside the keybinder need an arg (IMO).

    * I almost never run RP with multiple '-c's, so escaping is
      annoying.

I haven't used getopt for C before, so I'll send this then try to write
the patch.

-trent





reply via email to

[Prev in Thread] Current Thread [Next in Thread]