diff options
author | Sergey Poznyakoff <gray@gnu.org.ua> | 2009-02-21 12:53:43 +0200 |
---|---|---|
committer | Sergey Poznyakoff <gray@gnu.org.ua> | 2009-02-21 12:53:43 +0200 |
commit | 12fd740c530106f4a74c5ff2c6ce6d0ea305ab70 (patch) | |
tree | 6064e3770a3fa4210443cfc9f8cd390b932aee94 /src/wydawca.h | |
parent | 62758ace16e756050f15b81e66ee5ab3bdd062ab (diff) | |
download | wydawca-12fd740c530106f4a74c5ff2c6ce6d0ea305ab70.tar.gz wydawca-12fd740c530106f4a74c5ff2c6ce6d0ea305ab70.tar.bz2 |
Implement per-directory notifications
* src/config.c (default_notification): New static.
(cb_notify_event): Explicitly link new notification to the chain.
(directory_kw): New keyword "notify-event".
(cb_directory): Use previously defined global notifications.
* src/mail.c (register_notification): Remove.
(notify): Tak a list of notifications to run as an argument.
* src/directive.c, src/gpg.c, src/verify.c: Update calls to notify.
* src/wydawca.h (struct directory_pair.notification): New member.
* tests/notify-upl.at: Define notifications before the directory pair in
the configuration file.
Diffstat (limited to 'src/wydawca.h')
-rw-r--r-- | src/wydawca.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/wydawca.h b/src/wydawca.h index 152d914..893e334 100644 --- a/src/wydawca.h +++ b/src/wydawca.h @@ -134,6 +134,7 @@ struct directory_pair after this amount of time */ struct access_method *access_method[access_method_count]; struct archive_descr archive; /* Archivation data */ + struct notification *notification; }; @@ -225,10 +226,10 @@ struct notification const char *msg; }; -void register_notification (const struct notification *notif); void register_message_template (const char *name, const char *text); -void notify (struct file_triplet *, enum notification_event); +void notify (struct notification *, + struct file_triplet *, enum notification_event); const char *notification_event_str (enum notification_event evt); const char *notification_target_str (enum notification_target tgt); |