From mboxrd@z Thu Jan 1 00:00:00 1970 From: Christian Thaeter Subject: Re: sip: links Date: Tue, 23 Jun 2015 10:33:04 +0200 Message-ID: <20150623103304.6ce032f6@jupiter.pipapo.org> References: <20150620172345.5ec7bd92@jupiter.pipapo.org> <87y4jdjqjj.fsf@strey.biz> <20150621181508.613cf089@jupiter.pipapo.org> <87mvzshz3l.fsf@strey.biz> <20150622170202.286a8986@jupiter.pipapo.org> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:44245) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Z7Jds-0006A0-3x for emacs-orgmode@gnu.org; Tue, 23 Jun 2015 04:33:21 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Z7Jdo-0002p5-3N for emacs-orgmode@gnu.org; Tue, 23 Jun 2015 04:33:16 -0400 Received: from pipapo.org ([217.8.59.205]:46652 helo=mail.pipapo.org) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Z7Jdn-0002oX-Rh for emacs-orgmode@gnu.org; Tue, 23 Jun 2015 04:33:12 -0400 In-Reply-To: List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: "briangpowell ." Cc: emacs-orgmode On 2015-06-23 00:24, briangpowell . wrote: > Cool, what do you do with "xmpp:"? just opening 'psi-plus' here with a message window, I haven't figured out how to do more (aka all this xmpp: url variants) Again, just a crude works-for-me snippet: ;;; org-xmpp.el - Support for xmpp communication (require 'org) (org-add-link-type "xmpp" 'org-xmpp-open) (defcustom org-xmpp-command "psi-plus --remote --uri='%u'" "The Emacs command to be used to make a xmpp request." :group 'org-link :type '(string)) (defun org-xmpp-open (destination) "make a xmpp to DESTINATION" (start-process-shell-command "xmpp" nil (org-replace-escapes org-xmpp-command `(("%u" . ,destination))))) (provide 'org-xmpp) ;;; org-xmpp.el ends here Christian > > On Mon, Jun 22, 2015 at 11:02 AM, Christian Thaeter > wrote: > > > > > > > On 2015-06-22 11:27, Michael Strey wrote: > > > > > On So, 2015-06-21, Christian Thaeter wrote: > > > > > > [...] > > > > > > > looks good, I'll use that instead of my hack. > > > > > > Look out for bugs. It's one of my very first emacs-lisp hacks. > > > > > > > I've a minor ideas to add: > > > > > > > > Instead just append the telephone number to the end of the > > > > dial command one could use (org-replace-escapes STRING TABLE), > > > > that allows little more flexible commandline generation. > > > > > > Thanks for the hint. Could you please give me an example where > > > this increased flexibility would be required? > > > > I am using linphone too, where that just works to append the > > sanitized telephone number at the end. But I can imagine that other > > dial programs may have different calling conventions. Also I may > > feel a bit safer by quoting the telephone number, For example: > > > > linephone -c 'sip:%n' > > > > Maybe in the long run (I have no urge here, works for me now). > > You/we/someone could make this whole thing more generic, handling > > different kinds of communication protocols (I made another one for > > xmpp: meanwhile). > > > > tel: urls are somewhat simple https://www.ietf.org/rfc/rfc3966.txt > > (still surprisingly more syntax than just a number) but when you > > look at sip: http://tools.ietf.org/html/rfc3261#section-19.1 things > > get way more complicated. > > > > Christian > > > > > > > > > > > > Best regards > > > -- > > > Michael Strey > > > http://www.strey.biz * https://twitter.com/michaelstrey > > > > > > > > > > > >