From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Ryan Yeske Newsgroups: gmane.emacs.devel Subject: Re: PATCH: Add the ability to give rcirc servers an alias name Date: Thu, 17 Dec 2015 10:40:27 -0800 Message-ID: <1450377627.2542222.470336049.757BB9A6@webmail.messagingengine.com> References: <877flsgut2.fsf@gmail.com> <1447008724.187480.432504041.0E012C01@webmail.messagingengine.com> <1450246571.999218.468767129.1BD269CA@webmail.messagingengine.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="_----------=_145037762725422225"; charset="utf-8" Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1450378384 703 80.91.229.3 (17 Dec 2015 18:53:04 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 17 Dec 2015 18:53:04 +0000 (UTC) Cc: Leo Liu , Artur Malabarba , emacs-devel@gnu.org To: Dave Barker Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Dec 17 19:52:48 2015 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1a9dfO-0003of-D6 for ged-emacs-devel@m.gmane.org; Thu, 17 Dec 2015 19:52:42 +0100 Original-Received: from localhost ([::1]:56340 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a9dfN-0007z8-Mt for ged-emacs-devel@m.gmane.org; Thu, 17 Dec 2015 13:52:41 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:41837) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a9dTe-0004KM-Le for emacs-devel@gnu.org; Thu, 17 Dec 2015 13:40:36 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1a9dTa-0004pb-69 for emacs-devel@gnu.org; Thu, 17 Dec 2015 13:40:34 -0500 Original-Received: from out1-smtp.messagingengine.com ([66.111.4.25]:40088) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a9dTZ-0004pO-Se for emacs-devel@gnu.org; Thu, 17 Dec 2015 13:40:30 -0500 Original-Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailout.nyi.internal (Postfix) with ESMTP id 2FA0B20330 for ; Thu, 17 Dec 2015 13:40:28 -0500 (EST) Original-Received: from web1 ([10.202.2.211]) by compute4.internal (MEProxy); Thu, 17 Dec 2015 13:40:28 -0500 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=ryanyeske.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-sasl-enc :x-sasl-enc; s=mesmtp; bh=wEVRZw6k9+mqCjPEGrbQF3SRSBs=; b=dJkX/H jFUu08IMyMU7lWG6saK3KZ9/JiuFiKenU4OWplsAdYHm4BCKnd3kTn9K37R83sGy bJMmnft5AycuwZArSipiUmg0PzpZH1IcJwlb5p/QZprielxmERd4T8WhB3wlBB9R 81mO5D+moEiyr59ZJUt/iL5VSn0y72rOhOviY= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-sasl-enc:x-sasl-enc; s=smtpout; bh=wEVRZw6k9+mqCjP EGrbQF3SRSBs=; b=Ymg8laSQrfHQnfsS2kph+hZ8YxZ8TZVZzfSiUZ+Sv+fnmSV LLLIyGNjjFcbK2NdXEGJJmbchd3E1UfRk+aC3OpflTFUh2QdI+Da5w5S12Gz8flR bE/h7jPQ2VN73BoSYs9Yv4n87dDRzbLnrYpu5bZms7T6ltMYqfk8U3616loI= Original-Received: by web1.nyi.internal (Postfix, from userid 99) id EA403AE5BA4; Thu, 17 Dec 2015 13:40:27 -0500 (EST) X-Sasl-Enc: oBNHAas191xSU/8kWx5gY/1xuZxrONGkEoBp8ITwsv0P 1450377627 X-Mailer: MessagingEngine.com Webmail Interface - ajax-a93c17cb In-Reply-To: X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 66.111.4.25 X-Mailman-Approved-At: Thu, 17 Dec 2015 13:52:38 -0500 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:196428 Archived-At: This is a multi-part message in MIME format. --_----------=_145037762725422225 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="ISO-8859-1" Thanks for all your patience with this Dave. I think you are right on both counts. =A0Creating a helper function doesn't really work. =A0And creating multiple connections to one server is almost never what we would want. I approve this patch. =A0What is the next step to getting this merged into emacs? Ryan On Wed, Dec 16, 2015, at 04:29 AM, Dave Barker wrote: > Thanks for taking a look Ryan. > > I agree that `(or server-alias server)` shows up quite frequently. > > I don't think creating a function server-or-alias would help however > as in all cases both the `server` and `server-alias` variables are > local to the function (`rcirc` and `rcirc-connect`), so we would have > to pass them through. In other words we would be replacing `(or server- > alias server)` with something like `(server-or-alias server server- > alias)`! I could let a new local variable `server-or-alias` in both > functions if you think that would look nicer? > > As for the automatic server alias, I'm undecided. I think _usually_ > the desired behaviour is to just warn the user that server X is > already connected if she/he attempt to connect again. That's certainly > how I use rcric, for example I might have only lost connection to one > of four servers but I would still just call `rcirc` to reconnect to > that one. I'm struggling to think of many use cases where connecting > multiple times is required, and perhaps it's good for those that the > alias needs to be defined manually? > > Cheers, Dave. > > On Wed, Dec 16, 2015 at 6:16 AM, Ryan Yeske > wrote: >> __ >> Hi Dave, >> >> I got a chance to review this.=A0 It works fine for me here. >> >> I think it might be good to replace the several instances of `(or server- >> alias server)' with calls to a new function `rcirc-server-or-alias`. >> >> Also, what about automatically creating this alias when connecting to >> a server multiple times, without requiring the user to come up with >> an alias?=A0 Like automatically creating the server name >> `*irc.freenode.net*' and `*irc.freenode.net<1>'.=A0 This would only >> happen if disambiguating aliases were not provided via your new >> mechanism. >> >> What do you think? >> >> >> Ryan >> >> >> --_----------=_145037762725422225 Content-Transfer-Encoding: 7bit Content-Type: text/html; charset="ISO-8859-1"
Thanks for all your patience with this Dave.
 
I think you are right on both counts.  Creating a helper function doesn't really work.  And creating multiple connections to one server is almost never what we would want.
 
I approve this patch.  What is the next step to getting this merged into emacs?
 
Ryan
 
 
On Wed, Dec 16, 2015, at 04:29 AM, Dave Barker wrote:
 
Thanks for taking a look Ryan.
 
I agree that `(or server-alias server)` shows up quite frequently.
 
I don't think creating a function server-or-alias would help however as in all
cases both the `server` and `server-alias` variables are local to the function
(`rcirc` and `rcirc-connect`), so we would have to pass them through. In other
words we would be replacing `(or server-alias server)` with something like
`(server-or-alias server server-alias)`! I could let a new local variable
`server-or-alias` in both functions if you think that would look nicer?
 
As for the automatic server alias, I'm undecided. I think _usually_ the desired
behaviour is to just warn the user that server X is already connected if she/he
attempt to connect again. That's certainly how I use rcric, for example I might
have only lost connection to one of four servers but I would still just call
`rcirc` to reconnect to that one. I'm struggling to think of many use cases
where connecting multiple times is required, and perhaps it's good for those
that the alias needs to be defined manually?
 
Cheers, Dave.
 
On Wed, Dec 16, 2015 at 6:16 AM, Ryan Yeske <ryan@ryanyeske.com> wrote:

Hi Dave,
 
I got a chance to review this.  It works fine for me here.
 
I think it might be good to replace the several instances of `(or server-alias server)' with calls to a new function `rcirc-server-or-alias`.
 
Also, what about automatically creating this alias when connecting to a server multiple times, without requiring the user to come up with an alias?  Like automatically creating the server name `*irc.freenode.net*' and `*irc.freenode.net<1>'.  This would only happen if disambiguating aliases were not provided via your new mechanism.
 
What do you think?
 
 
Ryan
 
 
 
 
--_----------=_145037762725422225--