commit ec3b436f18a120415b4ab45690347002cec4d831 (HEAD, refs/remotes/origin/master) Author: Dave Barker Date: Sat Nov 7 22:32:51 2015 +0000 Add ability to give rcirc servers an alias name * lisp/net/rcirc.el (rcirc-server-alist): Add :server-alias customization option. (rcirc, rcirc-connect): Take server alias into account. diff --git a/lisp/net/rcirc.el b/lisp/net/rcirc.el index 55b43f6..f2c8c5d 100644 --- a/lisp/net/rcirc.el +++ b/lisp/net/rcirc.el @@ -103,7 +103,12 @@ connected to automatically. `:encryption' VALUE must be `plain' (the default) for unencrypted connections, or `tls' -for connections using SSL/TLS." +for connections using SSL/TLS. + +`:server-alias' + +VALUE must be a string that will be used instead of the server name for +display purposes. If absent, the real server name will be displayed instead." :type '(alist :key-type string :value-type (plist :options ((:nick string) @@ -113,7 +118,8 @@ for connections using SSL/TLS." (:full-name string) (:channels (repeat string)) (:encryption (choice (const tls) - (const plain)))))) + (const plain))) + (:server-alias string)))) :group 'rcirc) (defcustom rcirc-default-port 6667 @@ -484,22 +490,26 @@ If ARG is non-nil, instead prompt for connection parameters." (channels (plist-get (cdr c) :channels)) (password (plist-get (cdr c) :password)) (encryption (plist-get (cdr c) :encryption)) + (server-alias (plist-get (cdr c) :server-alias)) contact) (when server (let (connected) (dolist (p (rcirc-process-list)) - (when (string= server (process-name p)) + (when (string= (or server-alias server) (process-name p)) (setq connected p))) (if (not connected) (condition-case nil (rcirc-connect server port nick user-name - full-name channels password encryption) - (quit (message "Quit connecting to %s" server))) + full-name channels password encryption + server-alias) + (quit (message "Quit connecting to %s" + (or server-alias server)))) (with-current-buffer (process-buffer connected) (setq contact (process-contact - (get-buffer-process (current-buffer)) :host)) + (get-buffer-process (current-buffer)) :name)) (setq connected-servers - (cons (if (stringp contact) contact server) + (cons (if (stringp contact) + contact (or server-alias server)) connected-servers)))))))) (when connected-servers (message "Already connected to %s" @@ -528,9 +538,10 @@ If ARG is non-nil, instead prompt for connection parameters." ;;;###autoload (defun rcirc-connect (server &optional port nick user-name - full-name startup-channels password encryption) + full-name startup-channels password encryption + server-alias) (save-excursion - (message "Connecting to %s..." server) + (message "Connecting to %s..." (or server-alias server)) (let* ((inhibit-eol-conversion) (port-number (if port (if (stringp port) @@ -542,7 +553,7 @@ If ARG is non-nil, instead prompt for connection parameters." (full-name (or full-name rcirc-default-full-name)) (startup-channels startup-channels) (process (open-network-stream - server nil server port-number + (or server-alias server) nil server port-number :type (or encryption 'plain)))) ;; set up process (set-process-coding-system process 'raw-text 'raw-text) @@ -557,7 +568,8 @@ If ARG is non-nil, instead prompt for connection parameters." password encryption)) (setq-local rcirc-process process) (setq-local rcirc-server server) - (setq-local rcirc-server-name server) ; Update when we get 001 response. + (setq-local rcirc-server-name + (or server-alias server)) ; Update when we get 001 response. (setq-local rcirc-buffer-alist nil) (setq-local rcirc-nick-table (make-hash-table :test 'equal)) (setq-local rcirc-nick nick) @@ -584,7 +596,7 @@ If ARG is non-nil, instead prompt for connection parameters." (setq rcirc-keepalive-timer (run-at-time 0 (/ rcirc-timeout-seconds 2) 'rcirc-keepalive))) - (message "Connecting to %s...done" server) + (message "Connecting to %s...done" (or server-alias server)) ;; return process object process))) commit 475b1efd4e1f52dd1f8f2c8e8a5384fcf65e1cfd Author: Paul Eggert Date: Sun Jan 31 12:37:11 2016 -0800 ; Fix ChangeLog.2 commit ID. diff --git a/ChangeLog.2 b/ChangeLog.2 index c5cba03..12f9834 100644 --- a/ChangeLog.2 +++ b/ChangeLog.2 @@ -28545,7 +28545,7 @@ This file records repository revisions from commit 9d56a21e6a696ad19ac65c4b405aeca44785884a (exclusive) to -commit 3f43da09956b663d92f578e41bcacb8742bb6bba (inclusive). +commit ffbf163ab5ced1bc464a0034e6abc9a41f5e09c4 (inclusive). See ChangeLog.1 for earlier changes. ;; Local Variables: commit dd951c009a28857c14ae6f0d32f9e8fc042f54a4 Author: Paul Eggert Date: Sun Jan 31 09:50:07 2016 -0800 Port new hybrid malloc to FreeBSD Problem reported by Wolfgang Jenkner in: http://bugs.gnu.org/22086#118 * src/gmalloc.c (__malloc_initialize_hook, __after_morecore_hook) (__morecore) [HYBRID_MALLOC]: Define in this case too. diff --git a/src/gmalloc.c b/src/gmalloc.c index 282216a..0b76aee 100644 --- a/src/gmalloc.c +++ b/src/gmalloc.c @@ -321,6 +321,13 @@ License along with this library. If not, see . /* Debugging hook for 'malloc'. */ static void *(*__MALLOC_HOOK_VOLATILE gmalloc_hook) (size_t); +/* Replacements for traditional glibc malloc hooks, for platforms that + do not already have these hooks. Platforms with these hooks all + used relaxed ref/def, so it is OK to define them here too. */ +void (*__MALLOC_HOOK_VOLATILE __malloc_initialize_hook) (void); +void (*__MALLOC_HOOK_VOLATILE __after_morecore_hook) (void); +void *(*__morecore) (ptrdiff_t); + #ifndef HYBRID_MALLOC /* Pointer to the base of the first block. */ @@ -347,10 +354,6 @@ size_t _bytes_free; /* Are you experienced? */ int __malloc_initialized; -void (*__MALLOC_HOOK_VOLATILE __malloc_initialize_hook) (void); -void (*__MALLOC_HOOK_VOLATILE __after_morecore_hook) (void); -void *(*__morecore) (ptrdiff_t); - #else static struct list _fraghead[BLOCKLOG]; commit 0496a19a3277db199571af82a5de07d2f5985f0f Author: Wolfgang Jenkner Date: Sun Jan 31 09:23:06 2016 -0800 * configure.ac: Stop using mmap for buffers for FreeBSD. diff --git a/configure.ac b/configure.ac index 856c36c..d97d9e5 100644 --- a/configure.ac +++ b/configure.ac @@ -2192,7 +2192,7 @@ fi use_mmap_for_buffers=no case "$opsys" in - cygwin|mingw32|freebsd|irix6-5) use_mmap_for_buffers=yes ;; + cygwin|mingw32|irix6-5) use_mmap_for_buffers=yes ;; esac AC_FUNC_MMAP commit 0156b79ea8fd473c550abdb8d3e3b4eacaaab289 Author: Michael Albinus Date: Sun Jan 31 13:50:23 2016 +0100 Merge changes from Tramp repository * doc/misc/Makefile.in (${buildinfodir}/tramp.info tramp.html): No EXTRA_OPTS needed. * doc/misc/tramp.texi: Merge changes from Emacsemacs-25 branch, especially for @trampfn{}. (Top): Move @ifnottex down. (History): XEmacs support has been removed. (GVFS based methods, Remote processes): Do not use emacsgvfs flag. (Auto-save and Backup): Use both syntax versions. (File name Syntax): Remark on IPv6 adresses is valid for unified syntax only. * doc/misc/trampver.texi: Do not set emacsgvfs flag. diff --git a/doc/misc/Makefile.in b/doc/misc/Makefile.in index 4dffeaf..eca74a0 100644 --- a/doc/misc/Makefile.in +++ b/doc/misc/Makefile.in @@ -218,7 +218,6 @@ gnus.pdf: $(gnus_deps) cp gnustmppdf.pdf $@ rm gnustmppdf.* -${buildinfodir}/tramp.info tramp.html: EXTRA_OPTS = -D emacs ${buildinfodir}/tramp.info tramp.html: ${srcdir}/trampver.texi diff --git a/doc/misc/tramp.texi b/doc/misc/tramp.texi index d01f9be..54b9826 100644 --- a/doc/misc/tramp.texi +++ b/doc/misc/tramp.texi @@ -17,9 +17,9 @@ @include trampver.texi -@c Macro for formatting a file name according to the respective syntax. -@c Macro arguments should not have any leading or -@c trailing whitespace. Not very elegant, but I don't know it better. +@c Macro for formatting a file name according to the respective +@c syntax. Macro arguments should not have any leading or trailing +@c whitespace. Not very elegant, but I don't know it better. @macro trampfn {method, userhost, localname} @value{prefix}@c @@ -68,10 +68,10 @@ copy and modify this GNU manual.'' @contents -@ifnottex @node Top, Overview, (dir), (dir) @top @value{tramp} version @value{trampver} User Manual +@ifnottex This file documents @value{tramp} version @value{trampver}, a remote file editing package for Emacs. @@ -112,7 +112,6 @@ The Mail Archive}. @end ifhtml @insertcopying - @end ifnottex @menu @@ -414,15 +413,12 @@ April 2000 was the first time when multi-hop methods were added. In July 2002, @value{tramp} unified file names with Ange-FTP@. In July 2004, proxy hosts replaced multi-hop methods. Running commands on remote hosts was introduced in December 2005. Support for gateways -since April 2007. -@ifset emacsgvfs -GVFS integration started in February 2009. -@end ifset -Remote commands on Windows hosts since September 2011. Ad-hoc -multi-hop methods (with a changed syntax) re-enabled in November 2011. - -In November 2012, added Juergen Hoetzel's @file{tramp-adb.el}. +since April 2007. GVFS integration started in February 2009. Remote +commands on Windows hosts since September 2011. Ad-hoc multi-hop +methods (with a changed syntax) re-enabled in November 2011. In +November 2012, added Juergen Hoetzel's @file{tramp-adb.el}. +XEmacs support has been stopped in January 2016. @c Installation chapter is necessary only in case of standalone @c installation. Text taken from trampinst.texi. @@ -438,8 +434,8 @@ In November 2012, added Juergen Hoetzel's @file{tramp-adb.el}. @value{tramp} is initially configured to use the @command{scp} program to connect to the remote host. Just type @kbd{C-x C-f} and then enter -file name @file{@trampf{user@@host,/path/to.file}}. For details, -see @xref{Default Method}. +file name @file{@trampf{user@@host,/path/to.file}}. For details, see +@xref{Default Method}. For problems related to the behavior of remote shell, see @ref{Remote shell setup} for details. @@ -869,9 +865,9 @@ uses the anonymous user (without prompting for password). This behavior is unlike other @value{tramp} methods, where local user name is substituted. -The @option{smb} method is unavailable if Emacs is run under a -local user authentication context in MS Windows. However such users -can still access remote files using UNC file names instead of @value{tramp}: +The @option{smb} method is unavailable if Emacs is run under a local +user authentication context in MS Windows. However such users can +still access remote files using UNC file names instead of @value{tramp}: @example //melancholia/daniel$$/.emacs @@ -881,6 +877,7 @@ UNC file name specification does not allow the specification of a different user name for authentication like the @command{smbclient} can. + @item @option{adb} @cindex method adb @cindex adb method @@ -900,17 +897,17 @@ Emacs. @value{tramp} does not require a host name part of the remote file name when a single Android device is connected to @command{adb}. -@value{tramp} instead uses @file{@trampfn{adb,,}} as the default -name. @command{adb devices} shows available host names. +@value{tramp} instead uses @file{@trampfn{adb,,}} as the default name. +@command{adb devices} shows available host names. @option{adb} method normally does not need user name to authenticate -on the Andriod device because it runs under the @command{adbd} +on the Android device because it runs under the @command{adbd} process. But when a user name is specified, however, @value{tramp} applies an @command{su} in the syntax. When authentication does not succeed, especially on un-rooted Android devices, @value{tramp} displays login errors. -For Andriod devices connected through TCP/IP, a port number can be +For Android devices connected through TCP/IP, a port number can be specified using @file{device#42} host name syntax or @value{tramp} can use the default value as declared in @command{adb} command. Port numbers are not applicable to Android devices connected through USB@. @@ -918,7 +915,6 @@ numbers are not applicable to Android devices connected through USB@. @end table -@ifset emacsgvfs @node GVFS based methods @section GVFS based external methods @cindex methods, gvfs @@ -987,7 +983,6 @@ default, this list includes @option{afp}, @option{dav}, @option{davs}, @option{obex}, @option{sftp} and @option{synce}. Other methods to include are: @option{ftp} and @option{smb}. @end defopt -@end ifset @node Gateway methods @@ -1274,9 +1269,9 @@ access, then use this alist entry: '("\\.your\\.domain\\'" "\\`root\\'" "@trampfn{ssh,%h,}")) @end lisp -Opening @file{@trampfn{sudo,randomhost.your.domain,}} first -connects to @samp{randomhost.your.domain} via @code{ssh} under your -account name, and then perform @code{sudo -u root} on that host. +Opening @file{@trampfn{sudo,randomhost.your.domain,}} first connects +to @samp{randomhost.your.domain} via @code{ssh} under your account +name, and then perform @code{sudo -u root} on that host. It is key for the sudo method in the above example to be applied on the host after reaching it and not on the local host. @@ -1879,7 +1874,7 @@ where @samp{192.168.0.1} is the remote host IP address @value{tramp} uses the @option{adb} method to access Android devices. Android devices provide a restricted shell access through an -USB connection. The local host must have Andriod SDK installed. +USB connection. The local host must have the Android SDK installed. Applications such as @code{SSHDroid} that run @command{sshd} process on the Android device can accept any @option{ssh}-based methods @@ -1917,8 +1912,8 @@ directory for temporary files: @noindent Open a remote connection with the command @kbd{C-x C-f -@trampfn{ssh,192.168.0.26#2222,}}, where @command{sshd} is listening on port -@samp{2222}. +@trampfn{ssh,192.168.0.26#2222,}}, where @command{sshd} is listening +on port @samp{2222}. To add a corresponding entry to the @file{~/.ssh/config} file (recommended), use this: @@ -1950,8 +1945,8 @@ Open a remote connection with a more concise command @kbd{C-x C-f @cindex backup @vindex backup-directory-alist -To avoid @value{tramp} from saving backup files owned by root to -locations accessible to others, default backup settings in +To avoid @value{tramp} from saving backup files owned by @samp{root} +to locations accessible to others, default backup settings in @code{backup-directory-alist} have to be altered. Here's a scenario where files could be inadvertently exposed. Emacs @@ -1959,9 +1954,9 @@ by default writes backup files to the same directory as the original files unless changed to another location, such as @file{~/.emacs.d/backups/}. Such a directory will also be used by default by @value{tramp} when using, say, a restricted file -@file{@trampfn{su,root@@localhost,/etc/secretfile}}. The backup -file of the secretfile is now owned by the user logged in from tramp -and not root. +@file{@trampfn{su,root@@localhost,/etc/secretfile}}. The backup file +of the secretfile is now owned by the user logged in from +@value{tramp} and not @samp{root}. When @code{backup-directory-alist} is @code{nil} (the default), such problems do not occur. @@ -1975,7 +1970,7 @@ To ``turns off'' the backup feature for @value{tramp} files and stop @end lisp @noindent -Disabling backups can be targetted to just @option{su} and +Disabling backups can be targeted to just the @option{su} and @option{sudo} methods: @lisp @@ -2011,7 +2006,12 @@ Example: @noindent The backup file name of @file{@trampfn{su,root@@localhost,/etc/secretfile}} would be -@file{@trampfn{su,root@@localhost,~/.emacs.d/backups/!su:root@@localhost:!etc!secretfile~}}. +@ifset unified +@file{@trampfn{su,root@@localhost,~/.emacs.d/backups/!su:root@@localhost:!etc!secretfile~}} +@end ifset +@ifset separate +@file{@trampfn{su,root@@localhost,~/.emacs.d/backups/![su!root@@localhost]!etc!secretfile~}} +@end ifset Just as for backup files, similar issues of file naming affect auto-saving @value{tramp} files. Auto-saved files are saved in the @@ -2038,7 +2038,7 @@ This section is incomplete. Please share your solutions. Cygwin's @command{ssh} works only with a Cygwin version of Emacs. To check for compatibility: type @kbd{M-x eshell}, and start @kbd{ssh -test.host}. Incompatbilities trigger this message: +test.host}. Incompatibilities trigger this message: @example Pseudo-terminal will not be allocated because stdin is not a terminal. @@ -2090,7 +2090,7 @@ syntax. Unlike opening local files in Emacs, which are instantaneous, opening remote files in @value{tramp} is slower at first. Sometimes there is -a noticable delay before the prompts for passwords or authentication +a noticeable delay before the prompts for passwords or authentication appear in the minibuffer. Hitting @kbd{@key{RET}} or other keys during this gap will be processed by Emacs. This type-ahead facility is a feature of Emacs that may cause missed prompts when using @@ -2110,9 +2110,9 @@ is a feature of Emacs that may cause missed prompts when using @cindex file name syntax @cindex file name examples -@file{@trampf{host,localfilename}} -opens file @var{localfilename} on the remote host @var{host}, using -the default method. @xref{Default Method}. +@file{@trampf{host,localfilename}} opens file @var{localfilename} on +the remote host @var{host}, using the default method. @xref{Default +Method}. @table @file @item @value{prefix}melancholia@value{postfix}.emacs @@ -2139,8 +2139,10 @@ For the file @file{/etc/squid.conf} on the host @code{melancholia}. @var{host} can take IPv4 or IPv6 address, as in @file{@trampf{127.0.0.1,.emacs}} or @file{@trampf{@value{ipv6prefix}::1@value{ipv6postfix},.emacs}}. +@ifset unified For syntactical reasons, IPv6 addresses must be embedded in square brackets @file{@value{ipv6prefix}} and @file{@value{ipv6postfix}}. +@end ifset By default, @value{tramp} will use the current local user name as the remote user name for log in to the remote host. Specifying a different @@ -2150,16 +2152,15 @@ name using the proper syntax will override this default behavior: @trampf{user@@host,path/to.file} @end example -@file{@trampf{daniel@@melancholia,.emacs}} is for file -@file{.emacs} in @code{daniel}'s home directory on the host, -@code{melancholia}. +@file{@trampf{daniel@@melancholia,.emacs}} is for file @file{.emacs} +in @code{daniel}'s home directory on the host, @code{melancholia}. Specify other file access methods (@pxref{Inline methods}, @pxref{External methods}) as part of the file name. Method name comes before user name, as in @file{@value{prefix}@var{method}@value{postfixhop}} (Note the trailing -colon). The syntax specificaton for user, host, and file do not +colon). The syntax specifications for user, host, and file do not change. To connect to the host @code{melancholia} as @code{daniel}, using @@ -2212,8 +2213,7 @@ shows host names @value{tramp} from @file{/etc/hosts} file, for example. @multitable @columnfractions .5 .5 @c @multitable {@trampfn{telnet,melancholia.danann.net,}} {@trampfn{telnet,192.168.0.1,}} @item @trampfn{telnet,127.0.0.1,} @tab @trampfn{telnet,192.168.0.1,} -@c @item @trampfn{telnet,@value{ipv6prefix}::1@value{ipv6postfix},} @tab @trampfn{telnet,localhost,} -@item @value{prefix}telnet@value{postfixhop}@value{ipv6prefix}::1@value{ipv6postfix}@value{postfix} @tab @trampfn{telnet,localhost,} +@item @trampfn{telnet,@value{ipv6prefix}::1@value{ipv6postfix},} @tab @trampfn{telnet,localhost,} @item @trampfn{telnet,melancholia.danann.net,} @tab @trampfn{telnet,melancholia,} @end multitable @end example @@ -2229,8 +2229,8 @@ persistently (@pxref{Connection caching}) will be included in the completion lists. After remote host name completion comes completion of file names on -the remote host. It works the same as on loal host file completion -except when killing with double-slash @file{//} kills only the file +the remote host. It works the same as with local host file completion +except that killing with double-slash @file{//} kills only the file name part of the @value{tramp} file name syntax. A triple-slash stands for the default behavior. @ifinfo @@ -2327,12 +2327,9 @@ host when the variable @code{default-directory} is remote: "/bin/sh" "-c" "grep -e tramp *")) @end lisp - -@ifset emacsgvfs Remote processes do not apply to GVFS (see @ref{GVFS based methods}) because the remote file system is mounted on the local host and @value{tramp} just accesses by changing the @code{default-directory}. -@end ifset @value{tramp} starts a remote process when a command is executed in a remote file or directory buffer. As of now, these packages have been @@ -2513,8 +2510,8 @@ with a remote file name: @end example Relative file names are based on the remote default directory. When -@file{myprog.pl} exists in @file{@trampfn{ssh,host,/home/user}}, -valid calls include: +@file{myprog.pl} exists in @file{@trampfn{ssh,host,/home/user}}, valid +calls include: @example @kbd{M-x perldb @key{RET}} @@ -2570,9 +2567,8 @@ the internal representation of a remote connection. When called interactively, this command lists active remote connections in the minibuffer. Each connection is of the format @file{@trampfn{method,user@@host,}}. Flushing remote connections also -cleans the password -cache (@pxref{Password handling}), file cache, connection cache -(@pxref{Connection caching}), and connection buffers. +cleans the password cache (@pxref{Password handling}), file cache, +connection cache (@pxref{Connection caching}), and connection buffers. @end deffn @deffn Command tramp-cleanup-this-connection diff --git a/doc/misc/trampver.texi b/doc/misc/trampver.texi index 7093817..cdd008b 100644 --- a/doc/misc/trampver.texi +++ b/doc/misc/trampver.texi @@ -18,11 +18,6 @@ @c Formatting of the tramp program name consistent. @set tramp @sc{Tramp} -@c Whether or not describe GVFS integration. -@ifclear noemacsgvfs -@set emacsgvfs -@end ifclear - @c Some flags which define the remote file name syntax. @ifclear unified @ifclear separate