Commit graph

3202 commits

Author SHA1 Message Date
Michael Albinus
0332a0ef2b Minor improvements for tramp-interrupt-process, documentation
* doc/lispref/processes.texi (Signals to Processes):
* etc/NEWS: Document interrupt-process-functions.

* lisp/net/tramp.el (tramp-interrupt-process): Test also for
`process-live-p'.

* src/process.c (Vinterrupt_process_functions): Fix docstring.

* test/lisp/net/tramp-tests.el (tramp-test28-interrupt-process):
Extend test.
2017-08-24 15:53:56 +02:00
Michael Albinus
336707efb3 Test `file-expand-wildcards' for Tramp
* lisp/net/tramp-compat.el (tramp-advice-file-expand-wildcards):
Remove, not needed anymore.

* test/lisp/net/tramp-tests.el (top): Require seq.el.
(tramp-test16-directory-files): Simplify.
(tramp-test16-file-expand-wildcards): New test.
(tramp-test28-interrupt-process): Skip for older Emacsen.
2017-08-22 16:22:33 +02:00
Michael Albinus
01844e40dc Implement `interrupt-process-functions'
* lisp/net/tramp.el (tramp-interrupt-process): Rename from
`tramp-advice-interrupt-process'.  Adapt according to changed API.
(top): Add it to `interrupt-process-functions'.

* src/process.c (Finternal_default_interrupt_process): New defun.
(Finterrupt_process): Change implementation, based on
Vinterrupt_process_functions.
(Vinterrupt_process_functions): New defvar.

* test/lisp/net/tramp-tests.el (tramp-test40-unload): Do not
test removal of advice.
2017-08-21 17:30:33 +02:00
Michael Albinus
296472f5c5 Implement `interrupt-process' for remote processes (Bug#28066)
* lisp/net/tramp-sh.el (tramp-sh-handle-start-file-process):
Support sending signals remotely.
(tramp-open-connection-setup-interactive-shell):
Trace "remote-tty" connection property.

* lisp/net/tramp.el (tramp-advice-interrupt-process): New defun.
(top): Add advice to `interrupt-process'.  (Bug#28066)

* test/lisp/net/tramp-tests.el (tramp-test28-interrupt-process):
New test.
(tramp-test29-shell-command)
(tramp-test30-environment-variables)
(tramp-test30-environment-variables-and-port-numbers)
(tramp-test31-explicit-shell-file-name)
(tramp-test32-vc-registered)
(tramp-test33-make-auto-save-file-name)
(tramp-test34-make-nearby-temp-file)
(tramp-test35-special-characters)
(tramp-test35-special-characters-with-stat)
(tramp-test35-special-characters-with-perl)
(tramp-test35-special-characters-with-ls, tramp-test36-utf8)
(tramp-test36-utf8-with-stat, tramp-test36-utf8-with-perl)
(tramp-test36-utf8-with-ls)
(tramp-test37-asynchronous-requests)
(tramp-test38-recursive-load, tramp-test39-remote-load-path)
(tramp-test40-unload): Rename.
(tramp-test40-unload): Test also removal of advice.
2017-08-20 21:18:05 +02:00
Alex Schroeder
82b05985ba Use define-minor-mode for rcirc-omit-mode 2017-08-19 10:39:37 +02:00
Michael Albinus
142397e3a7 * lisp/net/ange-ftp.el (ange-ftp-skip-msgs): Further support ftp-ssl. 2017-08-16 11:52:12 +02:00
Michael Albinus
65899e5b01 * lisp/net/ange-ftp.el (ange-ftp-skip-msgs): Support ftp-ssl. 2017-08-14 18:05:58 +02:00
Paul Eggert
5bdc97d55d Be consistent in spelling 'ok-if-already-exists'. 2017-08-13 11:55:12 -07:00
Ulf Jasper
abab4b091f Remove feeds with dead uris from newsticker--raw-url-list-defaults
* lisp/net/newst-backend.el (newsticker--raw-url-list-defaults):
  Remove feeds with dead uris.
2017-08-13 16:55:03 +02:00
Ulf Jasper
0b858d9a88 Fix uri of Emacs Wiki
* lisp/net/newst-backend.el (newsticker--raw-url-list-defaults): Fix
  uri of Emacs Wiki.  (Bug#27981)
2017-08-13 16:26:31 +02:00
Michael Albinus
55a5e30c9f ; Do not mention ange-ftp-lovers ML in ange-ftp.el (Bug#28075) 2017-08-13 10:45:22 +02:00
Michael Albinus
ec5cfaa456 Implement EXCL of write-region for Tramp
* lisp/net/ange-ftp.el (ange-ftp-write-region):
* lisp/net/tramp-adb.el (tramp-adb-handle-write-region)
* lisp/net/tramp-gvfs.el (tramp-gvfs-handle-write-region):
* lisp/net/tramp-sh.el (tramp-sh-handle-write-region)
* lisp/net/tramp-smb.el (tramp-smb-handle-write-region):
Implement MUSTBENEW.

* lisp/net/tramp-gvfs.el (tramp-gvfs-do-copy-or-rename-file)
* lisp/net/tramp-sh.el (tramp-sh-handle-make-symbolic-link)
(tramp-sh-handle-add-name-to-file)
(tramp-do-copy-or-rename-file)
* lisp/net/tramp-smb.el (tramp-smb-handle-make-symbolic-link):
Adapt error message for `file-already-exists'.

* src/lisp.h:
* src/eval.c (call8): New function.

* src/fileio.c (write_region): Pass also lockname and
mustbenew to the file name handler.

* test/lisp/net/tramp-tests.el (tramp-test10-write-region):
Add tests for MUSTBENEW.
2017-08-12 12:30:39 +02:00
Mark Oteiza
c3445aed51 Do some cleanup in mailcap.el
* lisp/net/mailcap.el: Use lexical-binding.
(mailcap--set-user-mime-data, mailcap-possible-viewers): Use pcase
destructuring.
(mailcap-mime-data): Remove some entries for ancient functions.
(mailcap-parse-mailcaps, mailcap-mime-info): Nix single-branch ifs.
(mailcap-parse-mimetype-file): Just use append.
(mailcap-command-p): Remove unused function.
2017-08-07 22:06:03 -04:00
Grégoire Jadi
fe25d0ce8e Ensure that we parse images right in shr.el
* lisp/net/shr.el (shr-image-fetched): Go back to the
beginning of the buffer before trying to parse the image
fetched.
2017-07-24 17:29:28 +02:00
Lars Ingebrigtsen
e33ddda3bf Fix image/svg+xml display in shr
* lisp/net/shr.el (shr-put-image): Display svg images as svg
(bug#27799).  I suspect the previous change was checked in by
accident in conjuction with some other svg changes.
2017-07-23 15:23:14 +02:00
Michael Albinus
290d0e733f Stylistic changes in tramp-cache.el
* test/lisp/net/tramp-cache.el (tramp-get-file-property)
(tramp-set-file-property): Use `bound-and-true-p'.  Add
counter variables to `tramp-cache-unload-hook'.
2017-07-20 20:27:55 +02:00
Glenn Morris
ee5ec64624 Make tramp unloading handle debug counter variables
* lisp/net/tramp-cache.el (tramp-get-file-property)
(tramp-set-file-property): Add counter variables to tramp-unload-hook.
2017-07-20 13:46:52 -04:00
Michael Albinus
689c5c20d1 Use `with-demoted-errors' in Tramp
* lisp/net/tramp.el (tramp-with-demoted-errors): New defmacro.

* lisp/net/tramp-sh.el (tramp-sh-handle-vc-registered): Use it.
2017-07-10 17:49:01 +02:00
Michael Albinus
0440c748aa Add Quick Start Guide to Tramp manual
* doc/misc/tramp.texi: Use consequently "@value{tramp}" and
"MS Windows".
(Quick Start Guide): New node.

* doc/misc/trampver.texi:
* lisp/net/trampver.el: Change version to "2.3.3-pre".
2017-07-10 15:36:23 +02:00
Michael Albinus
17efc48000 Suppress timers in Tramp
* lisp/net/tramp.el (tramp-file-name-handler): Don't trigger timers.

* test/lisp/net/tramp-tests.el
(tramp-test36-asynchronous-requests): Trigger timers.
(tramp-test37-recursive-load, tramp-test38-remote-load-path):
Set `default-directory' to a trustworthy value.
2017-07-05 17:03:42 +02:00
Noam Postavsky
1b4f0a92ff Split shr-copy-url dwim behavior into separate functions (Bug#26826)
* lisp/net/shr.el (shr-url-at-point, shr-probe-url)
(shr-probe-and-copy-url, shr-maybe-probe-and-copy-url): New functions,
split out from `shr-copy-url'.
(shr-copy-url): Only copy the url, don't fetch it.
(shr-map): Bind 'w' and 'u' to `shr-maybe-probe-and-copy-url', which
has the same behavior as the old `shr-copy-url'.
* etc/NEWS: Announce changes.
2017-07-02 16:19:58 -04:00
Alex Branham
1fd6ca40fd Make eww-search-words prompt for query if nothing selected
* lisp/net/eww.el (eww-search-words): Make eww-search-words prompt the
user for a search query if the region is inactive or if the region is
just whitespace.

Copyright-paperwork-exempt: yes
2017-07-02 16:19:57 -04:00
Michael Albinus
ceedd86ed4 Release Tramp 2.3.2
* doc/misc/tramp.texi (Android shell setup): Show default file name.
Structure section.

* doc/misc/trampver.texi:
* lisp/net/trampver.el: Change version to "2.3.2".

* test/lisp/net/tramp-tests.el (tramp-test-temporary-file-directory):
Offer home directory for mock method if it doesn't exist.
2017-06-30 18:38:32 +02:00
Michael Albinus
138447c3ab Improve timer handling when Tramp accepts output
* lisp/net/tramp-compat.el: Avoid compiler warning.

* lisp/net/tramp-sh.el (tramp-sh-file-name-handler):
Remove lock machinery.

* lisp/net/tramp.el (tramp-locked, tramp-locker): Move up.
(tramp-file-name-handler): Add lock machinery from
`tramp-sh-file-name-handler'.  Allow timers to run.
(tramp-accept-process-output): Remove nasty workaround.
Suppress timers.

* test/lisp/net/tramp-tests.el (shell-command-sentinel):
Suppress run in tests.
(tramp--instrument-test-case-p): New defvar.
(tramp--instrument-test-case): Use it in order to allow nested calls.
(tramp--test-message, tramp--test-backtrace): New defsubst,
will be used for occasional test instrumentation.
(tramp-test00-availability, tramp-test31-vc-registered): Use them.
(tramp-test28-shell-command)
(tramp--test-shell-command-to-string-asynchronously): Suppress
nasty messages.  Don't overwrite sentinel.
(tramp-test36-asynchronous-requests): Rewrite major parts.
Expect :passed.
2017-06-29 18:22:38 +02:00
Michael Albinus
68e03d1eb4 Fix Android 6/7 problems in Tramp
* lisp/net/tramp-adb.el (tramp-adb-ls-toolbox-regexp): Fix link part.
(tramp-adb-handle-directory-files-and-attributes)
(tramp-adb-handle-file-name-all-completions): Insert "."  and
".." only when needed.
(tramp-adb-get-ls-command): Force one column output for toybox.
2017-06-25 19:49:53 +02:00
Stefan Monnier
4bd4df4047 * lisp/net/html2text.el: Move to obsolete/. 2017-06-24 08:59:20 -04:00
Glenn Morris
18896f7913 * lisp/net/shr.el (shr-fill-text): Actually fill the text. (Bug#27399) 2017-06-22 14:11:29 -04:00
Michael Albinus
ea196ebb93 Fix load-path issue when it contains remote directories
* lisp/net/tramp.el (tramp-file-name-handler): Use `autoloadp'.
(tramp-use-absolute-autoload-file-names): New defun.  Call it
after loading tramp.el.

* test/lisp/net/tramp-tests.el (tramp-test38-remote-load-path):
New test.
(tramp-test39-unload): Rename.
2017-06-16 14:46:25 +02:00
Michael Albinus
164fcc6f26 Fix Bug#27315
* lisp/net/tramp-cache.el (tramp-cache-read-persistent-data):
New defvar.
(top): Use it.

* lisp/net/tramp.el (tramp-handle-file-name-case-insensitive-p):
Check for connected, not for connectable.  (Bug#27315)
(tramp-process-actions):
* lisp/net/tramp-gvfs.el (tramp-gvfs-maybe-open-connection):
Use `tramp-cache-read-persistent-data'.

* test/lisp/net/tramp-tests.el (top): Set also
`tramp-cache-read-persistent-data'.
2017-06-14 14:17:22 +02:00
Thomas Fitzsimmons
2a058b7ef8 lisp/net/soap-client.el: Bump version to 3.1.3
* lisp/net/soap-client.el: Bump version to 3.1.3.
(soap-name-p): Fix checkdoc issue.
2017-06-13 21:21:24 -04:00
Alex Harsanyi
afc1eec8b8 Fix an HTTP encoding error in soap-client.el
* lisp/net/soap-client.el (soap-invoke-internal): Make
SOAPAction header a UTF-8 encoded string.
2017-06-13 21:21:24 -04:00
Michael Albinus
a63aeb64b7 * lisp/net/tramp-sh.el (tramp-set-file-uid-gid): Do not handle locally on w32. 2017-06-13 15:54:09 +02:00
Michael Albinus
e32d99593b ; Instrument `tramp-handle-file-name-case-insensitive-p' for debugging 2017-06-12 17:54:53 +02:00
Michael Albinus
7dfc8353ce Handle port and domain in Tramp's password cache
* doc/misc/tramp.texi (Password handling): Explain port and
domain handling in authinfo.

* lisp/net/tramp.el (tramp-process-actions, tramp-clear-passwd):
* lisp/net/tramp-gvfs.el (tramp-gvfs-handler-askpassword):
* lisp/net/tramp-sh.el (tramp-do-copy-or-rename-file-out-of-band)
(tramp-maybe-open-connection):
* lisp/net/tramp-smb.el (tramp-smb-handle-copy-directory)
(tramp-smb-handle-file-acl, tramp-smb-handle-set-file-acl)
(tramp-smb-maybe-open-connection): Handle also domain and port.
2017-06-12 17:52:42 +02:00
Glenn Morris
f5ea4efbe7 Merge from origin/emacs-25
eaa00584ce Improve documentation of 'gnutls-verify-error'
908498cc01 ; etc/PROBLEMS: Describe GTK-related crashes on elementar...
741daec617 ; Describe the problem with ksh when resizing shell window
2017-06-11 16:20:40 -07:00
Michael Albinus
87958db425 Some further improvements for tramp-gvfs.el
* lisp/net/tramp-gvfs.el (tramp-gvfs-handle-expand-file-name)
(tramp-gvfs-get-file-attributes)
(tramp-gvfs-maybe-open-connection): Handle davs? properly.
(tramp-gvfs-handler-askquestion): Improve `yes-or-no-p' prompt.
Show question also in batch mode.  Cache result.

* test/lisp/net/tramp-tests.el (tramp-test24-file-name-completion):
Support completion for host names and ports.
2017-06-11 23:16:13 +02:00
Michael Albinus
f361c54e6a Fix domain port and handling in tramp-gvfs.el
* lisp/net/tramp-gvfs.el (tramp-gvfs-dbus-byte-array-to-string):
Return nil if BYTE-ARRAY is nil.
(tramp-gvfs-url-file-name, tramp-gvfs-handler-mounted-unmounted)
(tramp-gvfs-connection-mounted-p, tramp-gvfs-mount-spec):
Fix domain and port handling.

* lisp/net/tramp.el (tramp-handle-file-name-case-insensitive-p):
Ignore errors.
2017-06-10 10:57:19 +02:00
Michael Albinus
a9327a0afc * lisp/net/tramp-sh.el (tramp-maybe-open-connection): Fix port handling. 2017-06-07 16:24:31 +02:00
Michael Albinus
792de924d5 Fix error in Tramp rsync method
* lisp/net/tramp-sh.el (tramp-methods) <rsync>: Add "-c" argument.
Otherwise, `tramp-test10-write-region' could fail.
2017-06-05 12:58:59 +02:00
Michael Albinus
e7bb7cc29b Some tweaks, almost all for Tramp adb method
* lisp/net/tramp-adb.el (tramp-adb-parse-device-names):
Use `make-tramp-file-name'.
(tramp-adb-get-device): Use `tramp-file-name-port-or-default'.
(tramp-adb-maybe-open-connection): Set "prompt" property.
(tramp-adb-wait-for-output): Use it.

* lisp/net/tramp-cache.el (tramp-cache-print): Use `elt'.
(tramp-dump-connection-properties): Check also that there are
properties to be saved.  Don't save "started" property of
"ftp" method.

* lisp/net/tramp-gvfs.el (tramp-gvfs-handle-expand-file-name):
Use `make-tramp-file-name'.

* lisp/net/tramp.el (tramp-remote-file-name-spec-regexp):
Host could be empty.
(tramp-file-name-port-or-default): New defun.
(tramp-dissect-file-name): Simplify `make-tramp-file-name' call.
(tramp-handle-file-name-case-insensitive-p): Use a progress reporter.
(tramp-call-process, tramp-call-process-region):
Use `make-tramp-file-name'.

* test/lisp/net/tramp-tests.el (tramp-test03-file-name-defaults):
Revert change from 2017-05-24.
(tramp-test05-expand-file-name-relative): Let it also pass for
"adb" method.
2017-05-28 23:44:10 +02:00
Jürgen Hötzel
288b3ca2e5 Fix Tramp for Android 7
* tramp-adb.el (tramp-adb-ls-toolbox-regexp):
Username part of prompt is empty on Android 7.
(tramp-adb-ls-toolbox-regexp):
Ignore addition links column on Android 7.
(tramp-adb-get-ls-command):
Dont use --color=none when using toybox (Android 7).  It's not
possible to disable coloring explicitly for toybox ls.
2017-05-28 13:06:53 +02:00
Michael Albinus
b303298840 Remove Emacs 23 compat code from Tramp
* doc/misc/tramp.texi (Remote processes): Don't mention
Emacs 24 explicitely.
(Frequently Asked Questions): Remove Emacs 23 from
compatibility list.

* lisp/net/tramp.el:
* lisp/net/tramp-adb.el:
* lisp/net/tramp-cache.el:
* lisp/net/tramp-gvfs.el:
* lisp/net/tramp-sh.el:
* lisp/net/tramp-smb.el: Replace compat function calls.

* lisp/net/tramp-compat.el (remote-file-name-inhibit-cache)
(tramp-compat-condition-case-unless-debug)
(tramp-compat-copy-file, tramp-compat-copy-directory)
(tramp-compat-delete-file, tramp-compat-delete-directory)
(tramp-compat-process-live-p): Remove them.

* lisp/net/trampver.el: Make version check fit for Emacs 24.
2017-05-26 16:25:18 +02:00
Thomas Fitzsimmons
9fb9e4b284 lisp/net/soap-client.el: Bump version to 3.1.2
* lisp/net/soap-client.el: Bump version to 3.1.2.
2017-05-25 08:49:58 -04:00
Thomas Fitzsimmons
4fa8336b03 Fix soap-inspect.el doc strings
* lisp/net/soap-inspect.el (soap-inspect-xs-attribute): Fix doc
string.
(soap-inspect-xs-attribute-group): Likewise.
2017-05-25 08:49:58 -04:00
Thomas Fitzsimmons
a928cfae60 Fix two soap-client.el byte compilation warnings
* lisp/net/soap-client.el (url-http-response-status): Add defvar.
(soap-fetch-xml-from-url): Remove special declaration of
url-http-response-status.
(soap-invoke-internal): Likewise.
2017-05-25 08:49:58 -04:00
Thomas Fitzsimmons
9a6ac2794f lisp/net/soap-client.el: Require cl-lib version 0.6.1
* lisp/net/soap-client.el: Require cl-lib version 0.6.1.
2017-05-25 08:49:58 -04:00
Thomas Fitzsimmons
27cafd1368 lisp/net/soap-client.el: Shorten some long lines
* lisp/net/soap-client.el (soap-encode-xs-element): Remove
unnecessary progn.
(soap-xs-add-union): Wrap long line.

Co-authored-by: Stefan Monnier <monnier@iro.umontreal.ca>
2017-05-25 08:49:57 -04:00
Alex Harsanyi
349fbb3551 Remove cl dependency in soap-client.el and soap-inspect.el
* lisp/net/soap-inspect.el: Replace cl library with cl-lib, case
with cl-case, destructuring-bind with cl-destructuring-bind and
loop with cl-loop.

* lisp/net/soap-client.el: Replace cl library with cl-lib,
defstruct with cl-defstruct, assert with cl-assert, case with
cl-case, ecase with cl-ecase, loop with cl-loop and
destructuring-bind with cl-destructuring-bind.

Co-authored-by: Stefan Monnier <monnier@iro.umontreal.ca>
2017-05-25 08:49:57 -04:00
Michael Albinus
1a9ce7c54e Switch Tramp to cl-lib
* lisp/net/tramp-compat.el (cl-lib): Require it rather than cl.

* lisp/net/tramp-ftp.el: Don't require cl.

* lisp/net/tramp-gvfs.el: Don't require cl.
(tramp-gvfs-handler-mounted-unmounted)
(tramp-gvfs-connection-mounted-p): Use `cl-*' macros.

* lisp/net/tramp-sh.el: Don't require cl.
(tramp-set-file-uid-gid): Use `shell-quote-argument'.
(tramp-sh-gvfs-monitor-dir-process-filter)
(tramp-sh-inotifywait-process-filter): Use `cl-*' macros.

* lisp/net/tramp-smb.el: Don't require cl.
(tramp-smb-read-file-entry): Use `cl-*' macros.

* lisp/net/tramp.el (cl-lib): Require it rather than cl.
(tramp-parse-file, tramp-parse-shostkeys-sknownhosts)
(tramp-parse-passwd, tramp-parse-etc-group)
(tramp-parse-putty): Use `cl-*' macros.
2017-05-25 10:04:12 +02:00
Michael Albinus
b2ec91db89 Fix Tramp for python.el
* lisp/net/tramp.el (tramp-get-connection-process): Check,
that VEC is a `tramp-file-name' structure.
2017-05-24 22:26:20 +02:00