Bug#525687: ferm: please add a hook which gets executed while configuration is read

2010-04-13 Thread Marc Haber
On Thu, Feb 18, 2010 at 10:04:50PM +0100, Max Kellermann wrote:
 On 2009/05/01 00:38, Marc Haber mh+debian-b...@zugschlus.de wrote:
  I do not understand. The hook would be executed while the shell script
  ie generated.
 
 No.  Hooks are executed when the rules are installed, not necessarily
 when ferm runs.  With --shell, ferm just prints the hook commands, to
 be executed later by the generated shell script.

I have understood now. This hook should be different. The use of the
hook I outlined in the first bug report is addressed by @include now
being able to execute commands, but this hook (@now) could probably be
used to generate debug output during ferm run, or for other advanced
things.

Please consider implementing it nevertheless.

Greetings
Marc

-- 
-
Marc Haber | I don't trust Computers. They | Mailadresse im Header
Mannheim, Germany  |  lose things.Winona Ryder | Fon: *49 621 72739834
Nordisch by Nature |  How to make an American Quilt | Fax: *49 3221 2323190



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#525687: ferm: please add a hook which gets executed while configuration is read

2010-02-18 Thread Max Kellermann
On 2009/05/01 00:38, Marc Haber mh+debian-b...@zugschlus.de wrote:
 I do not understand. The hook would be executed while the shell script
 ie generated.

No.  Hooks are executed when the rules are installed, not necessarily
when ferm runs.  With --shell, ferm just prints the hook commands, to
be executed later by the generated shell script.



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#525687: ferm: please add a hook which gets executed while configuration is read

2010-02-18 Thread Marc Haber
Hi,

On Thu, Feb 18, 2010 at 10:04:50PM +0100, Max Kellermann wrote:
 On 2009/05/01 00:38, Marc Haber mh+debian-b...@zugschlus.de wrote:
  I do not understand. The hook would be executed while the shell script
  ie generated.
 
 No.  Hooks are executed when the rules are installed, not necessarily
 when ferm runs.  With --shell, ferm just prints the hook commands, to
 be executed later by the generated shell script.

Can you give an example?

Greetings
Marc

-- 
-
Marc Haber | I don't trust Computers. They | Mailadresse im Header
Mannheim, Germany  |  lose things.Winona Ryder | Fon: *49 621 72739834
Nordisch by Nature |  How to make an American Quilt | Fax: *49 3221 2323190



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#525687: ferm: please add a hook which gets executed while configuration is read

2009-04-30 Thread Max Kellermann
On 2009/04/26 17:42, Marc Haber mh+debian-b...@zugschlus.de wrote:
 To _generate_ rules from outside ferm, it would be good to have a hook
 which is executed immediately when the line is read to allow things
 like:
 
 @hook now ferm-hook-create-rules;
 @include rules-created-by-ferm-hook;

The problem is that this is not transparent to --shell.  I will
implement #525678 instead.



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#525687: ferm: please add a hook which gets executed while configuration is read

2009-04-30 Thread Marc Haber
On Thu, Apr 30, 2009 at 04:55:21PM +0200, Max Kellermann wrote:
 On 2009/04/26 17:42, Marc Haber mh+debian-b...@zugschlus.de wrote:
  To _generate_ rules from outside ferm, it would be good to have a hook
  which is executed immediately when the line is read to allow things
  like:
  
  @hook now ferm-hook-create-rules;
  @include rules-created-by-ferm-hook;
 
 The problem is that this is not transparent to --shell.

I do not understand. The hook would be executed while the shell script
ie generated.

   I will implement #525678 instead.

That would be another possibility, yes.

Greetings
Marc

-- 
-
Marc Haber | I don't trust Computers. They | Mailadresse im Header
Mannheim, Germany  |  lose things.Winona Ryder | Fon: *49 621 72739834
Nordisch by Nature |  How to make an American Quilt | Fax: *49 3221 2323190



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#525687: ferm: please add a hook which gets executed while configuration is read

2009-04-26 Thread Marc Haber
Package: ferm
Version: 2.0.5-1
Severity: wishlist

Hi,

To _generate_ rules from outside ferm, it would be good to have a hook
which is executed immediately when the line is read to allow things
like:

@hook now ferm-hook-create-rules;
@include rules-created-by-ferm-hook;

I currently do this by inserting a dummy rule into a dummy chain:

chain dummy interface `ferm-hook-create-rules` NOP;
@include rules-created-by-ferm-hook;

while the scripts empty output prevents any rules from being actually
created.

Greetings
Marc



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org