[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [O] org-notify: Need to get notifications at the start time of the t
From: |
Charles Philip Chan |
Subject: |
Re: [O] org-notify: Need to get notifications at the start time of the task (in addition to the deadline) |
Date: |
Wed, 08 Jun 2016 20:35:35 -0400 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/25.1.50 (gnu/linux) |
Amit Tendulkar <address@hidden> writes:
Hi Amit:
> I put notify.el in my load path and added the following lines in my init
> file.
>
> (autoload 'notify "notify" "Notify TITLE, BODY.")
> (appt-activate 1)
> (org-agenda-to-appt)
>
> Still I am getting only inline intimations for the appointments. Am I
> missing something?
Sorry, I set this up a long time ago, so I gave you the wrong info,
After searching my configuration files, I found this:
;; Update appt list and dbus appt notification
; Get appointments for today
(defun my-org-agenda-to-appt ()
(interactive)
(setq appt-time-msg-list nil)
(let ((org-deadline-warning-days 0)) ;; will be automatic in org 5.23
(org-agenda-to-appt)))
; Run once, activate and schedule refresh
(my-org-agenda-to-appt)
(appt-activate t)
(run-at-time "00:01" nil 'my-org-agenda-to-appt)
; 5 minute warnings
(setq appt-message-warning-time 15)
(setq appt-display-interval 5)
; Update appt each time agenda opened.
(add-hook 'org-finalize-agenda-hook 'my-org-agenda-to-appt)
; Setup zenify, we tell appt to use window, and replace default function
(setq appt-display-format 'window)
(setq appt-disp-window-function (function my-appt-disp-window))
(defun my-appt-disp-window (min-to-app new-time msg)
(save-window-excursion
(shell-command
(concat "/home/hoor/bin/org-appt-notify '" msg "' '" min-to-app "'&")
nil nil)
)
)
and here is the content of "org-appt-notify"
#!/bin/sh
SOUND="/home/hoor/GNUstep/Library/WindowMaker/Sounds/Kopete_Received.ogg"
ICON="/home/hoor/GNUstep/Library/Icons/apps/system-config-date.tif"
ogg123 "$SOUND"
notify-send --icon="$ICON" "APPOINTMENT" "$1\ndue in $2 mins."
Charles
--
Your job is being a professor and researcher: That's one hell of a good excuse
for some of the brain-damages of minix.
(Linus Torvalds to Andrew Tanenbaum)
signature.asc
Description: PGP signature