From unknown Sun Jun 15 08:36:39 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#25426 <25426@debbugs.gnu.org> To: bug#25426 <25426@debbugs.gnu.org> Subject: Status: [PATCH] in net-utils.el several DNS query functions now take optional name server argument; also, `dig-program-options' added Reply-To: bug#25426 <25426@debbugs.gnu.org> Date: Sun, 15 Jun 2025 15:36:39 +0000 retitle 25426 [PATCH] in net-utils.el several DNS query functions now take = optional name server argument; also, `dig-program-options' added=20 reassign 25426 emacs submitter 25426 Andrew Robbins severity 25426 wishlist tag 25426 patch thanks From debbugs-submit-bounces@debbugs.gnu.org Thu Jan 12 11:11:00 2017 Received: (at submit) by debbugs.gnu.org; 12 Jan 2017 16:11:00 +0000 Received: from localhost ([127.0.0.1]:51718 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cRhxr-0001MB-Fe for submit@debbugs.gnu.org; Thu, 12 Jan 2017 11:11:00 -0500 Received: from eggs.gnu.org ([208.118.235.92]:46916) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cRfyv-0004jR-FG for submit@debbugs.gnu.org; Thu, 12 Jan 2017 09:03:57 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cRfyl-0001tt-T0 for submit@debbugs.gnu.org; Thu, 12 Jan 2017 09:03:52 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-0.0 required=5.0 tests=BAYES_40 autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:44388) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1cRfyl-0001tn-Q3 for submit@debbugs.gnu.org; Thu, 12 Jan 2017 09:03:47 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:37857) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cRfyk-0003Il-M7 for bug-gnu-emacs@gnu.org; Thu, 12 Jan 2017 09:03:47 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cRfyf-0001n7-Pf for bug-gnu-emacs@gnu.org; Thu, 12 Jan 2017 09:03:46 -0500 Received: from aibo.runbox.com ([91.220.196.211]:57395) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1cRfyf-0001kS-DG for bug-gnu-emacs@gnu.org; Thu, 12 Jan 2017 09:03:41 -0500 Received: from [10.9.9.210] (helo=mailfront10.runbox.com) by bars.runbox.com with esmtp (Exim 4.71) (envelope-from ) id 1cRfyZ-0001vI-KY for bug-gnu-emacs@gnu.org; Thu, 12 Jan 2017 15:03:36 +0100 Received: from [37.235.55.188] (helo=[5.254.96.200]) by mailfront10.runbox.com with esmtpsa (uid:855208 ) (TLS1.2:DHE_RSA_AES_128_CBC_SHA1:128) (Exim 4.82) id 1cRfy8-0003FF-0b for bug-gnu-emacs@gnu.org; Thu, 12 Jan 2017 15:03:08 +0100 From: Andrew Robbins To: bug-gnu-emacs@gnu.org Subject: [PATCH] in net-utils.el several DNS query functions now take optional name server argument; also, `dig-program-options' added User-Agent: Gnus/5.13 (Gnus v5.13) Date: Thu, 12 Jan 2017 09:03:02 -0500 Message-ID: <878tqgs7e1.fsf@andrewrobbins.info> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x [fuzzy] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -4.1 (----) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Thu, 12 Jan 2017 11:10:58 -0500 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -4.1 (----) --=-=-= Content-Type: text/plain - In a git-clone'd "lisp/net/net-utils.el" I modified several interactive DNS-querying functions (nslookup-host, dns-lookup-host, run-dig) to allow specifying a particular name server to use where before you couldn't. This is possible non-interactively as well as interactively with a prefix argument. - Also, a new variable `dig-program-options' is defined to allow users to set options for use with `run-dig'. This is in line with the current `nslookup-program-options' and `dns-lookup-program-options' and is necessary for the new definition of `run-dig' to function. - The `run-dig' function no longer needs the auto-loaded `ffap-string-at-point' function, removing one dependency on ffap.el For all users, and especially those unaware of the changes, there should be no discernible difference in functionality when used exactly as before. My changelog and diff are attached. --=-=-= Content-Type: application/octet-stream Content-Disposition: attachment; filename=changelog_net-utils Content-Transfer-Encoding: base64 MjAxNy0wMS0xMiAgQW5kcmV3IFJvYmJpbnMgIDxjb250YWN0QGFuZHJld3JvYmJpbnMuaW5mbz4K CgkqIGxpc3AvbmV0L25ldC11dGlscy5lbCAoZmZhcC1zdHJpbmctYXQtcG9pbnQpOiBSZW1vdmVk IGR1ZSB0bwoJJ25ldC11dGlscy1tYWNoaW5lLWF0LXBvaW50JyBvYnZpYXRpbmcgdGhpcyBhdXRv bG9hZGVkIGZ1bmN0aW9uLgoJKGRpZy1wcm9ncmFtLW9wdGlvbnMpOiBOZXcgY3VzdG9taXphdGlv biB2YXJpYWJsZS4KCShuc2xvb2t1cC1ob3N0LCBkbnMtbG9va3VwLWhvc3QsIHJ1bi1kaWcpOiBD YW4gbm93IHNwZWNpZnkgb3B0aW9uYWwKCW5hbWUgc2VydmVyIGFyZ3VtZW50IGludGVyYWN0aXZl bHkgKGJ5IHByZWZpeCBhcmcpICYgbm9uaW50ZXJhY3RpdmVseS4KCg== --=-=-= Content-Type: application/octet-stream Content-Disposition: attachment; filename=diff_net-utils Content-Transfer-Encoding: base64 LS0tIE9MRF9uZXQtdXRpbHMuZWwJMjAxNy0wMS0xMiAwNDowODo0MC4wOTQ4ODY3NDcgLTA1MDAK KysrIE5FV19uZXQtdXRpbHMuZWwJMjAxNy0wMS0xMiAwNjozMDowNS4wNTUzMzQyNjcgLTA1MDAK QEAgLTE5OSw2ICsxOTksMTEgQEAKICAgOmdyb3VwICduZXQtdXRpbHMKICAgOnR5cGUgICdzdHJp bmcpCiAKKyhkZWZjdXN0b20gZGlnLXByb2dyYW0tb3B0aW9ucyBuaWwKKyAgIk9wdGlvbnMgZm9y IHRoZSBkaWcgcHJvZ3JhbS4iCisgIDpncm91cCAnbmV0LXV0aWxzCisgIDp0eXBlICcocmVwZWF0 IHN0cmluZykpCisKIChkZWZjdXN0b20gZnRwLXByb2dyYW0gImZ0cCIKICAgIlByb2dyYW0gdG8g cnVuIHRvIGRvIEZUUCB0cmFuc2ZlcnMuIgogICA6Z3JvdXAgJ25ldC11dGlscwpAQCAtNTA3LDIw ICs1MTIsMjcgQEAKIDs7ICAgKGRlbGV0ZS1tYXRjaGluZy1saW5lcyBmaWx0ZXIpKQogCiA7Ozsj IyNhdXRvbG9hZAotKGRlZnVuIG5zbG9va3VwLWhvc3QgKGhvc3QpCi0gICJMb29rdXAgdGhlIERO UyBpbmZvcm1hdGlvbiBmb3IgSE9TVC4iCisoZGVmdW4gbnNsb29rdXAtaG9zdCAoaG9zdCAmb3B0 aW9uYWwgbmFtZS1zZXJ2ZXIpCisgICJMb29rIHVwIHRoZSBETlMgaW5mb3JtYXRpb24gZm9yIEhP U1QgKG5hbWUgb3IgSVAgYWRkcmVzcykuCitXaGVuIGNhbGxlZCBpbnRlcmFjdGl2ZWx5LCBETlMg cmVzb2x2ZXIgTkFNRS1TRVJWRVIgbWF5IGJlIHNwZWNpZmllZAorYnkgcGFzc2luZyB0aGUgZnVu Y3Rpb24gYSBwcmVmaXggYXJndW1lbnQuIgogICAoaW50ZXJhY3RpdmUKLSAgIChsaXN0IChyZWFk LWZyb20tbWluaWJ1ZmZlciAiTG9va3VwIGhvc3Q6ICIgKG5ldC11dGlscy1tYWNoaW5lLWF0LXBv aW50KSkpKQorICAgKGlmIGN1cnJlbnQtcHJlZml4LWFyZworICAgICAgIChsaXN0CisgICAgICAg IChyZWFkLWZyb20tbWluaWJ1ZmZlciAiTG9vayB1cCBob3N0OiAiIChuZXQtdXRpbHMtbWFjaGlu ZS1hdC1wb2ludCkpCisgICAgICAgIChyZWFkLWZyb20tbWluaWJ1ZmZlciAiTmFtZSBzZXJ2ZXI6 ICIpKQorICAgICAobGlzdAorICAgICAgKHJlYWQtZnJvbS1taW5pYnVmZmVyICJMb29rIHVwIGhv c3Q6ICIgKG5ldC11dGlscy1tYWNoaW5lLWF0LXBvaW50KSkpKSkKICAgKGxldCAoKG9wdGlvbnMK LQkgKGlmIG5zbG9va3VwLXByb2dyYW0tb3B0aW9ucwotCSAgICAgKGFwcGVuZCBuc2xvb2t1cC1w cm9ncmFtLW9wdGlvbnMgKGxpc3QgaG9zdCkpCi0JICAgKGxpc3QgaG9zdCkpKSkKKwkgKGlmIG5h bWUtc2VydmVyCisJICAgICAoYXBwZW5kIG5zbG9va3VwLXByb2dyYW0tb3B0aW9ucyAobGlzdCBo b3N0IG5hbWUtc2VydmVyKSkKKwkgICAoYXBwZW5kIG5zbG9va3VwLXByb2dyYW0tb3B0aW9ucyAo bGlzdCBob3N0KSkpKSkKICAgICAobmV0LXV0aWxzLXJ1bi1wcm9ncmFtCiAgICAgICJOc2xvb2t1 cCIKICAgICAgKGNvbmNhdCAiKiogIgotICAgICAgKG1hcGNvbmNhdCAnaWRlbnRpdHkKLQkJKGxp c3QgIk5zbG9va3VwIiBob3N0IG5zbG9va3VwLXByb2dyYW0pCi0JCSIgKiogIikpCisJICAgICAo bWFwY29uY2F0ICdpZGVudGl0eQorCQkgICAgICAgIChsaXN0ICJOc2xvb2t1cCIgaG9zdCBuc2xv b2t1cC1wcm9ncmFtKQorCQkgICAgICAgICIgKiogIikpCiAgICAgIG5zbG9va3VwLXByb2dyYW0K ICAgICAgb3B0aW9ucykpKQogCkBAIC01NTEsNDAgKzU2Myw1OCBAQAogICAoc2V0cSBjb21pbnQt aW5wdXQtYXV0b2V4cGFuZCB0KSkKIAogOzs7IyMjYXV0b2xvYWQKLShkZWZ1biBkbnMtbG9va3Vw LWhvc3QgKGhvc3QpCi0gICJMb29rdXAgdGhlIEROUyBpbmZvcm1hdGlvbiBmb3IgSE9TVCAobmFt ZSBvciBJUCBhZGRyZXNzKS4iCisoZGVmdW4gZG5zLWxvb2t1cC1ob3N0IChob3N0ICZvcHRpb25h bCBuYW1lLXNlcnZlcikKKyAgIkxvb2sgdXAgdGhlIEROUyBpbmZvcm1hdGlvbiBmb3IgSE9TVCAo bmFtZSBvciBJUCBhZGRyZXNzKS4KK1doZW4gY2FsbGVkIGludGVyYWN0aXZlbHksIEROUyByZXNv bHZlciBOQU1FLVNFUlZFUiBtYXkgYmUgc3BlY2lmaWVkCitieSBwYXNzaW5nIHRoZSBmdW5jdGlv biBhIHByZWZpeCBhcmd1bWVudC4iCiAgIChpbnRlcmFjdGl2ZQotICAgKGxpc3QgKHJlYWQtZnJv bS1taW5pYnVmZmVyICJMb29rdXAgaG9zdDogIiAobmV0LXV0aWxzLW1hY2hpbmUtYXQtcG9pbnQp KSkpCisgICAoaWYgY3VycmVudC1wcmVmaXgtYXJnCisgICAgICAgKGxpc3QKKyAgICAgICAgKHJl YWQtZnJvbS1taW5pYnVmZmVyICJMb29rIHVwIGhvc3Q6ICIgKG5ldC11dGlscy1tYWNoaW5lLWF0 LXBvaW50KSkKKyAgICAgICAgKHJlYWQtZnJvbS1taW5pYnVmZmVyICJOYW1lIHNlcnZlcjogIikp CisgICAgIChsaXN0CisgICAgICAocmVhZC1mcm9tLW1pbmlidWZmZXIgIkxvb2sgdXAgaG9zdDog IiAobmV0LXV0aWxzLW1hY2hpbmUtYXQtcG9pbnQpKSkpKQogICAobGV0ICgob3B0aW9ucwotCSAo aWYgZG5zLWxvb2t1cC1wcm9ncmFtLW9wdGlvbnMKLQkgICAgIChhcHBlbmQgZG5zLWxvb2t1cC1w cm9ncmFtLW9wdGlvbnMgKGxpc3QgaG9zdCkpCi0JICAgKGxpc3QgaG9zdCkpKSkKKwkgKGlmIG5h bWUtc2VydmVyCisJICAgICAoYXBwZW5kIGRucy1sb29rdXAtcHJvZ3JhbS1vcHRpb25zIChsaXN0 IGhvc3QgbmFtZS1zZXJ2ZXIpKQorCSAgIChhcHBlbmQgZG5zLWxvb2t1cC1wcm9ncmFtLW9wdGlv bnMgKGxpc3QgaG9zdCkpKSkpCiAgICAgKG5ldC11dGlscy1ydW4tcHJvZ3JhbQogICAgICAoY29u Y2F0ICJETlMgTG9va3VwIFsiIGhvc3QgIl0iKQogICAgICAoY29uY2F0ICIqKiAiCi0gICAgICAo bWFwY29uY2F0ICdpZGVudGl0eQotCQkobGlzdCAiRE5TIExvb2t1cCIgaG9zdCBkbnMtbG9va3Vw LXByb2dyYW0pCi0JCSIgKiogIikpCisJICAgICAobWFwY29uY2F0ICdpZGVudGl0eQorCQkgICAg ICAgIChsaXN0ICJETlMgTG9va3VwIiBob3N0IGRucy1sb29rdXAtcHJvZ3JhbSkKKwkJICAgICAg ICAiICoqICIpKQogICAgICBkbnMtbG9va3VwLXByb2dyYW0KICAgICAgb3B0aW9ucykpKQogCi0o YXV0b2xvYWQgJ2ZmYXAtc3RyaW5nLWF0LXBvaW50ICJmZmFwIikKLQogOzs7IyMjYXV0b2xvYWQK LShkZWZ1biBydW4tZGlnIChob3N0KQotICAiUnVuIGRpZyBwcm9ncmFtLiIKKyhkZWZ1biBydW4t ZGlnIChob3N0ICZvcHRpb25hbCBuYW1lLXNlcnZlcikKKyAgIkxvb2sgdXAgdGhlIEROUyBpbmZv cm1hdGlvbiBmb3IgSE9TVCAobmFtZSBvciBJUCBhZGRyZXNzKS4KK1doZW4gY2FsbGVkIGludGVy YWN0aXZlbHksIEROUyByZXNvbHZlciBOQU1FLVNFUlZFUiBtYXkgYmUgc3BlY2lmaWVkCitieSBw YXNzaW5nIHRoZSBmdW5jdGlvbiBhIHByZWZpeCBhcmd1bWVudC4iCiAgIChpbnRlcmFjdGl2ZQot ICAgKGxpc3QKLSAgICAocmVhZC1mcm9tLW1pbmlidWZmZXIgIkxvb2t1cCBob3N0OiAiCi0gICAg ICAgICAgICAgICAgICAgICAgICAgIChvciAoZmZhcC1zdHJpbmctYXQtcG9pbnQgJ21hY2hpbmUp ICIiKSkpKQotICAobmV0LXV0aWxzLXJ1bi1wcm9ncmFtCi0gICAiRGlnIgotICAgKGNvbmNhdCAi KiogIgotCSAgIChtYXBjb25jYXQgJ2lkZW50aXR5Ci0JCSAgICAgIChsaXN0ICJEaWciIGhvc3Qg ZGlnLXByb2dyYW0pCi0JCSAgICAgICIgKiogIikpCi0gICBkaWctcHJvZ3JhbQotICAgKGxpc3Qg aG9zdCkpKQorICAgKGlmIGN1cnJlbnQtcHJlZml4LWFyZworICAgICAgIChsaXN0CisgICAgICAg IChyZWFkLWZyb20tbWluaWJ1ZmZlciAiTG9vayB1cCBob3N0OiAiIChuZXQtdXRpbHMtbWFjaGlu ZS1hdC1wb2ludCkpCisgICAgICAgIChyZWFkLWZyb20tbWluaWJ1ZmZlciAiTmFtZSBzZXJ2ZXI6 ICIpKQorICAgICAobGlzdAorICAgICAgKHJlYWQtZnJvbS1taW5pYnVmZmVyICJMb29rIHVwIGhv c3Q6ICIgKG5ldC11dGlscy1tYWNoaW5lLWF0LXBvaW50KSkpKSkKKyAgKGxldCogKChzZXJ2ZXIK KwkgIChpZiAoYW5kIG5hbWUtc2VydmVyIChlcXVhbCAiZGlnIiBkaWctcHJvZ3JhbSkpCisJICAg ICAgKGNvbmNhdCAiQCIgbmFtZS1zZXJ2ZXIpCisJICAgIG5hbWUtc2VydmVyKSkKKwkgKG9wdGlv bnMKKwkgIChpZiBzZXJ2ZXIKKwkgICAgICAoYXBwZW5kIGRpZy1wcm9ncmFtLW9wdGlvbnMgKGxp c3QgaG9zdCBzZXJ2ZXIpKQorCSAgICAoYXBwZW5kIGRpZy1wcm9ncmFtLW9wdGlvbnMgKGxpc3Qg aG9zdCkpKSkpCisgICAgKG5ldC11dGlscy1ydW4tcHJvZ3JhbQorICAgICAiRGlnIgorICAgICAo Y29uY2F0ICIqKiAiCisJICAgICAobWFwY29uY2F0ICdpZGVudGl0eQorCQkgICAgICAgIChsaXN0 ICJEaWciIGhvc3QgZGlnLXByb2dyYW0pCisJCSAgICAgICAgIiAqKiAiKSkKKyAgICAgZGlnLXBy b2dyYW0KKyAgICAgb3B0aW9ucykpKQogCiAoYXV0b2xvYWQgJ2NvbWludC1leGVjICJjb21pbnQi KQogCg== --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Mon Feb 13 22:15:42 2017 Received: (at 25426) by debbugs.gnu.org; 14 Feb 2017 03:15:42 +0000 Received: from localhost ([127.0.0.1]:39112 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cdTag-0001zX-I2 for submit@debbugs.gnu.org; Mon, 13 Feb 2017 22:15:42 -0500 Received: from aibo.runbox.com ([91.220.196.211]:44144) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cdTae-0001zN-Gd for 25426@debbugs.gnu.org; Mon, 13 Feb 2017 22:15:41 -0500 Received: from [10.9.9.211] (helo=mailfront11.runbox.com) by mailtransmit02.runbox with esmtp (Exim 4.86_2) (envelope-from ) id 1cdTac-0000Pj-A4 for 25426@debbugs.gnu.org; Tue, 14 Feb 2017 04:15:38 +0100 Received: from [37.235.55.188] (helo=wallflower) by mailfront11.runbox.com with esmtpsa (uid:855208 ) (TLS1.2:DHE_RSA_AES_128_CBC_SHA1:128) (Exim 4.82) id 1cdTaP-00079B-G9 for 25426@debbugs.gnu.org; Tue, 14 Feb 2017 04:15:26 +0100 From: Andrew Robbins To: 25426@debbugs.gnu.org Subject: Re: Copyright Assignment User-Agent: Gnus/5.13 (Gnus v5.13) Date: Mon, 13 Feb 2017 22:15:08 -0500 Message-ID: <87tw7x1n0j.fsf@andrewrobbins.info> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 25426 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.7 (/) I recently realized that I neglected to include in my patch submission information regarding copyright assignment. I haven't filled out the required paperwork to assign copyright to the FSF so if that is the only thing standing in the way of accepting the patch then I will gladly fill it out should a dev send it my way. Should the patch not be merged, I'll be sure to include the above information in any future patch submissions (and make them better as well!). Regards, Andrew Robbins From debbugs-submit-bounces@debbugs.gnu.org Tue Feb 14 11:23:04 2017 Received: (at 25426) by debbugs.gnu.org; 14 Feb 2017 16:23:04 +0000 Received: from localhost ([127.0.0.1]:40018 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cdfse-0000K5-9a for submit@debbugs.gnu.org; Tue, 14 Feb 2017 11:23:04 -0500 Received: from eggs.gnu.org ([208.118.235.92]:51737) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cdfsb-0000JM-5s for 25426@debbugs.gnu.org; Tue, 14 Feb 2017 11:23:01 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cdfsT-00058a-DZ for 25426@debbugs.gnu.org; Tue, 14 Feb 2017 11:22:56 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,RP_MATCHES_RCVD autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:49630) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cdfsT-00058T-9X; Tue, 14 Feb 2017 11:22:53 -0500 Received: from 84.94.185.246.cable.012.net.il ([84.94.185.246]:3119 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1cdfsS-0005XC-He; Tue, 14 Feb 2017 11:22:53 -0500 Date: Tue, 14 Feb 2017 18:23:12 +0200 Message-Id: <831sv0213j.fsf@gnu.org> From: Eli Zaretskii To: Andrew Robbins In-reply-to: <87tw7x1n0j.fsf@andrewrobbins.info> (message from Andrew Robbins on Mon, 13 Feb 2017 22:15:08 -0500) Subject: Re: bug#25426: Copyright Assignment References: <878tqgs7e1.fsf@andrewrobbins.info> <87tw7x1n0j.fsf@andrewrobbins.info> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 25426 Cc: 25426@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -5.0 (-----) > From: Andrew Robbins > Date: Mon, 13 Feb 2017 22:15:08 -0500 > > I recently realized that I neglected to include in my patch > submission information regarding copyright assignment. I haven't > filled out the required paperwork to assign copyright to the FSF > so if that is the only thing standing in the way of accepting the > patch then I will gladly fill it out should a dev send it my > way. Yes, your contribution is large enough to require legal paperwork. I will send you the copyright assignment form off-list. Thanks. From debbugs-submit-bounces@debbugs.gnu.org Fri May 05 22:40:53 2017 Received: (at 25426) by debbugs.gnu.org; 6 May 2017 02:40:53 +0000 Received: from localhost ([127.0.0.1]:56993 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1d6peP-0007JY-0O for submit@debbugs.gnu.org; Fri, 05 May 2017 22:40:53 -0400 Received: from aibo.runbox.com ([91.220.196.211]:48212) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1d6peM-0007JL-T4 for 25426@debbugs.gnu.org; Fri, 05 May 2017 22:40:51 -0400 Received: from [10.9.9.211] (helo=mailfront11.runbox.com) by mailtransmit02.runbox with esmtp (Exim 4.86_2) (envelope-from ) id 1d6peL-0004x0-IP for 25426@debbugs.gnu.org; Sat, 06 May 2017 04:40:49 +0200 Received: from linux-cryptofree1-a.xn--cdaan2d.be ([212.129.34.154] helo=wallflower) by mailfront11.runbox.com with esmtpsa (uid:855208 ) (TLS1.2:DHE_RSA_AES_128_CBC_SHA1:128) (Exim 4.82) id 1d6peB-0007eh-Az for 25426@debbugs.gnu.org; Sat, 06 May 2017 04:40:39 +0200 From: Andrew Robbins To: 25426@debbugs.gnu.org Subject: Copyright Assignment Completed User-Agent: Gnus/5.13 (Gnus v5.13) Date: Fri, 05 May 2017 22:40:18 -0400 Message-ID: <87o9v6673h.fsf@andrewrobbins.info> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 25426 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.7 (/) I completed the copyright assignment paperwork a couple of months ago but forgot to follow-up on here afterward. So, uh, here's that (late) follow-up. From debbugs-submit-bounces@debbugs.gnu.org Sat May 06 03:17:34 2017 Received: (at 25426) by debbugs.gnu.org; 6 May 2017 07:17:34 +0000 Received: from localhost ([127.0.0.1]:57073 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1d6tyA-0005N4-9i for submit@debbugs.gnu.org; Sat, 06 May 2017 03:17:34 -0400 Received: from eggs.gnu.org ([208.118.235.92]:52347) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1d6ty8-0005Mo-5o for 25426@debbugs.gnu.org; Sat, 06 May 2017 03:17:32 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1d6txz-0004Kr-6a for 25426@debbugs.gnu.org; Sat, 06 May 2017 03:17:27 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,RP_MATCHES_RCVD autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:46878) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1d6txz-0004Km-2k; Sat, 06 May 2017 03:17:23 -0400 Received: from 84.94.185.246.cable.012.net.il ([84.94.185.246]:1934 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1d6txy-0001uJ-2P; Sat, 06 May 2017 03:17:22 -0400 Date: Sat, 06 May 2017 10:16:58 +0300 Message-Id: <83inlefo9h.fsf@gnu.org> From: Eli Zaretskii To: Andrew Robbins In-reply-to: <87o9v6673h.fsf@andrewrobbins.info> (message from Andrew Robbins on Fri, 05 May 2017 22:40:18 -0400) Subject: Re: bug#25426: Copyright Assignment Completed References: <878tqgs7e1.fsf@andrewrobbins.info> <87o9v6673h.fsf@andrewrobbins.info> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 25426 Cc: 25426@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -5.0 (-----) > From: Andrew Robbins > Date: Fri, 05 May 2017 22:40:18 -0400 > > I completed the copyright assignment paperwork a couple of months > ago but forgot to follow-up on here afterward. > > So, uh, here's that (late) follow-up. Thanks. Would people please look at the proposed patch and comment? I will push to master in a few days if there are no comments. From debbugs-submit-bounces@debbugs.gnu.org Sat May 06 03:51:05 2017 Received: (at 25426) by debbugs.gnu.org; 6 May 2017 07:51:05 +0000 Received: from localhost ([127.0.0.1]:57092 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1d6uUb-0006Ai-2Q for submit@debbugs.gnu.org; Sat, 06 May 2017 03:51:05 -0400 Received: from eggs.gnu.org ([208.118.235.92]:56978) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1d6uUa-0006AG-0c for 25426@debbugs.gnu.org; Sat, 06 May 2017 03:51:04 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1d6uUR-0008Fy-SL for 25426@debbugs.gnu.org; Sat, 06 May 2017 03:50:58 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,RP_MATCHES_RCVD autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:47081) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1d6uUR-0008Fu-Oe; Sat, 06 May 2017 03:50:55 -0400 Received: from 84.94.185.246.cable.012.net.il ([84.94.185.246]:1978 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1d6uUR-0003DR-3N; Sat, 06 May 2017 03:50:55 -0400 Date: Sat, 06 May 2017 10:50:31 +0300 Message-Id: <83d1bmfmpk.fsf@gnu.org> From: Eli Zaretskii To: contact@andrewrobbins.info In-reply-to: <83inlefo9h.fsf@gnu.org> (message from Eli Zaretskii on Sat, 06 May 2017 10:16:58 +0300) Subject: Re: bug#25426: Copyright Assignment Completed References: <878tqgs7e1.fsf@andrewrobbins.info> <87o9v6673h.fsf@andrewrobbins.info> <83inlefo9h.fsf@gnu.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 25426 Cc: 25426@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -5.0 (-----) > Date: Sat, 06 May 2017 10:16:58 +0300 > From: Eli Zaretskii > Cc: 25426@debbugs.gnu.org > > Would people please look at the proposed patch and comment? I will > push to master in a few days if there are no comments. Some minor comments of my own: > 2017-01-12 Andrew Robbins > > * lisp/net/net-utils.el (ffap-string-at-point): Removed due to > 'net-utils-machine-at-point' obviating this autoloaded function. > (dig-program-options): New customization variable. > (nslookup-host, dns-lookup-host, run-dig): Can now specify optional > name server argument interactively (by prefix arg) & noninteractively. Please mention the bug number in the log message, for reference. > +(defcustom dig-program-options nil > + "Options for the dig program." > + :group 'net-utils > + :type '(repeat string)) When you introduce new defcustoms, please provide a :version tag whose value is the first Emacs version where this defcustom will be available (26.1 in this case). > +(defun nslookup-host (host &optional name-server) > + "Look up the DNS information for HOST (name or IP address). > +When called interactively, DNS resolver NAME-SERVER may be specified > +by passing the function a prefix argument." Our standard wording for such optional behavior is like this: Look up the DNS information for HOST (name or IP address). Optional argument NAME-SERVER says which server to use for DNS resolution. Interactively, prompt for NAME-SERVER if invoked with prefix argument. > +(defun dns-lookup-host (host &optional name-server) > + "Look up the DNS information for HOST (name or IP address). > +When called interactively, DNS resolver NAME-SERVER may be specified > +by passing the function a prefix argument." Same here. > +(defun run-dig (host &optional name-server) > + "Look up the DNS information for HOST (name or IP address). > +When called interactively, DNS resolver NAME-SERVER may be specified > +by passing the function a prefix argument." And here. Finally, please add a NEWS entry to describe these new features. Thanks for working on this. From debbugs-submit-bounces@debbugs.gnu.org Sat May 06 07:05:14 2017 Received: (at 25426) by debbugs.gnu.org; 6 May 2017 11:05:14 +0000 Received: from localhost ([127.0.0.1]:57237 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1d6xWU-0002JX-1k for submit@debbugs.gnu.org; Sat, 06 May 2017 07:05:14 -0400 Received: from aibo.runbox.com ([91.220.196.211]:54550) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1d6xWS-0002JO-HB for 25426@debbugs.gnu.org; Sat, 06 May 2017 07:05:13 -0400 Received: from [10.9.9.212] (helo=mailfront12.runbox.com) by mailtransmit03.runbox with esmtp (Exim 4.86_2) (envelope-from ) id 1d6xWR-0006Y4-70; Sat, 06 May 2017 13:05:11 +0200 Received: from linux-cryptofree1-a.xn--cdaan2d.be ([212.129.34.154] helo=wallflower) by mailfront12.runbox.com with esmtpsa (uid:855208 ) (TLS1.2:DHE_RSA_AES_128_CBC_SHA1:128) (Exim 4.82) id 1d6xWM-0003MJ-ET; Sat, 06 May 2017 13:05:06 +0200 From: Andrew Robbins To: Eli Zaretskii Subject: Re: bug#25426: Copyright Assignment Completed In-Reply-To: <83d1bmfmpk.fsf@gnu.org> (Eli Zaretskii's message of "Sat, 06 May 2017 10:50:31 +0300") References: <878tqgs7e1.fsf@andrewrobbins.info> <87o9v6673h.fsf@andrewrobbins.info> <83inlefo9h.fsf@gnu.org> <83d1bmfmpk.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Date: Sat, 06 May 2017 07:05:03 -0400 Message-ID: <87h90y5jq8.fsf@andrewrobbins.info> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 25426 Cc: 25426@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.7 (/) Eli Zaretskii writes: >> Date: Sat, 06 May 2017 10:16:58 +0300 >> From: Eli Zaretskii >> Cc: 25426@debbugs.gnu.org >> >> Would people please look at the proposed patch and comment? I will >> push to master in a few days if there are no comments. > > Some minor comments of my own: > Please mention the bug number in the log message, for reference. > >> +(defcustom dig-program-options nil >> + "Options for the dig program." >> + :group 'net-utils >> + :type '(repeat string)) > > When you introduce new defcustoms, please provide a :version tag whose > value is the first Emacs version where this defcustom will be > available (26.1 in this case). >> +(defun nslookup-host (host &optional name-server) >> + "Look up the DNS information for HOST (name or IP address). >> +When called interactively, DNS resolver NAME-SERVER may be specified >> +by passing the function a prefix argument." > > Our standard wording for such optional behavior is like this: > > Look up the DNS information for HOST (name or IP address). > Optional argument NAME-SERVER says which server to use for > DNS resolution. > Interactively, prompt for NAME-SERVER if invoked with prefix argument. > >> +(defun dns-lookup-host (host &optional name-server) > > Same here. > >> +(defun run-dig (host &optional name-server) > > And here. > Finally, please add a NEWS entry to describe these new features. > > Thanks for working on this. No problem--I'll have those changes made and posted back here within the next 24 hours. If anyone else gives additional feedback, I'll include those suggestions in the revised patch as well. 'Til then. From debbugs-submit-bounces@debbugs.gnu.org Sat May 06 08:02:37 2017 Received: (at 25426) by debbugs.gnu.org; 6 May 2017 12:02:37 +0000 Received: from localhost ([127.0.0.1]:57267 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1d6yQ0-0005UG-UT for submit@debbugs.gnu.org; Sat, 06 May 2017 08:02:37 -0400 Received: from mail-io0-f175.google.com ([209.85.223.175]:35713) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1d6yPz-0005Tz-BJ for 25426@debbugs.gnu.org; Sat, 06 May 2017 08:02:35 -0400 Received: by mail-io0-f175.google.com with SMTP id f102so28483906ioi.2 for <25426@debbugs.gnu.org>; Sat, 06 May 2017 05:02:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=hTe/FBtqCPVOY2SxMrJ2/7+TnX0TH96uQ8KAGsBIvgM=; b=RdjaSoPb3D0OlIvdIs5/D5YzlWkVE0OnCr2Hx4Atno2+EB0vSc2CbykLyzw+y5jwms Z9u2lQNHwOMMsGnrEuRmGWygW71zE+oaEok9S8+/b2ILl5w2pkJ5RufTKJxgIWsng73a 1pqQNvrFIx0vtxFXKctb+Aw2R+yUJJDet8iSG6xJmxoCZipgm6QRHqK7vFo3R8F1ZIAO x/f+DhXJ99qchqTKZhxizThFG4LEPDxN9KNBm7gB3oV87vjS93UQazmv/edNKjLZ+Uc4 kV/cKP2EAAz3DgbFzTLlbmdH+xAvlzFie7fmEqW2qC8AcveNBM4710vOaPLG0bkZ/t+M vfMw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:references:date :in-reply-to:message-id:user-agent:mime-version; bh=hTe/FBtqCPVOY2SxMrJ2/7+TnX0TH96uQ8KAGsBIvgM=; b=Rjx5oyxw6cZv3zAJfnznjGw0pcL/qukWqHkSlOKN3CfnYM+wie76NlTSfkiO24Wo2K IBC8kT5U1T3FfAc3EA2U6lV5b2N9dd2InmP99icMhMx7zvk6QumnH+XU2CIsXxJUlyi9 LkypsC9sHPP6kRHfKitxqhtZhuNZ7VoxJRdbBa7RYUOUelVLrE5ru3oTAD/j6a0T4eci E6NhYD/cGQvAtg4uNqNuuxJfvyHcAqzuOP6uP4XaNuWFKQ5HqOMQd/ygvKKsED/l5Fcd cdQreBQtz+4Ai4xUyn5E9hsCFJLnGzVcBUJ5DMaAsDum8j54c1Eu53XvI7ezHhb1flPr yfGA== X-Gm-Message-State: AN3rC/5H3v4m8yXG2/U2WyMYxb1Ly/lO5Gd0y+om02AY+iymJBXXf3Hz LjqapwcYFkBhL6hh X-Received: by 10.107.24.132 with SMTP id 126mr17960815ioy.118.1494072149458; Sat, 06 May 2017 05:02:29 -0700 (PDT) Received: from zony ([45.2.7.65]) by smtp.googlemail.com with ESMTPSA id n85sm13339213ioi.6.2017.05.06.05.02.28 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Sat, 06 May 2017 05:02:28 -0700 (PDT) From: npostavs@users.sourceforge.net To: Andrew Robbins Subject: Re: bug#25426: [PATCH] in net-utils.el several DNS query functions now take optional name server argument; also, `dig-program-options' added References: <878tqgs7e1.fsf@andrewrobbins.info> Date: Sat, 06 May 2017 08:04:01 -0400 In-Reply-To: <878tqgs7e1.fsf@andrewrobbins.info> (Andrew Robbins's message of "Thu, 12 Jan 2017 09:03:02 -0500") Message-ID: <871ss2mbta.fsf@users.sourceforge.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.1 (--) X-Debbugs-Envelope-To: 25426 Cc: 25426@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.1 (--) Andrew Robbins writes: > - (list (read-from-minibuffer "Lookup host: " (net-utils-machine-at-point)))) > + (if current-prefix-arg > + (list > + (read-from-minibuffer "Look up host: " (net-utils-machine-at-point)) > + (read-from-minibuffer "Name server: ")) > + (list > + (read-from-minibuffer "Look up host: " (net-utils-machine-at-point))))) You could avoid repeating the "Look up host" code like this: (list (read-from-minibuffer "Look up host: " (net-utils-machine-at-point)) (if current-prefix-arg (read-from-minibuffer "Name server: "))) > - (if nslookup-program-options > - (append nslookup-program-options (list host)) > - (list host)))) > + (if name-server > + (append nslookup-program-options (list host name-server)) > + (append nslookup-program-options (list host))))) Similarly (append nslookup-program-options (list host) (if name-sever (list name-server))) > - (mapconcat 'identity > - (list "Nslookup" host nslookup-program) > - " ** ")) > + (mapconcat 'identity > + (list "Nslookup" host nslookup-program) > + " ** ")) This is just a whitespace change, right? Same comments again for dns-lookup-host and run-dig changes. From debbugs-submit-bounces@debbugs.gnu.org Sun May 07 04:03:01 2017 Received: (at 25426) by debbugs.gnu.org; 7 May 2017 08:03:01 +0000 Received: from localhost ([127.0.0.1]:59002 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1d7H9h-0002d3-39 for submit@debbugs.gnu.org; Sun, 07 May 2017 04:03:01 -0400 Received: from aibo.runbox.com ([91.220.196.211]:39626) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1d7H9e-0002ct-VQ for 25426@debbugs.gnu.org; Sun, 07 May 2017 04:02:59 -0400 Received: from [10.9.9.210] (helo=mailfront10.runbox.com) by mailtransmit03.runbox with esmtp (Exim 4.86_2) (envelope-from ) id 1d7H9d-0002lp-1w; Sun, 07 May 2017 10:02:57 +0200 Received: from linux-cryptofree1-a.xn--cdaan2d.be ([212.129.34.154] helo=wallflower) by mailfront10.runbox.com with esmtpsa (uid:855208 ) (TLS1.2:DHE_RSA_AES_128_CBC_SHA1:128) (Exim 4.82) id 1d7H9V-00073o-Kw; Sun, 07 May 2017 10:02:49 +0200 From: Andrew Robbins To: npostavs@users.sourceforge.net Subject: Re: bug#25426: [PATCH] in net-utils.el several DNS query functions now take optional name server argument; also, `dig-program-options' added In-Reply-To: <871ss2mbta.fsf@users.sourceforge.net> (npostavs@users.sourceforge.net's message of "Sat, 06 May 2017 08:04:01 -0400") References: <878tqgs7e1.fsf@andrewrobbins.info> <871ss2mbta.fsf@users.sourceforge.net> User-Agent: Gnus/5.13 (Gnus v5.13) Date: Sun, 07 May 2017 04:02:47 -0400 Message-ID: <87a86p5c2g.fsf@andrewrobbins.info> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 25426 Cc: 25426@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.7 (/) npostavs@users.sourceforge.net writes: > You could avoid repeating the "Look up host" code like this: > > (list (read-from-minibuffer "Look up host: " (net-utils-machine-at-point)) > (if current-prefix-arg (read-from-minibuffer "Name server: "))) Nice. I thought it looked a bit weird when I wrote that bit, but your simplification is better. > Similarly > > (append nslookup-program-options (list host) > (if name-sever (list name-server))) Same as above. >> - (mapconcat 'identity >> - (list "Nslookup" host nslookup-program) >> - " ** ")) >> + (mapconcat 'identity >> + (list "Nslookup" host nslookup-program) >> + " ** ")) > > This is just a whitespace change, right? Yes. I dropped the whitespace changes in this newest patch. From debbugs-submit-bounces@debbugs.gnu.org Sun May 07 04:36:49 2017 Received: (at 25426) by debbugs.gnu.org; 7 May 2017 08:36:49 +0000 Received: from localhost ([127.0.0.1]:59022 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1d7HgD-0003Ol-Uc for submit@debbugs.gnu.org; Sun, 07 May 2017 04:36:49 -0400 Received: from aibo.runbox.com ([91.220.196.211]:56902) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1d7Hg9-0003Oa-3z for 25426@debbugs.gnu.org; Sun, 07 May 2017 04:36:36 -0400 Received: from [10.9.9.211] (helo=mailfront11.runbox.com) by mailtransmit02.runbox with esmtp (Exim 4.86_2) (envelope-from ) id 1d7Hg4-0003Vu-Uz for 25426@debbugs.gnu.org; Sun, 07 May 2017 10:36:29 +0200 Received: from linux-cryptofree1-a.xn--cdaan2d.be ([212.129.34.154] helo=wallflower) by mailfront11.runbox.com with esmtpsa (uid:855208 ) (TLS1.2:DHE_RSA_AES_128_CBC_SHA1:128) (Exim 4.82) id 1d7Hfz-0007sW-Cz for 25426@debbugs.gnu.org; Sun, 07 May 2017 10:36:24 +0200 From: Andrew Robbins To: 25426@debbugs.gnu.org Subject: [PATCH] 26.1; Revised patch for bug#25426 User-Agent: Gnus/5.13 (Gnus v5.13) Date: Sun, 07 May 2017 04:36:21 -0400 Message-ID: <87vapd3vy2.fsf@andrewrobbins.info> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 25426 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.0 (/) --=-=-= Content-Type: text/plain Attached are the diffs for 'NEWS', 'ChangeLog', and 'net-utils.el'. I tested these again after revision, so the new functions and user-option should work being merged in as-is. If there's anything else that needs changing, let me know. The NEWS entry in particular may or may not be complete since I'm not really sure if it needs the '---' or '+++' (and manual entry). Thanks --=-=-= Content-Type: text/x-diff Content-Disposition: attachment; filename=ChangeLog 2017-05-07 Andrew Robbins * lisp/net/net-utils.el (ffap-string-at-point): Removed due to 'net-utils-machine-at-point' obviating this autoloaded function (Bug#25426). (dig-program-options): New customization variable. (nslookup-host, dns-lookup-host, run-dig): Can now specify optional name server argument interactively (by prefix arg) & non-interactively. --=-=-= Content-Type: text/x-diff Content-Disposition: attachment; filename=net-utils.el.NEW ;;; net-utils.el --- network functions ;; Copyright (C) 1998-2017 Free Software Foundation, Inc. ;; Author: Peter Breton ;; Created: Sun Mar 16 1997 ;; Keywords: network comm ;; This file is part of GNU Emacs. ;; GNU Emacs is free software: you can redistribute it and/or modify ;; it under the terms of the GNU General Public License as published by ;; the Free Software Foundation, either version 3 of the License, or ;; (at your option) any later version. ;; GNU Emacs is distributed in the hope that it will be useful, ;; but WITHOUT ANY WARRANTY; without even the implied warranty of ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ;; GNU General Public License for more details. ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs. If not, see . ;;; Commentary: ;; ;; There are three main areas of functionality: ;; ;; * Wrap common network utility programs (ping, traceroute, netstat, ;; nslookup, arp, route). Note that these wrappers are of the diagnostic ;; functions of these programs only. ;; ;; * Implement some very basic protocols in Emacs Lisp (finger and whois) ;; ;; * Support connections to HOST/PORT, generally for debugging and the like. ;; In other words, for doing much the same thing as "telnet HOST PORT", and ;; then typing commands. ;;; Code: ;; On some systems, programs like ifconfig are not in normal user ;; path, but rather in /sbin, /usr/sbin, etc (but non-root users can ;; still use them for queries). Actually the trend these ;; days is for /sbin to be a symlink to /usr/sbin, but we still need to ;; search both for older systems. (defun net-utils--executable-find-sbin (command) "Return absolute name of COMMAND if found in an sbin directory." (let ((exec-path '("/sbin" "/usr/sbin" "/usr/local/sbin"))) (executable-find command))) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; Customization Variables ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; (defgroup net-utils nil "Network utility functions." :prefix "net-utils-" :group 'comm :version "20.3") (defcustom traceroute-program (if (eq system-type 'windows-nt) "tracert" "traceroute") "Program to trace network hops to a destination." :group 'net-utils :type 'string) (defcustom traceroute-program-options nil "Options for the traceroute program." :group 'net-utils :type '(repeat string)) (defcustom ping-program "ping" "Program to send network test packets to a host." :group 'net-utils :type 'string) ;; On GNU/Linux and Irix, the system's ping program seems to send packets ;; indefinitely unless told otherwise (defcustom ping-program-options (and (eq system-type 'gnu/linux) (list "-c" "4")) "Options for the ping program. These options can be used to limit how many ICMP packets are emitted." :group 'net-utils :type '(repeat string)) (define-obsolete-variable-alias 'ipconfig-program 'ifconfig-program "22.2") (defcustom ifconfig-program (cond ((eq system-type 'windows-nt) "ipconfig") ((executable-find "ifconfig") "ifconfig") ((net-utils--executable-find-sbin "ifconfig")) ((net-utils--executable-find-sbin "ip")) (t "ip")) "Program to print network configuration information." :version "25.1" ; add ip :group 'net-utils :type 'string) (define-obsolete-variable-alias 'ipconfig-program-options 'ifconfig-program-options "22.2") (defcustom ifconfig-program-options (cond ((string-match "ipconfig\\'" ifconfig-program) '("/all")) ((string-match "ifconfig\\'" ifconfig-program) '("-a")) ((string-match "ip\\'" ifconfig-program) '("addr"))) "Options for the ifconfig program." :version "25.1" :set-after '(ifconfig-program) :group 'net-utils :type '(repeat string)) (defcustom iwconfig-program (cond ((executable-find "iwconfig") "iwconfig") ((net-utils--executable-find-sbin "iw") "iw") (t "iw")) "Program to print wireless network configuration information." :group 'net-utils :type 'string :version "26.1") (defcustom iwconfig-program-options (cond ((string-match-p "iw\\'" iwconfig-program) (list "dev")) (t nil)) "Options for the iwconfig program." :group 'net-utils :type '(repeat string) :version "26.1") (defcustom netstat-program (cond ((executable-find "netstat") "netstat") ((net-utils--executable-find-sbin "ss")) (t "ss")) "Program to print network statistics." :group 'net-utils :type 'string :version "26.1") (defcustom netstat-program-options (list "-a") "Options for the netstat program." :group 'net-utils :type '(repeat string)) (defcustom arp-program (or (net-utils--executable-find-sbin "arp") "arp") "Program to print IP to address translation tables." :group 'net-utils :type 'string) (defcustom arp-program-options (list "-a") "Options for the arp program." :group 'net-utils :type '(repeat string)) (defcustom route-program (cond ((eq system-type 'windows-nt) "route") ((executable-find "netstat") "netstat") ((net-utils--executable-find-sbin "netstat")) ((executable-find "ip") "ip") ((net-utils--executable-find-sbin "ip")) (t "ip")) "Program to print routing tables." :group 'net-utils :type 'string :version "26.1") (defcustom route-program-options (cond ((eq system-type 'windows-nt) (list "print")) ((string-match-p "netstat\\'" route-program) (list "-r")) (t (list "route"))) "Options for the route program." :group 'net-utils :type '(repeat string) :version "26.1") (defcustom nslookup-program "nslookup" "Program to interactively query DNS information." :group 'net-utils :type 'string) (defcustom nslookup-program-options nil "Options for the nslookup program." :group 'net-utils :type '(repeat string)) (defcustom nslookup-prompt-regexp "^> " "Regexp to match the nslookup prompt. This variable is only used if the variable `comint-use-prompt-regexp' is non-nil." :group 'net-utils :type 'regexp) (defcustom dig-program "dig" "Program to query DNS information." :group 'net-utils :type 'string) (defcustom dig-program-options nil "Options for the dig program." :group 'net-utils :type '(repeat string) :version "26.1") (defcustom ftp-program "ftp" "Program to run to do FTP transfers." :group 'net-utils :type 'string) (defcustom ftp-program-options nil "Options for the ftp program." :group 'net-utils :type '(repeat string)) (defcustom ftp-prompt-regexp "^ftp>" "Regexp which matches the FTP program's prompt. This variable is only used if the variable `comint-use-prompt-regexp' is non-nil." :group 'net-utils :type 'regexp) (defcustom smbclient-program "smbclient" "Smbclient program." :group 'net-utils :type 'string) (defcustom smbclient-program-options nil "Options for the smbclient program." :group 'net-utils :type '(repeat string)) (defcustom smbclient-prompt-regexp "^smb: >" "Regexp which matches the smbclient program's prompt. This variable is only used if the variable `comint-use-prompt-regexp' is non-nil." :group 'net-utils :type 'regexp) (defcustom dns-lookup-program "host" "Program to interactively query DNS information." :group 'net-utils :type 'string) (defcustom dns-lookup-program-options nil "Options for the dns-lookup program." :group 'net-utils :type '(repeat string)) ;; Internal variables (defvar network-connection-service nil) (defvar network-connection-host nil) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; Nslookup goodies ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; (defvar nslookup-font-lock-keywords (list (list "^[A-Za-z0-9 _]+:" 0 'font-lock-type-face) (list "\\<\\(SOA\\|NS\\|MX\\|A\\|CNAME\\)\\>" 1 'font-lock-keyword-face) ;; Dotted quads (list (mapconcat 'identity (make-list 4 "[0-9]+") "\\.") 0 'font-lock-variable-name-face) ;; Host names (list (let ((host-expression "[-A-Za-z0-9]+")) (concat (mapconcat 'identity (make-list 2 host-expression) "\\.") "\\(\\." host-expression "\\)*")) 0 'font-lock-variable-name-face)) "Expressions to font-lock for nslookup.") ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; General network utilities mode ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; (defvar net-utils-font-lock-keywords (list ;; Dotted quads (list (mapconcat 'identity (make-list 4 "[0-9]+") "\\.") 0 'font-lock-variable-name-face) ;; Simple rfc4291 addresses (list (concat "\\( \\([[:xdigit:]]+\\(:\\|::\\)\\)+[[:xdigit:]]+\\)" "\\|" "\\(::[[:xdigit:]]+\\)") 0 'font-lock-variable-name-face) ;; Host names (list (let ((host-expression "[-A-Za-z0-9]+")) (concat (mapconcat 'identity (make-list 2 host-expression) "\\.") "\\(\\." host-expression "\\)*")) 0 'font-lock-variable-name-face)) "Expressions to font-lock for general network utilities.") (define-derived-mode net-utils-mode special-mode "NetworkUtil" "Major mode for interacting with an external network utility." (set (make-local-variable 'font-lock-defaults) '((net-utils-font-lock-keywords))) (setq-local revert-buffer-function #'net-utils--revert-function)) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; Utility functions ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; Simplified versions of some at-point functions from ffap.el. ;; It's not worth loading all of ffap just for these. (defun net-utils-machine-at-point () (let ((pt (point))) (buffer-substring-no-properties (save-excursion (skip-chars-backward "-a-zA-Z0-9.") (point)) (save-excursion (skip-chars-forward "-a-zA-Z0-9.") (skip-chars-backward "." pt) (point))))) (defun net-utils-url-at-point () (let ((pt (point))) (buffer-substring-no-properties (save-excursion (skip-chars-backward "--:=&?$+@-Z_a-z~#,%") (skip-chars-forward "^A-Za-z0-9" pt) (point)) (save-excursion (skip-chars-forward "--:=&?$+@-Z_a-z~#,%") (skip-chars-backward ":;.,!?" pt) (point))))) (defun net-utils-remove-ctrl-m-filter (process output-string) "Remove trailing control Ms." (with-current-buffer (process-buffer process) (save-excursion (let ((inhibit-read-only t) (filtered-string output-string)) (while (string-match "\r" filtered-string) (setq filtered-string (replace-match "" nil nil filtered-string))) ;; Insert the text, moving the process-marker. (goto-char (process-mark process)) (insert filtered-string) (set-marker (process-mark process) (point)))))) (declare-function w32-get-console-output-codepage "w32proc.c" ()) (defun net-utils-run-program (name header program args) "Run a network information program." (let ((buf (get-buffer-create (concat "*" name "*"))) (coding-system-for-read ;; MS-Windows versions of network utilities output text ;; encoded in the console (a.k.a. "OEM") codepage, which is ;; different from the default system (a.k.a. "ANSI") ;; codepage. (if (eq system-type 'windows-nt) (intern (format "cp%d" (w32-get-console-output-codepage))) coding-system-for-read))) (set-buffer buf) (erase-buffer) (insert header "\n") (set-process-filter (apply 'start-process name buf program args) 'net-utils-remove-ctrl-m-filter) (display-buffer buf) buf)) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; General network utilities (diagnostic) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; Todo: This data could be saved in a bookmark. (defvar net-utils--revert-cmd nil) (defun net-utils-run-simple (buffer program-name args &optional nodisplay) "Run a network utility for diagnostic output only." (with-current-buffer (if (stringp buffer) (get-buffer-create buffer) buffer) (let ((proc (get-buffer-process (current-buffer)))) (when proc (set-process-filter proc nil) (delete-process proc))) (let ((inhibit-read-only t) (coding-system-for-read ;; MS-Windows versions of network utilities output text ;; encoded in the console (a.k.a. "OEM") codepage, which is ;; different from the default system (a.k.a. "ANSI") ;; codepage. (if (eq system-type 'windows-nt) (intern (format "cp%d" (w32-get-console-output-codepage))) coding-system-for-read))) (erase-buffer)) (net-utils-mode) (setq-local net-utils--revert-cmd `(net-utils-run-simple ,(current-buffer) ,program-name ,args nodisplay)) (set-process-filter (apply 'start-process program-name (current-buffer) program-name args) 'net-utils-remove-ctrl-m-filter) (unless nodisplay (display-buffer (current-buffer))))) (defun net-utils--revert-function (&optional ignore-auto noconfirm) (message "Reverting `%s'..." (buffer-name)) (apply (car net-utils--revert-cmd) (cdr net-utils--revert-cmd)) (let ((proc (get-buffer-process (current-buffer)))) (when proc (set-process-sentinel proc (lambda (process event) (when (string= event "finished\n") (message "Reverting `%s' done" (process-buffer process)))))))) ;;;###autoload (defun ifconfig () "Run ifconfig and display diagnostic output." (interactive) (net-utils-run-simple (format "*%s*" ifconfig-program) ifconfig-program ifconfig-program-options)) (defalias 'ipconfig 'ifconfig) ;;;###autoload (defun iwconfig () "Run iwconfig and display diagnostic output." (interactive) (net-utils-run-simple (format "*%s*" iwconfig-program) iwconfig-program iwconfig-program-options)) ;;;###autoload (defun netstat () "Run netstat and display diagnostic output." (interactive) (net-utils-run-simple (format "*%s*" netstat-program) netstat-program netstat-program-options)) ;;;###autoload (defun arp () "Run arp and display diagnostic output." (interactive) (net-utils-run-simple (format "*%s*" arp-program) arp-program arp-program-options)) ;;;###autoload (defun route () "Run route and display diagnostic output." (interactive) (net-utils-run-simple (format "*%s*" route-program) route-program route-program-options)) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; Wrappers for external network programs ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;###autoload (defun traceroute (target) "Run traceroute program for TARGET." (interactive "sTarget: ") (let ((options (if traceroute-program-options (append traceroute-program-options (list target)) (list target)))) (net-utils-run-simple (concat "Traceroute" " " target) traceroute-program options))) ;;;###autoload (defun ping (host) "Ping HOST. If your system's ping continues until interrupted, you can try setting `ping-program-options'." (interactive (list (read-from-minibuffer "Ping host: " (net-utils-machine-at-point)))) (let ((options (if ping-program-options (append ping-program-options (list host)) (list host)))) (net-utils-run-program (concat "Ping" " " host) (concat "** Ping ** " ping-program " ** " host) ping-program options))) ;; FIXME -- Needs to be a process filter ;; (defun netstat-with-filter (filter) ;; "Run netstat program." ;; (interactive "sFilter: ") ;; (netstat) ;; (set-buffer (get-buffer "*Netstat*")) ;; (goto-char (point-min)) ;; (delete-matching-lines filter)) ;;;###autoload (defun nslookup-host (host &optional name-server) "Look up the DNS information for HOST (name or IP address). Optional argument NAME-SERVER says which server to use for DNS resolution. Interactively, prompt for NAME-SERVER if invoked with prefix argument." (interactive (list (read-from-minibuffer "Lookup host: " (net-utils-machine-at-point)) (if current-prefix-arg (read-from-minibuffer "Name server: ")))) (let ((options (append nslookup-program-options (list host) (if name-server (list name-server))))) (net-utils-run-program "Nslookup" (concat "** " (mapconcat 'identity (list "Nslookup" host nslookup-program) " ** ")) nslookup-program options))) ;;;###autoload (defun nslookup () "Run nslookup program." (interactive) (switch-to-buffer (make-comint "nslookup" nslookup-program)) (nslookup-mode)) (defvar comint-prompt-regexp) (defvar comint-input-autoexpand) (autoload 'comint-mode "comint" nil t) (defvar nslookup-mode-map (let ((map (make-sparse-keymap))) (define-key map "\t" 'completion-at-point) map)) ;; Using a derived mode gives us keymaps, hooks, etc. (define-derived-mode nslookup-mode comint-mode "Nslookup" "Major mode for interacting with the nslookup program." (set (make-local-variable 'font-lock-defaults) '((nslookup-font-lock-keywords))) (setq comint-prompt-regexp nslookup-prompt-regexp) (setq comint-input-autoexpand t)) ;;;###autoload (defun dns-lookup-host (host &optional name-server) "Look up the DNS information for HOST (name or IP address). Optional argument NAME-SERVER says which server to use for DNS resolution. Interactively, prompt for NAME-SERVER if invoked with prefix argument." (interactive (list (read-from-minibuffer "Lookup host: " (net-utils-machine-at-point)) (if current-prefix-arg (read-from-minibuffer "Name server: ")))) (let ((options (append dns-lookup-program-options (list host) (if name-server (list name-server))))) (net-utils-run-program (concat "DNS Lookup [" host "]") (concat "** " (mapconcat 'identity (list "DNS Lookup" host dns-lookup-program) " ** ")) dns-lookup-program options))) ;;;###autoload (defun run-dig (host &optional name-server) "Look up the DNS information for HOST (name or IP address). Optional argument NAME-SERVER says which server to use for DNS resolution. Interactively, prompt for NAME-SERVER if invoked with prefix argument." (interactive (list (read-from-minibuffer "Lookup host: " (net-utils-machine-at-point)) (if current-prefix-arg (read-from-minibuffer "Name server: ")))) (let ((options (append dig-program-options (list host) (if name-server (list (concat "@" name-server)))))) (net-utils-run-program "Dig" (concat "** " (mapconcat 'identity (list "Dig" host dig-program) " ** ")) dig-program options))) (autoload 'comint-exec "comint") ;; This is a lot less than ange-ftp, but much simpler. ;;;###autoload (defun ftp (host) "Run ftp program." (interactive (list (read-from-minibuffer "Ftp to Host: " (net-utils-machine-at-point)))) (let ((buf (get-buffer-create (concat "*ftp [" host "]*")))) (set-buffer buf) (ftp-mode) (comint-exec buf (concat "ftp-" host) ftp-program nil (if ftp-program-options (append (list host) ftp-program-options) (list host))) (pop-to-buffer buf))) (defvar ftp-mode-map (let ((map (make-sparse-keymap))) ;; Occasionally useful (define-key map "\t" 'completion-at-point) map)) (define-derived-mode ftp-mode comint-mode "FTP" "Major mode for interacting with the ftp program." (setq comint-prompt-regexp ftp-prompt-regexp) (setq comint-input-autoexpand t) ;; Only add the password-prompting hook if it's not already in the ;; global hook list. This stands a small chance of losing, if it's ;; later removed from the global list (very small, since any ;; password prompts will probably immediately follow the initial ;; connection), but it's better than getting prompted twice for the ;; same password. (unless (memq 'comint-watch-for-password-prompt (default-value 'comint-output-filter-functions)) (add-hook 'comint-output-filter-functions 'comint-watch-for-password-prompt nil t))) (defun smbclient (host service) "Connect to SERVICE on HOST via SMB." (interactive (list (read-from-minibuffer "Connect to Host: " (net-utils-machine-at-point)) (read-from-minibuffer "SMB Service: "))) (let* ((name (format "smbclient [%s\\%s]" host service)) (buf (get-buffer-create (concat "*" name "*"))) (service-name (concat "\\\\" host "\\" service))) (set-buffer buf) (smbclient-mode) (comint-exec buf name smbclient-program nil (if smbclient-program-options (append (list service-name) smbclient-program-options) (list service-name))) (pop-to-buffer buf))) (defun smbclient-list-shares (host) "List services on HOST." (interactive (list (read-from-minibuffer "Connect to Host: " (net-utils-machine-at-point)))) (let ((buf (get-buffer-create (format "*SMB Shares on %s*" host)))) (set-buffer buf) (smbclient-mode) (comint-exec buf "smbclient-list-shares" smbclient-program nil (list "-L" host)) (pop-to-buffer buf))) (define-derived-mode smbclient-mode comint-mode "smbclient" "Major mode for interacting with the smbclient program." (setq comint-prompt-regexp smbclient-prompt-regexp) (setq comint-input-autoexpand t) ;; Only add the password-prompting hook if it's not already in the ;; global hook list. This stands a small chance of losing, if it's ;; later removed from the global list (very small, since any ;; password prompts will probably immediately follow the initial ;; connection), but it's better than getting prompted twice for the ;; same password. (unless (memq 'comint-watch-for-password-prompt (default-value 'comint-output-filter-functions)) (add-hook 'comint-output-filter-functions 'comint-watch-for-password-prompt nil t))) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; Network Connections ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; Full list is available at: ;; http://www.iana.org/assignments/port-numbers (defvar network-connection-service-alist (list (cons 'echo 7) (cons 'active-users 11) (cons 'daytime 13) (cons 'chargen 19) (cons 'ftp 21) (cons 'telnet 23) (cons 'smtp 25) (cons 'time 37) (cons 'whois 43) (cons 'gopher 70) (cons 'finger 79) (cons 'www 80) (cons 'pop2 109) (cons 'pop3 110) (cons 'sun-rpc 111) (cons 'nntp 119) (cons 'ntp 123) (cons 'netbios-name 137) (cons 'netbios-data 139) (cons 'irc 194) (cons 'https 443) (cons 'rlogin 513)) "Alist of services and associated TCP port numbers. This list is not complete.") ;; Workhorse routine (defun run-network-program (process-name host port &optional initial-string) (let ((tcp-connection) (buf)) (setq buf (get-buffer-create (concat "*" process-name "*"))) (set-buffer buf) (or (setq tcp-connection (open-network-stream process-name buf host port)) (error "Could not open connection to %s" host)) (erase-buffer) (set-marker (process-mark tcp-connection) (point-min)) (set-process-filter tcp-connection 'net-utils-remove-ctrl-m-filter) (and initial-string (process-send-string tcp-connection (concat initial-string "\r\n"))) (display-buffer buf))) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; Simple protocols ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; (defcustom finger-X.500-host-regexps nil "A list of regular expressions matching host names. If a host name passed to `finger' matches one of these regular expressions, it is assumed to be a host that doesn't accept queries of the form USER@HOST, and wants a query containing USER only." :group 'net-utils :type '(repeat regexp) :version "21.1") ;; Finger protocol ;;;###autoload (defun finger (user host) "Finger USER on HOST." ;; One of those great interactive statements that's actually ;; longer than the function call! The idea is that if the user ;; uses a string like "pbreton@cs.umb.edu", we won't ask for the ;; host name. If we don't see an "@", we'll prompt for the host. (interactive (let* ((answer (read-from-minibuffer "Finger User: " (net-utils-url-at-point))) (index (string-match (regexp-quote "@") answer))) (if index (list (substring answer 0 index) (substring answer (1+ index))) (list answer (read-from-minibuffer "At Host: " (net-utils-machine-at-point)))))) (let* ((user-and-host (concat user "@" host)) (process-name (concat "Finger [" user-and-host "]")) (regexps finger-X.500-host-regexps) found) (and regexps (while (not (string-match (car regexps) host)) (setq regexps (cdr regexps))) (when regexps (setq user-and-host user))) (run-network-program process-name host (cdr (assoc 'finger network-connection-service-alist)) user-and-host))) (defcustom whois-server-name "rs.internic.net" "Default host name for the whois service." :group 'net-utils :type 'string) (defcustom whois-server-list '(("whois.arin.net") ; Networks, ASN's, and related POC's (numbers) ("rs.internic.net") ; domain related info ("whois.publicinterestregistry.net") ("whois.abuse.net") ("whois.apnic.net") ("nic.ddn.mil") ("whois.nic.mil") ("whois.nic.gov") ("whois.ripe.net")) "A list of whois servers that can be queried." :group 'net-utils :type '(repeat (list string))) ;; FIXME: modern whois clients include a much better tld <-> whois server ;; list, Emacs should probably avoid specifying the server as the client ;; will DTRT anyway... -rfr (defcustom whois-server-tld '(("rs.internic.net" . "com") ("whois.publicinterestregistry.net" . "org") ("whois.ripe.net" . "be") ("whois.ripe.net" . "de") ("whois.ripe.net" . "dk") ("whois.ripe.net" . "it") ("whois.ripe.net" . "fi") ("whois.ripe.net" . "fr") ("whois.ripe.net" . "uk") ("whois.apnic.net" . "au") ("whois.apnic.net" . "ch") ("whois.apnic.net" . "hk") ("whois.apnic.net" . "jp") ("whois.nic.gov" . "gov") ("whois.nic.mil" . "mil")) "Alist to map top level domains to whois servers." :group 'net-utils :type '(repeat (cons string string))) (defcustom whois-guess-server t "If non-nil then whois will try to deduce the appropriate whois server from the query. If the query doesn't look like a domain or hostname then the server named by `whois-server-name' is used." :group 'net-utils :type 'boolean) (defun whois-get-tld (host) "Return the top level domain of `host', or nil if it isn't a domain name." (let ((i (1- (length host))) (max-len (- (length host) 5))) (while (not (or (= i max-len) (char-equal (aref host i) ?.))) (setq i (1- i))) (if (= i max-len) nil (substring host (1+ i))))) ;; Whois protocol ;;;###autoload (defun whois (arg search-string) "Send SEARCH-STRING to server defined by the `whois-server-name' variable. If `whois-guess-server' is non-nil, then try to deduce the correct server from SEARCH-STRING. With argument, prompt for whois server." (interactive "P\nsWhois: ") (let* ((whois-apropos-host (if whois-guess-server (rassoc (whois-get-tld search-string) whois-server-tld) nil)) (server-name (if whois-apropos-host (car whois-apropos-host) whois-server-name)) (host (if arg (completing-read "Whois server name: " whois-server-list nil nil "whois.") server-name))) (run-network-program "Whois" host (cdr (assoc 'whois network-connection-service-alist)) search-string))) (defcustom whois-reverse-lookup-server "whois.arin.net" "Server which provides inverse DNS mapping." :group 'net-utils :type 'string) ;;;###autoload (defun whois-reverse-lookup () (interactive) (let ((whois-server-name whois-reverse-lookup-server)) (call-interactively 'whois))) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;; General Network connection ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; Using a derived mode gives us keymaps, hooks, etc. (define-derived-mode network-connection-mode comint-mode "Network-Connection" "Major mode for interacting with the network-connection program.") (defun network-connection-mode-setup (host service) (make-local-variable 'network-connection-host) (setq network-connection-host host) (make-local-variable 'network-connection-service) (setq network-connection-service service)) ;;;###autoload (defun network-connection-to-service (host service) "Open a network connection to SERVICE on HOST." (interactive (list (read-from-minibuffer "Host: " (net-utils-machine-at-point)) (completing-read "Service: " (mapcar (function (lambda (elt) (list (symbol-name (car elt))))) network-connection-service-alist)))) (network-connection host (cdr (assoc (intern service) network-connection-service-alist)))) ;;;###autoload (defun network-connection (host port) "Open a network connection to HOST on PORT." (interactive "sHost: \nnPort: ") (network-service-connection host (number-to-string port))) (defun network-service-connection (host service) "Open a network connection to SERVICE on HOST." (let* ((process-name (concat "Network Connection [" host " " service "]")) (portnum (string-to-number service)) (buf (get-buffer-create (concat "*" process-name "*")))) (or (zerop portnum) (setq service portnum)) (make-comint process-name (cons host service)) (set-buffer buf) (network-connection-mode) (network-connection-mode-setup host service) (pop-to-buffer buf))) (defvar comint-input-ring) (defun network-connection-reconnect () "Reconnect a network connection, preserving the old input ring." (interactive) (let ((proc (get-buffer-process (current-buffer))) (old-comint-input-ring comint-input-ring) (host network-connection-host) (service network-connection-service)) (if (not (or (not proc) (eq (process-status proc) 'closed))) (message "Still connected") (goto-char (point-max)) (insert (format "Reopening connection to %s\n" host)) (network-connection host (if (numberp service) service (cdr (assoc service network-connection-service-alist)))) (and old-comint-input-ring (setq comint-input-ring old-comint-input-ring))))) (provide 'net-utils) ;;; net-utils.el ends here --=-=-= Content-Type: text/x-diff; charset=utf-8 Content-Disposition: attachment; filename=NEWS Content-Transfer-Encoding: quoted-printable GNU Emacs NEWS -- history of user-visible changes. Copyright (C) 2014-2017 Free Software Foundation, Inc. See the end of the file for license conditions. Please send Emacs bug reports to bug-gnu-emacs@gnu.org. If possible, use M-x report-emacs-bug. This file is about changes in Emacs version 26. See file HISTORY for a list of GNU Emacs versions and release dates. See files NEWS.25, NEWS.24, NEWS.23, NEWS.22, NEWS.21, NEWS.20, NEWS.19, NEWS.18, and NEWS.1-17 for changes in older Emacs versions. You can narrow news to a specific version by calling 'view-emacs-news' with a prefix argument or by typing C-u C-h C-n. Temporary note: +++ indicates that all necessary documentation updates are complete. (This means all relevant manuals in doc/ AND lisp doc-strings.) --- means no change in the manuals is needed. When you add a new item, use the appropriate mark if you are sure it applie= s, * Installation Changes in Emacs 26.1 ** By default libgnutls is now required when building Emacs. Use 'configure --with-gnutls=3Dno' to build even when GnuTLS is missing. ** GnuTLS version 2.12.2 or later is now required, instead of merely version 2.6.6 or later. ** The new option 'configure --with-mailutils' causes Emacs to rely on GNU Mailutils 'movemail' to retrieve email. By default, the Emacs build procedure continues to build and install a limited and insecure 'movemail' substitute. Although --with-mailutils is recommended, it is not yet the default due to backward-compatibility concerns. ** The new option 'configure --enable-gcc-warnings=3Dwarn-only' causes GCC to issue warnings without stopping the build. This behavior is now the default in developer builds. As before, use '--disable-gcc-warnings' to suppress GCC's warnings, and '--enable-gcc-warnings' to stop the build if GCC issues warnings. ** When GCC warnings are enabled, '--enable-check-lisp-object-type' is now enabled by default when configuring. +++ ** The Emacs server now has socket-launching support. This allows socket based activation, where an external process like systemd can invoke the Emacs server process upon a socket connection event and hand the socket over to Emacs. Emacs uses this socket to service emacsclient commands. This new functionality can be disabled with the configure option '--disable-libsystemd'. +++ ** A systemd user unit file is provided. Use it in the standard way: systemctl --user enable emacs (If your Emacs is installed in a non-standard location, you may need to copy the emacs.service file to eg ~/.config/systemd/user/) ** New configure option '--disable-build-details' attempts to build an Emacs that is more likely to be reproducible; that is, if you build and install Emacs twice, the second Emacs is a copy of the first. Deterministic builds omit the build date from the output of the emacs-version and erc-cmd-SV functions, and the leave the following variables nil: emacs-build-system, emacs-build-time, erc-emacs-build-time. ** The configure option '--with-gameuser' now defaults to 'no', as this appears to be the most common configuration in practice. When it is 'no', the shared game directory and the auxiliary program update-game-score are no longer needed and are not installed. ** Emacs no longer works on IRIX. We expect that Emacs users are not affected by this, as SGI stopped supporting IRIX in December 2013. * Startup Changes in Emacs 26.1 ** New option '--new-daemon'. This is the same as '--daemon', except it runs in the foreground and does not fork. This is intended for modern init systems such as systemd, which manage many of the traditional aspects of daemon behavior themselves. '--old-daemon' is now an alias for '--daemon'. +++ ** Emacs now supports 24-bit colors on capable text terminals Terminal is automatically initialized to use 24-bit colors if the required capabilities are found in terminfo. See the FAQ node "Colors on a TTY" for more information. * Changes in Emacs 26.1 +++ ** The functions write-region, append-to-file, and the like now also output the number of characters added in addition to the name of the file affected, if the new variable 'write-region-verbose' is non-nil. ** The variable 'emacs-version' no longer includes the build number. This is now stored separately in a new variable, 'emacs-build-number'. +++ ** The new function 'mapbacktrace' applies a function to all frames of the current stack trace. +++ ** Emacs now provides a limited form of concurrency with Lisp threads. Concurrency in Emacs Lisp is "mostly cooperative", meaning that Emacs will only switch execution between threads at well-defined times: when Emacs waits for input, during blocking operations related to threads (such as mutex locking), or when the current thread explicitly yields. Global variables are shared among all threads, but a 'let' binding is thread-local. Each thread also has its own current buffer and its own match data. See the chapter "Threads" in the ELisp manual for full documentation of these facilities. +++ ** The new function 'file-name-case-insensitive-p' tests whether a given file is on a case-insensitive filesystem. +++ ** The new user variable 'electric-quote-chars' provides a list of curved quotes for 'electric-quote-mode', allowing user to choose the types of quotes to be used. +++ ** The new user variable 'dired-omit-case-fold' allows the user to customize the case-sensitivity of dired-omit-mode. It defaults to the same sensitivity as that of the filesystem for the corresponding dired buffer. +++ ** Emacs now uses double buffering to reduce flicker when editing and resizing graphical Emacs frames on the X Window System. This support requires the DOUBLE-BUFFER extension, which major X servers have supported for many years. If your system has this extension, but an Emacs built with double buffering misbehaves on some displays you use, you can disable the feature by adding '(inhibit-double-buffering . t) to default-frame-alist. Or inject this parameter into the selected frame by evaluating this form: (modify-frame-parameters nil '((inhibit-double-buffering . t))) --- The group 'wp', whose label was "text", is now deprecated. Use the new group 'text', which inherits from 'wp', instead. +++ ** The new function 'call-shell-region' executes a command in an inferior shell with the buffer region as input. +++ ** The new user option 'shell-command-dont-erase-buffer' controls if the output buffer is erased between shell commands; if non-nil, the output buffer is not erased; this variable also controls where to set the point in the output buffer: beginning of the output, end of the buffer or save the point. When 'shell-command-dont-erase-buffer' is nil, the default value, the behavior of 'shell-command', 'shell-command-on-region' and 'async-shell-command' is as usual. +++ ** The new user option 'mouse-select-region-move-to-beginning' controls the position of point when double-clicking mouse-1 on the end of a parenthetical grouping or string-delimiter: the default value nil keeps point at the end of the region, setting it to non-nil moves point to the beginning of the region. +++ ** The new user option 'confirm-kill-processes' allows the user to skip a confirmation prompt for killing subprocesses when exiting Emacs. When set to t (the default), Emacs will prompt for confirmation before killing subprocesses on exit, which is the same behavior as before. --- ** 'find-library-name' will now fall back on looking at 'load-history' to try to locate libraries that have been loaded with an explicit path outside 'load-path'. +++ ** Faces in 'minibuffer-prompt-properties' no longer overwrite properties in the text in functions like 'read-from-minibuffer', but instead are added to the end of the face list. This allows users to say things like '(read-from-minibuffer (propertize "Enter something: " 'face 'bold))'. +++ ** The new variable 'extended-command-suggest-shorter' has been added to control whether to suggest shorter 'M-x' commands or not. --- ** icomplete now respects 'completion-ignored-extensions'. +++ ** Non-breaking hyphens are now displayed with the 'nobreak-hyphen' face instead of the 'escape-glyph' face. +++ ** Approximations to quotes are now displayed with the new 'homoglyph' face instead of the 'escape-glyph' face. --- ** 'C-x h' ('mark-whole-buffer') will now avoid marking the prompt part of minibuffers. --- ** 'find-library' now takes a prefix argument to pop to a different window. --- ** 'process-attributes' on Darwin systems now returns more information. +++ ** Several accessors for the value returned by 'file-attributes' have been added. They are: 'file-attribute-type', 'file-attribute-link-number', 'file-attribute-user-id', 'file-attribute-group-id', 'file-attribute-access-time', 'file-attribute-modification-time', 'file-attribute-status-change-time', 'file-attribute-size', 'file-attribute-modes', 'file-attribute-inode-number', 'file-attribute-device-number' and 'file-attribute-collect'. +++ ** The new function 'buffer-hash' computes a fast, non-consing hash of a buffer's contents. --- ** 'fill-paragraph' no longer marks the buffer as changed unless it actually changed something. --- ** The locale language name 'ca' is now mapped to the language environment 'Catalan', which has been added. --- ** 'align-regexp' has a separate history for its interactive argument. 'align-regexp' no longer shares its history with all other history-less functions that use 'read-string'. +++ ** The networking code has been reworked so that it's more asynchronous than it was (when specifying :nowait t in 'make-network-process'). How asynchronous it is varies based on the capabilities of the system, but on a typical GNU/Linux system the DNS resolution, the connection, and (for TLS streams) the TLS negotiation are all done without blocking the main Emacs thread. To get asynchronous TLS, the TLS boot parameters have to be passed in (see the manual for details). Certain process oriented functions (like 'process-datagram-address') will block until socket setup has been performed. The recommended way to deal with asynchronous sockets is to avoid interacting with them until they have changed status to "run". This is most easily done from a process sentinel. ** 'make-network-process' and 'open-network-stream' sometimes allowed :service to be an integer string (e.g., :service "993") and sometimes required an integer (e.g., :service 993). This difference has been eliminated, and integer strings work everywhere. ** It is possible to disable attempted recovery on fatal signals. Two new variables support disabling attempts to recover from stack overflow and to avoid automatic auto-save when Emacs is delivered a fatal signal. 'attempt-stack-overflow-recovery', if set to 'nil', will disable attempts to recover from C stack overflows; Emacs will then crash as with any other fatal signal. 'attempt-orderly-shutdown-on-fatal-signal', if set to 'nil', will disable attempts to auto-save the session and shut down in an orderly fashion when Emacs receives a fatal signal; instead, Emacs will terminate immediately. Both variables are non-'nil' by default. These variables are for users who would like to avoid the small probability of data corruption due to techniques Emacs uses to recover in these situations. +++ ** File local and directory local variables are now initialized each time the major mode is set, not just when the file is first visited. These local variables will thus not vanish on setting a major mode. +++ ** A second dir-local file (.dir-locals-2.el) is now accepted. See the variable 'dir-locals-file-2' for more information. +++ ** Connection-local variables can be used to specify local variables with a value depending on the connected remote server. For details, see the node "Connection Local Variables" in the ELisp manual. --- ** International domain names (IDNA) are now encoded via the new puny.el library, so that one can visit web sites with non-ASCII URLs. +++ ** The new 'timer-list' command lists all active timers in a buffer, where you can cancel them with the 'c' command. +++ ** The new function 'read-multiple-choice' prompts for multiple-choice questions, with a handy way to display help texts. +++ ** 'switch-to-buffer-preserve-window-point' now defaults to t. +++ ** The new variable 'debugger-stack-frame-as-list' allows displaying all call stack frames in a Lisp backtrace buffer as lists. Both debug.el and edebug.el have been updated to heed to this variable. +++ ** The new variable 'x-ctrl-keysym' has been added to the existing roster of X keysyms. It can be used in combination with another variable of this kind to swap modifiers in Emacs. --- ** New input methods: 'cyrillic-tuvan', 'polish-prefix'. +++ ** File name quoting by adding the prefix "/:" is now possible for the local part of a remote file name. Thus, if you have a directory named "/~" on the remote host "foo", you can prevent it from being substituted by a home directory by writing it as "/foo:/:/~/file". +++ ** The new variable 'maximum-scroll-margin' allows having effective settings of 'scroll-margin' up to half the window size, instead of always restricting the margin to a quarter of the window. +++ ** Emacs can scroll horizontally using mouse, touchpad, and trackbar. You can enable this by customizing 'mwheel-tilt-scroll-p'. If you want to reverse the direction of the scroll, customize 'mwheel-flip-direction'. +++ ** Emacsclient has a new option -u/--suppress-output. The option suppresses display of return values from the server process. ** New user option 'dig-program-options' and extended functionality for DNS-querying functions 'nslookup-host', 'dns-lookup-host', and 'run-dig'. Each function now accepts an optional name server argument interactively (with a prefix argument) and non-interactively. * Editing Changes in Emacs 26.1 +++ ** Two new user options 'list-matching-lines-jump-to-current-line' and 'list-matching-lines-current-line-face' to show highlighted the current line in *Occur* buffer. +++ ** The 'occur' command can now operate on the region. +++ ** New bindings for 'query-replace-map'. 'undo', undo the last replacement; bound to 'u'. 'undo-all', undo all replacements; bound to 'U'. ** 'delete-trailing-whitespace' deletes whitespace after form feed. In modes where form feed was treated as a whitespace character, 'delete-trailing-whitespace' would keep lines containing it unchanged. It now deletes whitespace after the last form feed thus behaving the same as in modes where the character is not whitespace. ** No more prompt about changed file when the file's content is unchanged. Instead of only checking the modification time, Emacs now also checks the file's actual content before prompting the user. ** Various casing improvements. *** 'upcase', 'upcase-region' et al. convert title case characters (such as =C7=B2) into their upper case form (such as =C7=B1). *** 'capitalize', 'upcase-initials' et al. make use of title-case forms of initial characters (correctly producing for example =C7=85ungla instead of incorrect =C7=84ungla). *** Characters which turn into multiple ones when cased are correctly handl= ed. For example, =EF=AC=81 ligature is converted to FI when upper cased. *** Greek small sigma is correctly handled when at the end of the word. Strings such as =CE=8C=CE=A3=CE=9F=CE=A3 are now correctly converted to =CE= =8C=CF=83=CE=BF=CF=82 when capitalized instead of incorrect =CE=8C=CF=83=CE=BF=CF=83 (compare lowercas= e sigma at the end of the word). ** Emacs can now auto-save buffers to visited files in a more robust manner via the new mode 'auto-save-visited-mode'. Unlike 'auto-save-visited-file-name', this mode uses the normal saving procedure and therefore obeys saving hooks. 'auto-save-visited-file-name' is now obsolete. * Changes in Specialized Modes and Packages in Emacs 26.1 *** Info menu and index completion uses substring completion by default. This can be customized via the info-menu category in completion-category-override. +++ *** The ancestor buffer is shown by default in 3way merges. A new option ediff-show-ancestor and a new toggle ediff-toggle-show-ancestor. ** TeX: Add luatex and xetex as alternatives to pdftex ** Electric-Buffer-menu +++ *** Key 'U' is bound to 'Buffer-menu-unmark-all' and key 'M-DEL' is bound to 'Buffer-menu-unmark-all-buffers'. ** bs --- *** Two new commands 'bs-unmark-all', bound to 'U', and 'bs-unmark-previous', bound to . ** Buffer-menu +++ *** Two new commands 'Buffer-menu-unmark-all', bound to 'U' and 'Buffer-menu-unmark-all-buffers', bound to 'M-DEL'. ** Gnus --- *** The .newsrc file will now only be saved if the native select method is an NNTP select method. +++ *** A new command for sorting articles by readedness marks has been added: 'C-c C-s C-m C-m'. ** Ibuffer --- *** New command 'ibuffer-jump'. --- *** New filter commands 'ibuffer-filter-by-basename', 'ibuffer-filter-by-file-extension', 'ibuffer-filter-by-directory', 'ibuffer-filter-by-starred-name', 'ibuffer-filter-by-modified' and 'ibuffer-filter-by-visiting-file'; bound respectively to '/b', '/.', '//', '/*', '/i' and '/v'. --- *** Two new commands 'ibuffer-filter-chosen-by-completion' and 'ibuffer-and-filter', the second bound to '/&'. --- *** The commands 'ibuffer-pop-filter', 'ibuffer-pop-filter-group', 'ibuffer-or-filter' and 'ibuffer-filter-disable' have the alternative bindings '/', '/S-', '/|' and '/DEL', respectively. --- *** The data format specifying filters has been extended to allow explicit logical 'and', and a more flexible form for logical 'not'. See 'ibuffer-filtering-qualifiers' doc string for full details. --- *** A new command 'ibuffer-copy-buffername-as-kill'; bound to 'B'. --- *** New command 'ibuffer-change-marks'; bound to '* c'. --- *** A new command 'ibuffer-mark-by-locked' to mark all locked buffers; bound to '% L'. --- *** A new option 'ibuffer-locked-char' to indicate locked buffers; Ibuffer shows a new column displaying 'ibuffer-locked-char' for locked buffers. --- *** A new command 'ibuffer-unmark-all-marks' to unmark all buffers without asking confirmation; bound to 'U'; 'ibuffer-do-replace-regexp' bound to 'r'. --- *** A new command 'ibuffer-mark-by-content-regexp' to mark buffers whose content matches a regexp; bound to '% g'. --- *** Two new options 'ibuffer-never-search-content-name' and 'ibuffer-never-search-content-mode' used by 'ibuffer-mark-by-content-regexp'. ** Browse-URL *** Support for opening links to man pages in Man or WoMan mode. ** Comint --- *** New user option 'comint-move-point-for-matching-input' to control where to place point after C-c M-r and C-c M-s. ** Compilation mode --- *** Messages from CMake are now recognized. +++ *** A new option 'dired-always-read-filesystem' default to nil. If non-nil, buffers visiting files are reverted before search them; for instance, in 'dired-mark-files-containing-regexp' a non-nil value of this option means the file is revisited in a temporary buffer; this temporary buffer is the actual buffer searched: the original buffer visiting the file is not modified. +++ *** In wdired, when editing files to contain slash characters, the resulting directories are automatically created. Whether to do this is controlled by the 'wdired-create-parent-directories' variable. +++ *** 'W' is now bound to 'browse-url-of-dired-file', and is useful for viewing HTML files and the like. ** Edebug *** Edebug can be prevented from pausing 1 second after reaching a breakpoint (e.g. with "f" and "o") by customizing the new option 'edebug-sit-on-break'. +++ *** New customizable option 'edebug-max-depth' This allows to enlarge the maximum recursion depth when instrumenting code. ** Eshell *** 'eshell-input-filter's value is now a named function 'eshell-input-filter-default', and has a new custom option 'eshell-input-filter-initial-space' to ignore adding commands prefixed with blank space to eshell history. ** eww +++ *** New 'M-RET' command for opening a link at point in a new eww buffer. +++ *** A new 's' command for switching to another eww buffer via the minibuffe= r. --- *** The 'o' command ('shr-save-contents') has moved to 'O' to avoid collisi= on with the 'o' command from 'image-map'. +++ *** A new command 'C' ('eww-toggle-colors') can be used to toggle whether to use the HTML-specified colors or not. The user can also customize the 'shr-use-colors' variable. --- *** Images that are being loaded are now marked with gray "placeholder" images of the size specified by the HTML. They are then replaced by the real images asynchronously, which will also now respect width/height HTML specs (unless they specify widths/heights bigger than the current window). ** Ido *** The commands 'find-alternate-file-other-window', 'dired-other-window', 'dired-other-frame', and 'display-buffer-other-window' are now remapped to Ido equivalents if Ido mode is active. ** Images +++ *** Images are automatically scaled before displaying based on the 'image-scaling-factor' variable (if Emacs supports scaling the images in question). +++ *** Images inserted with 'insert-image' and related functions get a keymap put into the text properties (or overlays) that span the image. This keymap binds keystrokes for manipulating size and rotation, as well as saving the image to a file. These commands are also available in 'image-mode'. +++ *** A new library for creating and manipulating SVG images has been added. See the "SVG Images" section in the Lisp reference manual for details. +++ *** New setf-able function to access and set image parameters is provided: 'image-property'. --- *** New commands 'image-scroll-left' and 'image-scroll-right' for 'image-mode' that complement 'image-scroll-up' and 'image-scroll-down': they have the same prefix arg behavior and stop at image boundaries. ** Image-Dired *** Now provides a minor mode 'image-dired-minor-mode' which replaces the function 'image-dired-setup-dired-keybindings'. *** Thumbnail generation is now asynchronous The number of concurrent processes is limited by the variable 'image-dired-thumb-job-limit'. *** 'image-dired-thumbnail-storage' has a new option 'standard-large' for generating 256x256 thumbnails according to the Thumbnail Managing Standard. *** Inherits movement keys from 'image-mode' for viewing full images. This includes the usual char, line, and page movement commands. *** All the -options types have been changed to argument lists instead of shell command strings. This change affects 'image-dired-cmd-create-thumbnail-options', 'image-dired-cmd-create-temp-image-options', 'image-dired-cmd-rotate-thumbnail-options', 'image-dired-cmd-rotate-original-options', 'image-dired-cmd-write-exif-data-options', 'image-dired-cmd-read-exif-data-options', and introduces 'image-dired-cmd-pngnq-options', 'image-dired-cmd-pngcrush-options', 'image-dired-cmd-create-standard-thumbnail-options' *** Recognizes more tools by default, including pngnq-s9 and OptiPNG *** 'find-file' and related commands now work on thumbnails and displayed images, providing a default argument of the original file name via an addition to 'file-name-at-point-functions'. --- ** The default 'Info-default-directory-list' no longer checks some obsolete directory suffixes (gnu, gnu/lib, gnu/lib/emacs, emacs, lib, lib/emacs) when searching for info directories. +++ ** The commands that add ChangeLog entries now prefer a VCS root directory for the ChangeLog file, if none already exists. Customize 'change-log-directory-files' to nil for the old behavior. --- ** Support for non-string values of 'time-stamp-format' has been removed. ** Message --- *** 'message-use-idna' now defaults to t (because Emacs comes with built-in IDNA support now). --- *** When sending HTML messages with embedded images, and you have exiftool installed, and you rotate images with EXIF data (i.e., JPEGs), the rotational information will be inserted into the outgoing image in the message. (The original image will not have its orientation affected.) --- *** The 'message-valid-fqdn-regexp' variable has been removed, since there are now top-level domains added all the time. Message will no longer warn about sending emails to top-level domains it hasn't heard about. *** 'message-beginning-of-line' (bound to C-a) understands folded headers. In 'visual-line-mode' it will look for the true beginning of a header while in non-'visual-line-mode' it will move the point to the indented header's value. ** Package +++ *** The new variable 'package-gnupghome-dir' has been added to control where the GnuPG home directory (used for signature verification) is located and whether GnuPG's option "--homedir" is used or not. ** Tramp +++ *** The method part of remote file names is mandatory now. A valid remote file name starts with "/method:host:" or "/method:user@host:". +++ *** The new pseudo method "-" is a marker for the default method. "/-::" is the shortest remote file name then. +++ *** The command 'tramp-change-syntax' allows to choose an alternative remote file name syntax. +++ *** New connection method "sg", which supports editing files under a different group ID. +++ *** New connection method "doas" for OpenBSD hosts. +++ *** New connection method "gdrive", which allows to access Google Drive onsite repositories. +++ *** Gateway methods in Tramp have been removed. Instead, the Tramp manual documents how to configure ssh and PuTTY accordingly. +++ *** Setting the "ENV" environment variable in 'tramp-remote-process-environment' enables reading of shell initialization files. --- *** Variable 'tramp-completion-mode' is obsoleted. --- ** 'auto-revert-use-notify' is set back to t in 'global-auto-revert-mode'. --- ** JS mode now sets 'comment-multi-line' to t. ** CSS mode --- *** Support for completing attribute values, at-rules, bang-rules, HTML tags, classes and IDs using the 'completion-at-point' command. Completion candidates for HTML classes and IDs are retrieved from open HTML mode buffers. --- *** CSS mode now binds 'C-h S' to a function that will show information about a CSS construct (an at-rule, property, pseudo-class, pseudo-element, with the default being guessed from context). By default the information is looked up on the Mozilla Developer Network, but this can be customized using 'css-lookup-url-format'. --- *** CSS colors are fontified using the color they represent as the background. For instance, #ff0000 would be fontified with a red background. +++ ** Emacs now supports character name escape sequences in character and string literals. The syntax variants \N{character name} and \N{U+code} are supported. +++ ** Prog mode has some support for multi-mode indentation. This allows better indentation support in modes that support multiple programming languages in the same buffer, like literate programming environments or ANTLR programs with embedded Python code. A major mode can provide indentation context for a sub-mode through the 'prog-indentation-context' variable. To support this, modes that provide indentation should use 'prog-widen' instead of 'widen' and 'prog-first-column' instead of a literal zero. See the node "Mode-Specific Indent" in the ELisp manual for more details. ** ERC *** New variable 'erc-default-port-tls' used to connect to TLS IRC servers. ** URL +++ *** The new function 'url-cookie-delete-cookie' can be used to programmatically delete all cookies, or cookies from a specific domain. +++ *** 'url-retrieve-synchronously' now takes an optional timeout parameter. --- *** The URL package now support HTTPS over proxies supporting CONNECT. +++ *** 'url-user-agent' now defaults to 'default', and the User-Agent string is computed dynamically based on 'url-privacy-level'. ** VC and related modes --- *** The VC state indicator in the mode line now defaults to more colorful faces to make it more obvious to the user what the state is. See the 'vc-faces' customization group. +++ *** 'vc-dir-mode' now binds 'vc-log-outgoing' to 'O'; and has various branch-related commands on a keymap bound to 'B'. ** CC mode *** Opening a .h file will turn C or C++ mode depending on language used. This is done with the help of 'c-or-c++-mode' function which analyses contents of the buffer to determine whether it's a C or C++ source file. ** Flymake +++ *** Emacs does no longer prompt the user before killing Flymake processes on exit. * New Modes and Packages in Emacs 26.1 ** New Elisp data-structure library 'radix-tree'. ** New library 'xdg' with utilities for some XDG standards and specs. ** HTML +++ *** A new submode of 'html-mode', 'mhtml-mode', is now the default mode for *.html files. This mode handles indentation, fontification, and commenting for embedded JavaScript and CSS. * Incompatible Lisp Changes in Emacs 26.1 +++ *** Command 'dired-mark-extension' now automatically prepends a '.' to the extension when not present. The new command 'dired-mark-suffix' behaves similarly but it doesn't prepend a '.'. +++ ** Certain cond/pcase/cl-case forms are now compiled using a faster jump table implementation. This uses a new bytecode op 'switch', which isn't compatible with previous Emacs versions. This functionality can be disabled by setting 'byte-compile-cond-use-jump-table' to nil. ** 'C-up', 'C-down', 'C-left' and 'C-right' are now defined in term mode to send the same escape sequences that xterm does. This makes things like forward-word in readline work. --- ** hideshow mode got four key bindings that are analogous to outline mode bindings: 'C-c @ C-a', 'C-c @ C-t', 'C-c @ C-d', and 'C-c @ C-e.' ** The grep/rgrep/lgrep functions will now ask about saving files before running. This is controlled by the 'grep-save-buffers' variable. --- ** Customizable variable 'query-replace-from-to-separator' now doesn't propertize the string value of the separator. Instead, text properties are added by query-replace-read-from. Additionally, the new nil value restores pre-24.5 behavior of not providing replacement pairs via the history. ** Some obsolete functions, variables, and faces have been removed: *** make-variable-frame-local. Variables cannot be frame-local any more. *** From subr.el: window-dot, set-window-dot, read-input, show-buffer, eval-current-buffer, string-to-int *** All the default-FOO variables that hold the default value of the FOO variable. Use 'default-value' and 'setq-default' to access and change FOO, respectively. The exhaustive list of removed variables is: 'default-mode-line-format', 'default-header-line-format', 'default-line-spacing', 'default-abbrev-mode', 'default-ctl-arrow', 'default-truncate-lines', 'default-left-margin', 'default-tab-width', 'default-case-fold-search', 'default-left-margin-width', 'default-right-margin-width', 'default-left-fringe-width', 'default-right-fringe-width', 'default-fringes-outside-margins', 'default-scroll-bar-width', 'default-vertical-scroll-bar', 'default-indicate-empty-lines', 'default-indicate-buffer-boundaries', 'default-fringe-indicator-alist', 'default-fringe-cursor-alist', 'default-scroll-up-aggressively', 'default-scroll-down-aggressively', 'default-fill-column', 'default-cursor-type', 'default-cursor-in-non-selected-windows', 'default-buffer-file-coding-system', 'default-major-mode', and 'default-enable-multibyte-characters'. *** Many variables obsoleted in 22.1 referring to face symbols +++ ** The variable 'text-quoting-style' no longer affects the treatment of curved quotes in format arguments to functions like 'message' and 'format-message'. In particular, when this variable's value is 'grave', all quotes in formats are output as-is. ** Functions like 'check-declare-file' and 'check-declare-directory' now generate less chatter and more-compact diagnostics. The auxiliary function 'check-declare-errmsg' has been removed. +++ ** The regular expression character class [:blank:] now matches Unicode horizontal whitespace as defined in the Unicode Technical Standard #18. If you only want to match space and tab, use [ \t] instead. +++ ** 'min' and 'max' no longer round their results. Formerly, they returned a floating-point value if any argument was floating-point, which was sometimes numerically incorrect. For example, on a 64-bit host (max 1e16 10000000000000001) now returns its second argument instead of its first. * Lisp Changes in Emacs 26.1 ** New function 'seq-set-equal-p' to check if SEQUENCE1 and SEQUENCE2 contain the same elements, regardless of the order. +++ ** Emacs now supports records for user-defined types, via the new functions 'make-record', 'record', and 'recordp'. Records are now used internally to represent cl-defstruct and defclass instances, for example. +++ ** 'save-some-buffers' now uses 'save-some-buffers-default-predicate' to decide which buffers to ask about, if the PRED argument is nil. The default value of 'save-some-buffers-default-predicate' is nil, which means ask about all file-visiting buffers. ** string-(to|as|make)-(uni|multi)byte are now declared obsolete. ** New variable 'while-no-input-ignore-events' which allow setting which special events 'while-no-input' should ignore. It is a list of symbols. ** New function 'undo-amalgamate-change-group' to get rid of undo-boundaries between two states. ** New var 'definition-prefixes' is a hash table mapping prefixes to the files where corresponding definitions can be found. This can be used to fetch definitions that are not yet loaded, for example for 'C-h f'. ** New var 'syntax-ppss-table' to control the syntax-table used in 'syntax-ppss'. +++ ** 'define-derived-mode' can now specify an :after-hook form, which gets evaluated after the new mode's hook has run. This can be used to incorporate configuration changes made in the mode hook into the mode's setup. ** Autoload files can be generated without timestamps, by setting 'autoload-timestamps' to nil. FIXME As an experiment, nil is the current default. If no insurmountable problems before next release, it can stay that way. --- ** 'gnutls-boot' now takes a parameter ':complete-negotiation' that says that negotiation should complete even on non-blocking sockets. --- ** There is now a new variable 'flyspell-sort-corrections-function' that allows changing the way corrections are sorted. --- ** The new command 'fortune-message' has been added, which displays fortunes in the echo area. +++ ** New function 'func-arity' returns information about the argument list of an arbitrary function. This generalizes 'subr-arity' for functions that are not built-in primitives. We recommend using this new function instead of 'subr-arity'. ** New function 'region-bounds' can be used in the interactive spec to provide region boundaries (for rectangular regions more than one) to an interactively callable function as a single argument instead of two separate arguments region-beginning and region-end. +++ ** 'parse-partial-sexp' state has a new element. Element 10 is non-nil when the last character scanned might be the first character of a two character construct, i.e., a comment delimiter or escaped character. Its value is the syntax of that last character. +++ ** 'parse-partial-sexp's state, element 9, has now been confirmed as permanent and documented, and may be used by Lisp programs. Its value is a list of currently open parenthesis positions, starting with the outermost parenthesis. --- ** 'read-color' will now display the color names using the color itself as the background color. ** The function 'redirect-debugging-output' now works on platforms other than GNU/Linux. +++ ** The new function 'string-version-lessp' compares strings by interpreting consecutive runs of numerical characters as numbers, and compares their numerical values. According to this predicate, "foo2.png" is smaller than "foo12.png". --- ** Numeric comparisons and 'logb' no longer return incorrect answers due to internal rounding errors. For example, (< most-positive-fixnum (+ 1.0 most-positive-fixnum)) now correctly returns t on 64-bit hosts. --- ** The functions 'ffloor', 'fceiling', 'ftruncate' and 'fround' now accept only floating-point arguments, as per their documentation. Formerly, they quietly accepted integer arguments and sometimes returned nonsensical answers, e.g., (< N (ffloor N)) could return t. --- ** On hosts like GNU/Linux x86-64 where a 'long double' fraction contains at least EMACS_INT_WIDTH - 3 bits, 'format' no longer returns incorrect answers due to internal rounding errors when formatting Emacs integers with %e, %f, or %g conversions. For example, on these hosts (eql N (string-to-number (format "%.0f" N))) now returns t for all Emacs integers N. --- ** Calls that accept floating-point integers (for use on hosts with limited integer range) now signal an error if arguments are not integral. For example (decode-char 'ascii 0.5) now signals an error. +++ ** The new function 'char-from-name' converts a Unicode name string to the corresponding character code. +++ ** New functions 'sxhash-eq' and 'sxhash-eql' return hash codes of a Lisp object suitable for use with 'eq' and 'eql' correspondingly. If two objects are 'eq' ('eql'), then the result of 'sxhash-eq' ('sxhash-eql') on them will be the same. +++ ** Function 'sxhash' has been renamed to 'sxhash-equal' for consistency with the new functions. For compatibility, 'sxhash' remains as an alias to 'sxhash-equal'. +++ ** 'make-hash-table' now defaults to a rehash threshold of 0.8125 instead of 0.8, to avoid rounding glitches. +++ ** New function 'add-variable-watcher' can be used to call a function when a symbol's value is changed. This is used to implement the new debugger command 'debug-on-variable-change'. +++ ** Time conversion functions that accept a time zone rule argument now allow it to be OFFSET or a list (OFFSET ABBR), where the integer OFFSET is a count of seconds east of Universal Time, and the string ABBR is a time zone abbreviation. The affected functions are 'current-time-string', 'current-time-zone', 'decode-time', 'format-time-string', and 'set-time-zone-rule'. +++ ** 'format-time-string' now formats "%q" to the calendar quarter. ** New built-in function 'mapcan' which avoids unnecessary consing (and gar= bage collection). +++ ** 'car' and 'cdr' compositions 'cXXXr' and 'cXXXXr' are now part of Elisp. --- ** 'if-let*', 'when-let*', and 'and-let*' are new in subr-x.el. The incumbent 'if-let' and 'when-let' are now aliases. ** Low-level list functions like 'length' and 'member' now do a better job of signaling list cycles instead of looping indefinitely. +++ ** The new functions 'make-nearby-temp-file' and 'temporary-file-directory' can be used for creation of temporary files of remote or mounted directorie= s. +++ ** The new function 'file-local-name' can be used to specify arguments of remote processes. +++ ** The new functions 'file-name-quote', 'file-name-unquote' and 'file-name-quoted-p' can be used to quote / unquote file names with the prefix "/:". +++ ** The new error 'file-missing', a subcategory of 'file-error', is now signaled instead of 'file-error' if a file operation acts on a file that does not exist. +++ ** The function 'delete-directory' no longer signals an error when operating recursively and when some other process deletes the directory or its files before 'delete-directory' gets to them. +++ *** New error type 'user-search-failed' like 'search-failed' but avoids debugger like 'user-error'. ** Changes in Frame- and Window- Handling +++ *** Resizing a frame no longer runs 'window-configuration-change-hook'. 'window-size-change-functions' should be used instead. +++ *** The new function 'frame-size-changed-p' can tell whether a frame has been resized since the last time 'window-size-change-functions' has been run. +++ *** The function 'frame-geometry' now also returns the width of a frame's outer border. +++ *** New frame parameters +++ **** 'z-group' positions a frame above or below all others. +++ **** 'min-width' and 'min-height' specify the absolute minimum size of a frame. +++ **** 'parent-frame' makes a frame the child frame of another Emacs frame. The section "Child Frames" in the Elisp manual describes the intrinsics of that relationship. +++ **** 'delete-before' triggers deletion of one frame before that of another. +++ **** 'mouse-wheel-frame' specifies another frame whose windows shall be scrolled instead. +++ **** 'no-other-frame' has 'next-frame' and 'previous-frame' skip this frame. +++ **** 'skip-taskbar' removes a frame's icon from the taskbar and has Alt- skip this frame. +++ **** 'no-focus-on-map' avoids that a frame gets input focus when mapped. +++ **** 'no-accept-focus' means that a frame does not want to get input focus via the mouse. +++ **** 'undecorated' removes the window manager decorations from a frame. +++ **** 'override-redirect' tells the window manager to disregard this frame. +++ *** The 'width' and 'height' frame parameters allow to specify pixel values now. +++ *** The new function 'frame-list-z-order' returns a list of all frames in Z (stacking) order. +++ *** The function 'x-focus-frame' optionally tries to not activate its frame. +++ *** The variable 'focus-follows-mouse' has a third meaningful value 'auto-raise' to indicate that the window manager automatically raises a frame when the mouse pointer enters it. +++ *** The new function 'frame-restack' puts a frame above or below another on the display. +++ *** The new face 'internal-border' specifies the background of a frame's internal border. +++ *** The NORECORD argument of 'select-window' now has a meaningful value 'mark-for-redisplay' which is like any other non-nil value but marks WINDOW for redisplay. +++ *** Support for side windows is now official. The display action function 'display-buffer-in-side-window' will display its buffer in a side window. Functions for toggling all side windows on a frame, changing and reversing the layout of side windows and returning the main (major non-side) window of a frame are provided. For details consult the section "Side Windows" in the Elisp manual. +++ *** Support for atomic windows - rectangular compositions of windows treated by 'split-window', 'delete-window' and 'delete-other-windows' like a single live window - is now official. For details consult the section "Atomic Windows" in the Elisp manual. +++ *** New 'display-buffer' alist entry 'window-parameters' allows to assign window parameters to the window used for displaying the buffer. +++ *** New function 'display-buffer-reuse-mode-window' is an action function suitable for use in 'display-buffer-alist'. For example, to avoid creating a new window when opening man pages when there's already one, use (add-to-list 'display-buffer-alist '("\\`\\*Man .*\\*\\'" . (display-buffer-reuse-mode-window (inhibit-same-window . nil) (mode . Man-mode)))) +++ *** New window parameter 'no-delete-other-window' prevents that its window gets deleted by 'delete-other-windows'. +++ *** New command 'window-swap-states' swaps the states of two live windows. +++ *** New functions 'window-pixel-width-before-size-change' and 'window-pixel-height-before-size-change' support detecting which window changed size when 'window-size-change-functions' are run. +++ *** The semantics of 'mouse-autoselect-window' has changed slightly. For details see the section "Mouse Window Auto-selection" in the Elisp manual. * Changes in Emacs 26.1 on Non-Free Operating Systems ** Intercepting hotkeys on Windows 7 and later now works better. The new keyboard hooking code properly grabs system hotkeys such as Win-* and Alt-TAB, in a way that Emacs can get at them before the system. This makes the 'w32-register-hot-key' functionality work again on all versions of MS-Windows starting with Windows 7. On Windows NT and later you can now register any hotkey combination. (On Windows 9X, the previous limitations, spelled out in the Emacs manual, still apply.) ** 'convert-standard-filename' no longer mirrors slashes on MS-Windows. Previously, on MS-Windows this function converted slash characters in file names into backslashes. It no longer does that. If your Lisp program used 'convert-standard-filename' to prepare file names to be passed to subprocesses (which is not the recommended usage of that function), you will now have to mirror slashes in your application code. One possible way is this: (let ((start 0)) (while (string-match "/" file-name start) (aset file-name (match-beginning 0) ?\\) (setq start (match-end 0)))) ** GUI sessions now treat SIGINT like Posix platforms do. The effect of delivering a Ctrl-C (SIGINT) signal to a GUI Emacs on MS-Windows is now the same as on Posix platforms -- Emacs saves the session and exits. In particular, this will happen if you start emacs.exe from the Windows shell, then type Ctrl-C into that shell's window. --- ** 'signal-process' supports SIGTRAP on Windows XP and later. The 'kill' emulation on Windows now maps SIGTRAP to a call to the 'DebugBreakProcess' API. This causes the receiving process to break execution and return control to the debugger. If no debugger is attached to the receiving process, the call is typically ignored. This is in contrast to the default action on POSIX Systems, where it causes the receiving process to terminate with a core dump if no debugger has been attached to it. ---------------------------------------------------------------------- This file is part of GNU Emacs. GNU Emacs is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. GNU Emacs is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with GNU Emacs. If not, see . Local variables: coding: utf-8 mode: outline paragraph-separate: "[ ]*$" end: --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Sun May 07 04:40:53 2017 Received: (at 25426) by debbugs.gnu.org; 7 May 2017 08:40:53 +0000 Received: from localhost ([127.0.0.1]:59026 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1d7HkL-0003UV-5q for submit@debbugs.gnu.org; Sun, 07 May 2017 04:40:53 -0400 Received: from aibo.runbox.com ([91.220.196.211]:57080) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1d7HkJ-0003UN-Q2 for 25426@debbugs.gnu.org; Sun, 07 May 2017 04:40:52 -0400 Received: from [10.9.9.210] (helo=mailfront10.runbox.com) by mailtransmit02.runbox with esmtp (Exim 4.86_2) (envelope-from ) id 1d7HkJ-0003rO-5h for 25426@debbugs.gnu.org; Sun, 07 May 2017 10:40:51 +0200 Received: from linux-cryptofree1-a.xn--cdaan2d.be ([212.129.34.154] helo=wallflower) by mailfront10.runbox.com with esmtpsa (uid:855208 ) (TLS1.2:DHE_RSA_AES_128_CBC_SHA1:128) (Exim 4.82) id 1d7HkC-0004JT-Ld; Sun, 07 May 2017 10:40:45 +0200 From: Andrew Robbins To: Andrew Robbins Subject: Re: [PATCH] 26.1; Revised patch for bug#25426 In-Reply-To: <87vapd3vy2.fsf@andrewrobbins.info> (Andrew Robbins's message of "Sun, 07 May 2017 04:36:21 -0400") References: <87vapd3vy2.fsf@andrewrobbins.info> User-Agent: Gnus/5.13 (Gnus v5.13) Date: Sun, 07 May 2017 04:40:42 -0400 Message-ID: <87r3013vqt.fsf@andrewrobbins.info> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 25426 Cc: 25426@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.7 (/) --=-=-= Content-Type: text/plain Andrew Robbins writes: > Attached are the diffs for 'NEWS', 'ChangeLog', and > 'net-utils.el'. Oops, attached the wrong files. THESE are the diffs. --=-=-= Content-Type: text/x-diff Content-Disposition: attachment; filename=ChangeLog.diff --- ChangeLog.2 2017-05-07 03:36:37.869464250 -0400 +++ ChangeLog.NEW 2017-05-07 03:45:59.594253035 -0400 @@ -1,3 +1,12 @@ +2017-05-07 Andrew Robbins + + * lisp/net/net-utils.el (ffap-string-at-point): Removed due to + 'net-utils-machine-at-point' obviating this autoloaded + function (Bug#25426). + (dig-program-options): New customization variable. + (nslookup-host, dns-lookup-host, run-dig): Can now specify optional + name server argument interactively (by prefix arg) & non-interactively. + 2017-04-20 Nicolas Petton * Version 25.2 released. --=-=-= Content-Type: text/x-diff Content-Disposition: attachment; filename=net-utils.diff --- lisp/net/net-utils.el 2017-05-07 03:36:38.553470033 -0400 +++ lisp/net/net-utils.el.NEW 2017-05-07 03:45:56.638227429 -0400 @@ -199,6 +199,12 @@ :group 'net-utils :type 'string) +(defcustom dig-program-options nil + "Options for the dig program." + :group 'net-utils + :type '(repeat string) + :version "26.1") + (defcustom ftp-program "ftp" "Program to run to do FTP transfers." :group 'net-utils @@ -507,15 +513,18 @@ ;; (delete-matching-lines filter)) ;;;###autoload -(defun nslookup-host (host) - "Lookup the DNS information for HOST." +(defun nslookup-host (host &optional name-server) + "Look up the DNS information for HOST (name or IP address). +Optional argument NAME-SERVER says which server to use for +DNS resolution. +Interactively, prompt for NAME-SERVER if invoked with prefix argument." (interactive - (list (read-from-minibuffer "Lookup host: " (net-utils-machine-at-point)))) + (list (read-from-minibuffer "Lookup host: " (net-utils-machine-at-point)) + (if current-prefix-arg (read-from-minibuffer "Name server: ")))) (let ((options - (if nslookup-program-options - (append nslookup-program-options (list host)) - (list host)))) - (net-utils-run-program + (append nslookup-program-options (list host) + (if name-server (list name-server))))) + (net-utils-run-program "Nslookup" (concat "** " (mapconcat 'identity @@ -551,14 +560,17 @@ (setq comint-input-autoexpand t)) ;;;###autoload -(defun dns-lookup-host (host) - "Lookup the DNS information for HOST (name or IP address)." +(defun dns-lookup-host (host &optional name-server) + "Look up the DNS information for HOST (name or IP address). +Optional argument NAME-SERVER says which server to use for +DNS resolution. +Interactively, prompt for NAME-SERVER if invoked with prefix argument." (interactive - (list (read-from-minibuffer "Lookup host: " (net-utils-machine-at-point)))) + (list (read-from-minibuffer "Lookup host: " (net-utils-machine-at-point)) + (if current-prefix-arg (read-from-minibuffer "Name server: ")))) (let ((options - (if dns-lookup-program-options - (append dns-lookup-program-options (list host)) - (list host)))) + (append dns-lookup-program-options (list host) + (if name-server (list name-server))))) (net-utils-run-program (concat "DNS Lookup [" host "]") (concat "** " @@ -568,15 +580,18 @@ dns-lookup-program options))) -(autoload 'ffap-string-at-point "ffap") - ;;;###autoload -(defun run-dig (host) - "Run dig program." +(defun run-dig (host &optional name-server) + "Look up the DNS information for HOST (name or IP address). +Optional argument NAME-SERVER says which server to use for +DNS resolution. +Interactively, prompt for NAME-SERVER if invoked with prefix argument." (interactive - (list - (read-from-minibuffer "Lookup host: " - (or (ffap-string-at-point 'machine) "")))) + (list (read-from-minibuffer "Lookup host: " (net-utils-machine-at-point)) + (if current-prefix-arg (read-from-minibuffer "Name server: ")))) + (let ((options + (append dig-program-options (list host) + (if name-server (list (concat "@" name-server)))))) (net-utils-run-program "Dig" (concat "** " @@ -584,7 +599,7 @@ (list "Dig" host dig-program) " ** ")) dig-program - (list host))) + options))) (autoload 'comint-exec "comint") --=-=-= Content-Type: text/x-diff Content-Disposition: attachment; filename=NEWS.diff --- etc/NEWS 2017-05-07 03:36:38.077466009 -0400 +++ etc/NEWS.NEW 2017-05-07 03:46:03.122283597 -0400 @@ -343,6 +343,11 @@ ** Emacsclient has a new option -u/--suppress-output. The option suppresses display of return values from the server process. +** New user option 'dig-program-options' and extended functionality +for DNS-querying functions 'nslookup-host', 'dns-lookup-host', +and 'run-dig'. Each function now accepts an optional name server +argument interactively (with a prefix argument) and non-interactively. + * Editing Changes in Emacs 26.1 --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Sun May 07 10:08:43 2017 Received: (at 25426) by debbugs.gnu.org; 7 May 2017 14:08:43 +0000 Received: from localhost ([127.0.0.1]:60404 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1d7Mrb-0004oL-E0 for submit@debbugs.gnu.org; Sun, 07 May 2017 10:08:43 -0400 Received: from mail-it0-f65.google.com ([209.85.214.65]:36176) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1d7Mra-0004o9-1U for 25426@debbugs.gnu.org; Sun, 07 May 2017 10:08:42 -0400 Received: by mail-it0-f65.google.com with SMTP id x188so5116639itb.3 for <25426@debbugs.gnu.org>; Sun, 07 May 2017 07:08:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=Ty+ac1VWoytM/iBxUnvNWZPhQ7k3h6qFFdBLyV1WrIk=; b=LqOZ6lzW9sCJpfosJPDeHv2/0hO2ZZ7tJWZ0facZrrcQNFS87EYu+n+AXzIAuT/8Wg JDcrauXaDBuHW+pSp7+jWVGfGfMt7jdD1mYKopB+tfpQpwfJ8vs7DwlyhvsL4K5FbF1h M/7JofrkNiEj5Qx9eXDip2zJs2vPTwAfxkklXQpWLHCyC/maIuewy4FAE1smU2Nyq4sF ydTAxVyZzULjYJ4zY1xZ5HlGnhDzNQkJ2ylOqe6yM48Z5ZVCokj5Sqct/r7i5CHkV9Rw WzeeMLMPsNlZcYw6sQ93Qi/ZzETGin6e+8eizdfRZL4Osc85HZlbZM6l08WiWJT+Juh/ NSXA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:references:date :in-reply-to:message-id:user-agent:mime-version; bh=Ty+ac1VWoytM/iBxUnvNWZPhQ7k3h6qFFdBLyV1WrIk=; b=eqSy+FRNnBLbOIn7F4jDReTk/50NPLbpZBy2qjgbz7p9qfNFxfQzJkwV1vsyHyksBj h5q52zF3J8okSRhkx9Btlh1rQJN7N9YIPRO0U6ktUsjj7J7hKcXhGFbPnv4F9eJczSoA W7Nh6MDzQil/sMSpEFW8RWXW0IapX4e9rtbm9b+doOgL2ERwwnsShN2JlJCbO95nf9KC Dfow+13XK2mJli2JZJcbC/tC4z3+4zf/28jI0CPScB9XpCzblsnvLOoi8azMyotagdEf 5S8AJYD0n3aSfG8onh9qPaSr1YFbhF5It+zbY/DJK+09Sdt8w+tLp9ey/LXmHDfvuU4W pVww== X-Gm-Message-State: AN3rC/7OFoy1n+j/j8P1JUzl12tu+baxAhmF9gJK6xjjHO4Q5ojecRDS yzBxCIhR/aromWHo X-Received: by 10.36.104.198 with SMTP id v189mr14986265itb.99.1494166116465; Sun, 07 May 2017 07:08:36 -0700 (PDT) Received: from zony ([45.2.7.65]) by smtp.googlemail.com with ESMTPSA id c62sm3516332itd.11.2017.05.07.07.08.35 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Sun, 07 May 2017 07:08:35 -0700 (PDT) From: npostavs@users.sourceforge.net To: Andrew Robbins Subject: Re: bug#25426: [PATCH] 26.1; Revised patch for bug#25426 References: <87vapd3vy2.fsf@andrewrobbins.info> <87r3013vqt.fsf@andrewrobbins.info> Date: Sun, 07 May 2017 10:10:08 -0400 In-Reply-To: <87r3013vqt.fsf@andrewrobbins.info> (Andrew Robbins's message of "Sun, 07 May 2017 04:40:42 -0400") Message-ID: <8737cglpvj.fsf@users.sourceforge.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.2 (/) X-Debbugs-Envelope-To: 25426 Cc: 25426@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: 0.2 (/) Andrew Robbins writes: > (let ((options > - (if nslookup-program-options > - (append nslookup-program-options (list host)) > - (list host)))) > - (net-utils-run-program > + (append nslookup-program-options (list host) > + (if name-server (list name-server))))) > + (net-utils-run-program > "Nslookup" > (concat "** " > (mapconcat 'identity The indentation on (net-utils-run-program...) seems to have got messed up. Otherwise looks good to me. From debbugs-submit-bounces@debbugs.gnu.org Sun May 07 16:27:59 2017 Received: (at 25426) by debbugs.gnu.org; 7 May 2017 20:27:59 +0000 Received: from localhost ([127.0.0.1]:60804 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1d7Smc-0004Gn-WD for submit@debbugs.gnu.org; Sun, 07 May 2017 16:27:59 -0400 Received: from aibo.runbox.com ([91.220.196.211]:38058) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1d7Sma-0004Gf-Ui for 25426@debbugs.gnu.org; Sun, 07 May 2017 16:27:57 -0400 Received: from [10.9.9.210] (helo=mailfront10.runbox.com) by mailtransmit02.runbox with esmtp (Exim 4.86_2) (envelope-from ) id 1d7SmZ-0006dF-Jp; Sun, 07 May 2017 22:27:55 +0200 Received: from linux-cryptofree1-a.xn--cdaan2d.be ([212.129.34.154] helo=wallflower) by mailfront10.runbox.com with esmtpsa (uid:855208 ) (TLS1.2:DHE_RSA_AES_128_CBC_SHA1:128) (Exim 4.82) id 1d7SmQ-0008ES-Hv; Sun, 07 May 2017 22:27:46 +0200 From: Andrew Robbins To: npostavs@users.sourceforge.net Subject: Re: bug#25426: [PATCH] 26.1; Revised patch for bug#25426 In-Reply-To: <8737cglpvj.fsf@users.sourceforge.net> (npostavs@users.sourceforge.net's message of "Sun, 07 May 2017 10:10:08 -0400") References: <87vapd3vy2.fsf@andrewrobbins.info> <87r3013vqt.fsf@andrewrobbins.info> <8737cglpvj.fsf@users.sourceforge.net> User-Agent: Gnus/5.13 (Gnus v5.13) Date: Sun, 07 May 2017 16:27:44 -0400 Message-ID: <87k25s4dkv.fsf@andrewrobbins.info> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 25426 Cc: 25426@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.7 (/) --=-=-= Content-Type: text/plain npostavs@users.sourceforge.net writes: > Andrew Robbins writes: > >> (let ((options >> - (if nslookup-program-options >> - (append nslookup-program-options (list host)) >> - (list host)))) >> - (net-utils-run-program >> + (append nslookup-program-options (list host) >> + (if name-server (list name-server))))) >> + (net-utils-run-program >> "Nslookup" >> (concat "** " >> (mapconcat 'identity > > The indentation on (net-utils-run-program...) seems to have got messed > up. Otherwise looks good to me. Ah, good catch. Here's the final diff if there aren't any other modifications that need to be made: --=-=-= Content-Type: text/x-diff Content-Disposition: attachment; filename=net-utils.final.diff --- lisp/net/net-utils.el 2017-05-07 03:57:44.080371619 -0400 +++ lisp/net/net-utils.el.NEW 2017-05-07 16:05:46.601658191 -0400 @@ -199,6 +199,12 @@ :group 'net-utils :type 'string) +(defcustom dig-program-options nil + "Options for the dig program." + :group 'net-utils + :type '(repeat string) + :version "26.1") + (defcustom ftp-program "ftp" "Program to run to do FTP transfers." :group 'net-utils @@ -507,14 +513,17 @@ ;; (delete-matching-lines filter)) ;;;###autoload -(defun nslookup-host (host) - "Lookup the DNS information for HOST." +(defun nslookup-host (host &optional name-server) + "Look up the DNS information for HOST (name or IP address). +Optional argument NAME-SERVER says which server to use for +DNS resolution. +Interactively, prompt for NAME-SERVER if invoked with prefix argument." (interactive - (list (read-from-minibuffer "Lookup host: " (net-utils-machine-at-point)))) + (list (read-from-minibuffer "Lookup host: " (net-utils-machine-at-point)) + (if current-prefix-arg (read-from-minibuffer "Name server: ")))) (let ((options - (if nslookup-program-options - (append nslookup-program-options (list host)) - (list host)))) + (append nslookup-program-options (list host) + (if name-server (list name-server))))) (net-utils-run-program "Nslookup" (concat "** " @@ -551,14 +560,17 @@ (setq comint-input-autoexpand t)) ;;;###autoload -(defun dns-lookup-host (host) - "Lookup the DNS information for HOST (name or IP address)." +(defun dns-lookup-host (host &optional name-server) + "Look up the DNS information for HOST (name or IP address). +Optional argument NAME-SERVER says which server to use for +DNS resolution. +Interactively, prompt for NAME-SERVER if invoked with prefix argument." (interactive - (list (read-from-minibuffer "Lookup host: " (net-utils-machine-at-point)))) + (list (read-from-minibuffer "Lookup host: " (net-utils-machine-at-point)) + (if current-prefix-arg (read-from-minibuffer "Name server: ")))) (let ((options - (if dns-lookup-program-options - (append dns-lookup-program-options (list host)) - (list host)))) + (append dns-lookup-program-options (list host) + (if name-server (list name-server))))) (net-utils-run-program (concat "DNS Lookup [" host "]") (concat "** " @@ -568,15 +580,18 @@ dns-lookup-program options))) -(autoload 'ffap-string-at-point "ffap") - ;;;###autoload -(defun run-dig (host) - "Run dig program." +(defun run-dig (host &optional name-server) + "Look up the DNS information for HOST (name or IP address). +Optional argument NAME-SERVER says which server to use for +DNS resolution. +Interactively, prompt for NAME-SERVER if invoked with prefix argument." (interactive - (list - (read-from-minibuffer "Lookup host: " - (or (ffap-string-at-point 'machine) "")))) + (list (read-from-minibuffer "Lookup host: " (net-utils-machine-at-point)) + (if current-prefix-arg (read-from-minibuffer "Name server: ")))) + (let ((options + (append dig-program-options (list host) + (if name-server (list (concat "@" name-server)))))) (net-utils-run-program "Dig" (concat "** " @@ -584,7 +599,7 @@ (list "Dig" host dig-program) " ** ")) dig-program - (list host))) + options))) (autoload 'comint-exec "comint") --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Fri May 12 04:37:35 2017 Received: (at 25426-done) by debbugs.gnu.org; 12 May 2017 08:37:35 +0000 Received: from localhost ([127.0.0.1]:39686 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1d964t-0000dk-63 for submit@debbugs.gnu.org; Fri, 12 May 2017 04:37:35 -0400 Received: from eggs.gnu.org ([208.118.235.92]:52558) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1d964r-0000dX-DI for 25426-done@debbugs.gnu.org; Fri, 12 May 2017 04:37:33 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1d964i-0007ha-Ul for 25426-done@debbugs.gnu.org; Fri, 12 May 2017 04:37:28 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-0.0 required=5.0 tests=BAYES_20,RP_MATCHES_RCVD autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:39338) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1d964i-0007hR-R3; Fri, 12 May 2017 04:37:24 -0400 Received: from 84.94.185.246.cable.012.net.il ([84.94.185.246]:1931 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1d964i-00067d-4q; Fri, 12 May 2017 04:37:24 -0400 Date: Fri, 12 May 2017 11:37:18 +0300 Message-Id: <834lwqa2td.fsf@gnu.org> From: Eli Zaretskii To: Andrew Robbins In-reply-to: <87k25s4dkv.fsf@andrewrobbins.info> (message from Andrew Robbins on Sun, 07 May 2017 16:27:44 -0400) Subject: Re: bug#25426: [PATCH] 26.1; Revised patch for bug#25426 References: <87vapd3vy2.fsf@andrewrobbins.info> <87r3013vqt.fsf@andrewrobbins.info> <8737cglpvj.fsf@users.sourceforge.net> <87k25s4dkv.fsf@andrewrobbins.info> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 25426-done Cc: 25426-done@debbugs.gnu.org, npostavs@users.sourceforge.net X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -5.0 (-----) > From: Andrew Robbins > Date: Sun, 07 May 2017 16:27:44 -0400 > Cc: 25426@debbugs.gnu.org > > Ah, good catch. Here's the final diff if there aren't any other > modifications that need to be made: Thanks, installed. From unknown Sun Jun 15 08:36:39 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Fri, 09 Jun 2017 11:24:04 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator