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

Re: Multiple commands in binding



Hi,

On Sat, Sep 22, 2012 at 01:54:42PM +0200, Thorsten Wißmann wrote:
> On Thu, Sep 20, 2012 at 01:54:51PM +0200, Thorsten Wißmann wrote:
> > === Specify a command seperator dynamically ===
> > Similar to sed's s/search/replace/ where once can freely choose the
> > separator, we could add a chaimcmd that takes a seperator word first
> > followed by the two commands:
> > 
> >     chaincmd , cmd1 arg1a arg1b , cmd2 arg2a     # would be equal to
> >     chaincmd .-. cmd1 arg1a arg1b .-. cmd2 arg2a # or
> >     chaincmd ab cmd1 arg1a arg1b ab cmd2 arg2a
> > 
> Yesterday implemented this as the commands "chain", "and" and "or". You
> can find them temporarily in the chain branch[1].
> 
> The current usage is:
> 
>     [chain|or|and] SEP COMMANDS...
> 
> They aren't merged to master yet, because they're maybe not final,
> there is no documentation yet and later commands still overwrite the
> output of previous commands in the chain.

I fixed this bug (including some refactoring...), added the
documentation for it including an example keychain.sh script. Currently
it's only in the chain branch[1] and it will be merged to master in the
next days.

I would be happy about any feedback here or in th IRC[2].

Regards,

Thorsten

> [1] git clone git://git.cs.fau.de/hlwm -b chain herbstluftwm
> or: git fetch && git checkout origin/chain in an existing repository
> or: http://git.cs.fau.de/?p=hlwm;a=shortlog;h=refs/heads/chain
[2] #herbstluftwm on irc.freenode.net