emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Charles Philip Chan <cpchan@bell.net>
To: Org-mode <emacs-orgmode@gnu.org>
Subject: Re: 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	[thread overview]
Message-ID: <87d1nr42sp.fsf@bell.net> (raw)
In-Reply-To: <874m94mohv.fsf@persistent.com> (Amit Tendulkar's message of "Wed, 08 Jun 2016 07:27:16 +0530")

[-- Attachment #1: Type: text/plain, Size: 1939 bytes --]

Amit Tendulkar <amit_tendulkar@persistent.com> 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)

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 180 bytes --]

  parent reply	other threads:[~2016-06-09  0:35 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-06-05 12:09 org-notify: Need to get notifications at the start time of the task (in addition to the deadline) Amit Tendulkar
2016-06-05 13:36 ` Marco Wahl
2016-06-06 17:53   ` Amit Tendulkar
2016-06-07  6:08   ` Marco Wahl
2016-06-07  7:24     ` Charles Philip Chan
2016-06-08  1:57       ` Amit Tendulkar
2016-06-08 15:01         ` Nick Dokos
2016-06-09  0:35         ` Charles Philip Chan [this message]
2016-06-10 16:45           ` Amit Tendulkar
2023-10-17  9:13 ` Peter Münster

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87d1nr42sp.fsf@bell.net \
    --to=cpchan@bell.net \
    --cc=emacs-orgmode@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).