From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id EARyKZP/4GBfCAAAgWs5BA (envelope-from ) for ; Sun, 04 Jul 2021 02:23:47 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id +DEGJZP/4GCmIgAAbx9fmQ (envelope-from ) for ; Sun, 04 Jul 2021 00:23:47 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 04799193D2 for ; Sun, 4 Jul 2021 02:23:47 +0200 (CEST) Received: from localhost ([::1]:40354 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lzpvF-0003pr-Mu for larch@yhetil.org; Sat, 03 Jul 2021 20:23:45 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:42754) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lzpuk-0003pj-89 for emacs-orgmode@gnu.org; Sat, 03 Jul 2021 20:23:14 -0400 Received: from mail-pl1-x633.google.com ([2607:f8b0:4864:20::633]:42790) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lzpui-0003ms-Fr for emacs-orgmode@gnu.org; Sat, 03 Jul 2021 20:23:13 -0400 Received: by mail-pl1-x633.google.com with SMTP id v13so8107595ple.9 for ; Sat, 03 Jul 2021 17:23:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:mime-version:subject:message-id:date:to; bh=C676zw0ds1MQzI49EsiJZhr2wV9iYTqL8pilJNcu6vI=; b=OBqwEa/s78ezrk8tBKPumk1LEFmvE98uDlV08RPBS8uJKUtKXzNd6xos01MViXokK0 bhYOuTwG+Zn5Z7h01xDmVKBij6bv4ullqyYKefGsZRKODukkP95KvsUmnMoVOMcv3gtl h3S3N0JKxu04A3TvxjHQxfs2mvCm9ZqNhjRJb0CYX1QLCIrLc61uVpO67nK99BbP+j4j YvMF04KvgFdC3IYno2rxVqPb4DFB/NXYpCNXPzQDQgwsWasoyTX9W3CmIaUjr0jiZR90 udr+xaPcfiMb1lofCxD+Bbea3SDLPikshQF46yuUnLF6AyxSsfzlhLee1BNnP07P7itH 1OKA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:mime-version:subject:message-id:date:to; bh=C676zw0ds1MQzI49EsiJZhr2wV9iYTqL8pilJNcu6vI=; b=J2yF8s3S59XGc9chN/MnxCNW5LlOgWZbmhFJdFz2BaRvVeg9/YnaDaZ88054BWpUgI piakqw+FJsxT4NJnBr69SK7Mrun2EGuPrK7DA0hHQ23l6t0P9DBx02XPGKzbcNM4c7Lj RZYzUhkt7PnqVKOb7rMEUsw19Im2G37u6J2pHYtUubaG6qO8+Yn4gj0b1Bd0HIIEdvTz Oz106Vb1CmtBZppkPDuoKlIAQoWe2OAwljMkF19Jw8P8sDYgoqiI+JyfuDHXtYJcIihd qjwJc+zL6fBvlMiXvZiC5w+vmHHLnJdgDBKBVDF0S+r33OuRg13DiD6xa+DORRNVW5IA ozog== X-Gm-Message-State: AOAM531oNCjDk4KGwpW3UvdRIQlfoG/0ur7FMl3jWI4G1bQFm0rJC4Er 50pCpbSCldN94gLNVzu+eRfa7qgSzA== X-Google-Smtp-Source: ABdhPJxmsVADZKtCwOpZn+X3i9Ba4PkKkH+tI7DV5CTn/t5XD9FGMJjA9mlpjv6EfKtESleLYqvYwg== X-Received: by 2002:a17:90a:cb8c:: with SMTP id a12mr822622pju.184.1625358189682; Sat, 03 Jul 2021 17:23:09 -0700 (PDT) Received: from smtpclient.apple ([150.109.103.155]) by smtp.gmail.com with ESMTPSA id n23sm8988679pgv.76.2021.07.03.17.23.08 for (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Sat, 03 Jul 2021 17:23:09 -0700 (PDT) From: stardiviner Content-Type: multipart/mixed; boundary="Apple-Mail=_E22E5FDF-6938-45D8-B88B-3A315D569C27" Mime-Version: 1.0 (Mac OS X Mail 14.0 \(3654.100.0.2.22\)) Subject: [PATCH] make org-notify support for macOS desktop notification Message-Id: <5B57CD8B-AA91-4C63-A449-A07364083AEE@gmail.com> Date: Sun, 4 Jul 2021 08:23:03 +0800 To: Org-mode X-Mailer: Apple Mail (2.3654.100.0.2.22) Received-SPF: pass client-ip=2607:f8b0:4864:20::633; envelope-from=numbchild@gmail.com; helo=mail-pl1-x633.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1625358227; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=C676zw0ds1MQzI49EsiJZhr2wV9iYTqL8pilJNcu6vI=; b=AZBwHmvvbx5kf8MOx8uNOtnC5KFlsNd/Bc2IUATMHiWV7tRaket+LEuhaOmFxYh42bJ6JV rCb+nrXRQ0BBKL7Bla/e1jFsurZhCMmEdPaw4FSEOogCLt0furwIko7dGpYSJO4cmKneuU oG2jdUZkg4cpf3zqfZ8P3CW8mcepwpcoSkCcmz3sxoB0XM+lwTw6amJZAm4f8GIDkCigZA tdsF3Prp90Ubk22t0uKJRD9A12Vvm9TFXKa22zFFd+7VDS+LRF72SQdW799XhH0sJm5Udx mTlQZDFJtM17JV9mNdL8AlGmr8wji91Da5Hw07r+E8GNShlV/Bm4Mr4UrhZE8Q== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1625358227; a=rsa-sha256; cv=none; b=QK8i8Y6Wni2SR/iXc2Yrf/qCX6SrGpMGDFyX7rzoGdpXQawRPs2LRH5HGCFwuzC9uE+iq4 IrY7K2ihtIJu6HiIV2bu0q8wlKumLidv5tr8ee5z5E79AWlJxIpSH8JkG4Gmkmj4PGsDH5 J3N1Mq0qaQq6sRsEZlrAz/ENUwqGVUChY8zCpAWuq3wPwPBOlgmhSfmWAp2FvJHBOlUaiY dDIYDoIB7xrPLxjTmG1p6KLhjnIORTqjsR0BPs4gvNxPjAAI6HsUvlRq93IegZg3jFeM6D sC39HlI/FsS0rJKf+BZpdf3v/VzPkDZyVuyg+4LYKjU/W/1bhIksKndL5G3VYQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20161025 header.b="OBqwEa/s"; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Migadu-Spam-Score: -2.61 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20161025 header.b="OBqwEa/s"; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Migadu-Queue-Id: 04799193D2 X-Spam-Score: -2.61 X-Migadu-Scanner: scn0.migadu.com X-TUID: binw5TUinlwk --Apple-Mail=_E22E5FDF-6938-45D8-B88B-3A315D569C27 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii I found `org-notify` does not support macOS desktop notification. So I = write a small patch for this. Thanks for reviewing. --Apple-Mail=_E22E5FDF-6938-45D8-B88B-3A315D569C27 Content-Disposition: attachment; filename=0001-org-clock.el-Make-org-notify-support-macOS-notificat.patch Content-Type: application/octet-stream; x-unix-mode=0644; name="0001-org-clock.el-Make-org-notify-support-macOS-notificat.patch" Content-Transfer-Encoding: quoted-printable =46rom=20cfaa53d44a6bc5bcd62efcc77568f46a5ccf50b4=20Mon=20Sep=2017=20= 00:00:00=202001=0AFrom:=20stardiviner=20=0ADate:=20= Sun,=204=20Jul=202021=2008:13:43=20+0800=0ASubject:=20[PATCH]=20= org-clock.el:=20Make=20org-notify=20support=20macOS=20notification=0A=0A= *=20lisp/org-clock.el=20(org-show-notification):=20Add=20support=20for=20= macOS=0Anotification.=0A---=0A=20lisp/org-clock.el=20|=208=20+++++++-=0A=20= 1=20file=20changed,=207=20insertions(+),=201=20deletion(-)=0A=0Adiff=20= --git=20a/lisp/org-clock.el=20b/lisp/org-clock.el=0Aindex=20= cd930e875..df66f2950=20100644=0A---=20a/lisp/org-clock.el=0A+++=20= b/lisp/org-clock.el=0A@@=20-859,7=20+859,7=20@@=20use=20libnotify=20if=20= available,=20or=20fall=20back=20on=20a=20message."=0A=20=09=20=20=20=20= org-show-notification-timeout=0A=20=09=20=20=20=20nil=0A=20=09=20=20=20=20= (lambda=20()=20(w32-notification-close=20id)))))=0A-=09((fboundp=20= 'notifications-notify)=0A+=09((and=20(eq=20system-type=20'gnu/linux)=20= (fboundp=20'notifications-notify))=0A=20=09=20(notifications-notify=0A=20= =09=20=20:title=20"Org=20mode=20message"=0A=20=09=20=20:body=20= notification=0A@@=20-870,6=20+870,12=20@@=20use=20libnotify=20if=20= available,=20or=20fall=20back=20on=20a=20message."=0A=20=09= ((executable-find=20"notify-send")=0A=20=09=20(start-process=20= "emacs-timer-notification"=20nil=0A=20=09=09=09"notify-send"=20= notification))=0A+=20=20=20=20=20=20=20=20((and=20(eq=20system-type=20= 'darwin)=20(fboundp=20'osx-lib-notify2))=0A+=20=20=20=20=20=20=20=20=20= (osx-lib-notify2=20"Org=20mode=20message"=20notification))=0A+=20=20=20=20= =20=20=20=20((and=20(eq=20system-type=20'darwin)=20(executable-find=20= "osascript"))=0A+=09=20(start-process=20"emacs-timer-notification"=20nil=0A= +=09=09=09"osascript"=20"-e"=0A+=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20(format=20"'display=20notification=20= \"%s\"=20with=20title=20\"title\"'"=20notification=20"Org=20mode=20= message")))=0A=20=09;;=20Maybe=20the=20handler=20will=20send=20a=20= message,=20so=20only=20use=20message=20as=0A=20=09;;=20a=20fall=20back=20= option=0A=20=09(t=20(message=20"%s"=20notification))))=0A--=20=0A2.30.1=20= (Apple=20Git-130)=0A=0A= --Apple-Mail=_E22E5FDF-6938-45D8-B88B-3A315D569C27--