1. 11 Aug, 2020 1 commit
    • Kaushal Modi's avatar
      Allow Dired to dereference symbolic links when copying · 9b01badf
      Kaushal Modi authored
      * doc/emacs/dired.texi (Operating on Files): Mention the new
      defcustom (bug#25075).
      * lisp/dired-aux.el (dired-do-copy): Invert the value of
      `dired-copy-dereference' in lexical scope when prefix argument is
      '(4). Update function documentation for the new defcustom.
      * lisp/dired-aux.el (dired-copy-file): Use `dired-copy-dereference' as
      the `dereference' argument to `dired-copy-file-recursive'.
      * lisp/dired-aux.el (dired-copy-file-recursive): Add new optional
      argument `dereference'.
      * lisp/dired.el (dired-copy-dereference): New defcustom, defaults to
  2. 09 Aug, 2020 2 commits
    • Eli Zaretskii's avatar
      Fix recently added documentation bits · ec323389
      Eli Zaretskii authored
      * lisp/simple.el (async-shell-command-buffer)
      (async-shell-command, shell-command, shell-command-on-region):
      * lisp/dired-aux.el (dired-do-async-shell-command)
      * doc/misc/tramp.texi (Remote processes):
      * doc/emacs/misc.texi (Single Shell):
      * etc/NEWS: Fix wording and punctuation of recently added
    • Tino Calancha's avatar
      Add constants for shell command output buffer names · 2ed502d2
      Tino Calancha authored
      Buffers `*Shell Command Output*' and `*Async Shell Command*'
      have been around since a long time; used across several libraries,
      they are de facto output buffers for shell commands.
      * lisp/simple.el (shell-command-buffer-name)
      (shell-command-buffer-name-async): New variables.
      * lisp/dired-aux.el
      * lisp/gnus/gnus-sum.el
      * lisp/gnus/gnus-win.el
      * lisp/ibuf-ext.el
      * lisp/net/tramp.el: Use them.
      * etc/NEWS (Changes in Emacs 28.1): Announce this change.
      * doc/emacs/misc.texi (Single Shell)
      * doc/misc/tramp.texi (Remote processes):
      Update manual (bug#39138).
  3. 06 Aug, 2020 2 commits
    • Nick Helm's avatar
      Signal an error in dired when moving to a directory that doesn't exist · 66bdf77a
      Nick Helm authored
      * lisp/dired-aux.el (dired-do-create-files): Give an error when
      apparently moving to a directory name, and that directory doesn't
      exist (bug#38707).
    • Paul Eggert's avatar
      Simplify Solaris port · 155b2c8a
      Paul Eggert authored
      This should avoid some configuration confusion as exemplified
      by Jeffrey Walton’s recent bug report (Bug#42675).
      * configure.ac (opsys): Simplify Solaris configuration by
      not worrying about Solaris 9 and earlier, as they are no
      longer supported by the Solaris developers.  This should
      support Walton’s ‘./configure --build=x86_64-sun-solaris’.
      Instead of bothering with ‘opsys=sol2-6’ and ‘opsys=sol2-10’,
      just use ‘opsys=solaris’.  All uses changed.
      (emacs_check_sunpro_c): Remove unused var.
      * doc/misc/tramp.texi (Remote programs):
      * etc/MACHINES, etc/PROBLEMS:
      Modernize PATH for Oracle Developer Studio.
      * etc/PROBLEMS: Move Solaris-related problems to legacy area,
      except those that are still relevant.
  4. 05 Aug, 2020 1 commit
  5. 18 Jun, 2020 1 commit
    • Basil L. Contovounesios's avatar
      Fix and extend format-spec (bug#41758) · 0185d76e
      Basil L. Contovounesios authored
      * lisp/format-spec.el: Use lexical-binding.  Remove dependence on
      (format-spec-make): Clarify docstring.
      (format-spec--parse-modifiers): Rename to...
      (format-spec--parse-flags): ...this and simplify.  In particular,
      don't bother parsing :space-pad which is redundant and unused.
      (format-spec--pad): Remove, replacing with...
      (format-spec--do-flags): ...this new helper function which performs
      more of format-spec's supported text manipulation.
      (format-spec): Autoload.  Allow optional argument to take on special
      values 'ignore' and 'delete' for more control over what happens when
      a replacement for a format specification isn't provided.  Bring back
      proper support for a precision modifier similar to that of 'format'.
      * lisp/battery.el (battery-format): Rewrite in terms of format-spec.
      (battery-echo-area-format, battery-mode-line-format): Mention
      support of format-spec syntax in docstrings.
      * doc/lispref/strings.texi (Custom Format Strings):
      * etc/NEWS: Document and announce these changes.
      * lisp/dired-aux.el (dired-do-compress-to):
      * lisp/erc/erc-match.el (erc-log-matches):
      * lisp/erc/erc.el (erc-update-mode-line-buffer):
      * lisp/gnus/gnus-sieve.el (gnus-sieve-update):
      * lisp/gnus/gssapi.el (open-gssapi-stream):
      * lisp/gnus/mail-source.el (mail-source-fetch-file)
      (mail-source-fetch-directory, mail-source-fetch-pop)
      * lisp/gnus/message.el (message-insert-formatted-citation-line):
      * lisp/image-dired.el:
      * lisp/net/eww.el:
      * lisp/net/imap.el (imap-kerberos4-open, imap-gssapi-open)
      * lisp/net/network-stream.el (network-stream-open-shell):
      * lisp/obsolete/tls.el (open-tls-stream):
      * lisp/textmodes/tex-mode.el:
      Remove extraneous loads and autoloads of format-spec now that it is
      autoloaded and simplify its uses where possible.
      * test/lisp/battery-tests.el (battery-format): Test new format-spec
      * test/lisp/format-spec-tests.el (test-format-spec): Rename to...
      (format-spec) ...this, extending test cases.
      (test-format-unknown): Rename to...
      (format-spec-unknown): ...this, extending test cases.
      (test-format-modifiers): Rename to...
      (format-spec-flags): ...this.
      (format-spec-make, format-spec-parse-flags, format-spec-do-flags)
      (format-spec-do-flags-truncate, format-spec-do-flags-pad)
      (format-spec-do-flags-chop, format-spec-do-flags-case): New tests.
  6. 16 Jun, 2020 1 commit
  7. 15 May, 2020 1 commit
  8. 29 Mar, 2020 1 commit
    • Juri Linkov's avatar
      Support state changing VC operations on directories in Dired (bug#34949) · 7a6f5a51
      Juri Linkov authored
      * lisp/dired-aux.el (dired-vc-next-action): New command.
      (dired-vc-deduce-fileset): Rename from vc-dired-deduce-fileset in vc.el.
      * lisp/dired.el (dired-mode-map): Remap vc-next-action to
      * lisp/vc/vc-dir.el (vc-dir-mark-files): New function.
      (vc-dir-refresh): Run hook vc-dir-refresh-hook.
      * lisp/vc/vc.el (vc-deduce-fileset): Rename arg 'observer' to
      'not-state-changing' and document it in docstring.
      (vc-dired-deduce-fileset): Rename to dired-vc-deduce-fileset in dired-aux.el.
      * lisp/cedet/ede.el (ede-turn-on-hook, ede-minor-mode):
      * lisp/desktop.el (desktop-minor-mode-table): Rename the long ago
      obsolete vc-dired-mode to vc-dir-mode.
  9. 23 Mar, 2020 1 commit
    • Juri Linkov's avatar
      * lisp/dired.el (dired-mark-region): New defcustom (bug#39902) · 3b7cb5f3
      Juri Linkov authored
      * lisp/dired.el (dired-mark-if): Use dired-mark-region.
      (dired-mark): Use dired-mark-region.  Fix docstring.
      (dired-mark-files-regexp, dired-mark-files-containing-regexp)
      (dired-mark-symlinks, dired-mark-directories)
      (dired-mark-executables, dired-flag-auto-save-files)
      (dired-flag-backup-files): Mention dired-mark-region in docstring.
      * lisp/dired-aux.el (dired-compare-directories):
      * lisp/dired-x.el (dired-mark-unmarked-files, dired-mark-sexp):
      Mention dired-mark-region in docstring.
  10. 24 Feb, 2020 1 commit
    • Paul Eggert's avatar
      Add 'nofollow' flag to set-file-modes etc. · 9d626dff
      Paul Eggert authored
      This avoids some race conditions (Bug#39683).  E.g., if some other
      program changes a file to a symlink between the time Emacs creates
      the file and the time it changes the file’s permissions, using the
      new flag prevents Emacs from inadvertently changing the
      permissions of a victim in some completely unrelated directory.
      * admin/merge-gnulib (GNULIB_MODULES): Add fchmodat.
      * doc/lispref/files.texi (Testing Accessibility, Changing Files):
      * doc/lispref/os.texi (File Notifications):
      * etc/NEWS:
      Adjust documentation accordingly.
      * lib/chmodat.c, lib/fchmodat.c, lib/lchmod.c, m4/fchmodat.m4:
      * m4/lchmod.m4: New files, copied from Gnulib.
      * lib/gnulib.mk.in: Regenerate.
      * lisp/dired-aux.el (dired-do-chmod):
      * lisp/doc-view.el (doc-view-make-safe-dir):
      * lisp/emacs-lisp/autoload.el (autoload--save-buffer):
      * lisp/emacs-lisp/bytecomp.el (byte-compile-file):
      * lisp/eshell/em-pred.el (eshell-pred-file-mode):
      * lisp/files.el (backup-buffer-copy, copy-directory):
      * lisp/gnus/mail-source.el (mail-source-movemail):
      * lisp/gnus/mm-decode.el (mm-display-external):
      * lisp/gnus/nnmail.el (nnmail-write-region):
      * lisp/net/tramp-adb.el (tramp-adb-handle-file-local-copy)
      * lisp/net/tramp-sh.el (tramp-do-copy-or-rename-file-directly):
      * lisp/net/tramp-sudoedit.el (tramp-sudoedit-handle-write-region):
      * lisp/net/tramp.el (tramp-handle-write-region)
      * lisp/server.el (server-ensure-safe-dir):
      * lisp/url/url-util.el (url-make-private-file):
      When getting or setting file modes, avoid following symbolic links
      when the file is not supposed to be a symbolic link.
      * lisp/doc-view.el (doc-view-make-safe-dir):
      Omit no-longer-needed separate symlink test.
      * lisp/gnus/gnus-util.el (gnus-set-file-modes):
      * lisp/net/tramp.el (tramp-handle-file-modes):
      * lisp/net/tramp-gvfs.el (tramp-gvfs-handle-set-file-modes):
      * src/fileio.c (symlink_nofollow_flag): New function.
      (Ffile_modes, Fset_file_modes):
      Support an optional FLAG arg.  All C callers changed.
      * lisp/net/ange-ftp.el (ange-ftp-set-file-modes):
      * lisp/net/tramp-adb.el (tramp-adb-handle-set-file-modes):
      * lisp/net/tramp-sh.el (tramp-sh-handle-set-file-modes):
      * lisp/net/tramp-smb.el (tramp-smb-handle-set-file-modes):
      * lisp/net/tramp-sudoedit.el (tramp-sudoedit-handle-set-file-modes):
      Accept an optional FLAG arg that is currently ignored,
      and add a FIXME comment for it.
      * m4/gnulib-comp.m4: Regenerate.
  11. 08 Jan, 2020 1 commit
    • Eli Zaretskii's avatar
      Fix compression of directories in Dired · 6cd9ccb0
      Eli Zaretskii authored
      This fixes comporession and uncompression of directories on
      MS-Windows, but also on other systems.  The original code used
      ":" as the REGEXP of the directory entry in
      dired-compress-file-suffixes, which on Windows always matched any
      absolute file name, and can also match unusual file names on Posix
      hosts.  This false match would cause dired-compress-file to act as
      if we are decompressing a directory, but use a command suitable
      for compression, which would fail in interesting ways.
      We now use a REGEXP that can never match any valid file name.
      * lisp/dired-aux.el (dired-compress-file-suffixes): Make the
      "compress directory" entry's REGEXP really fail to match any valid
      file name.
      (dired-compress-file): Adapt to the change in
      dired-compress-file-suffixes.  (Bug#39024)
      (dired-compress): If the current file is a directory, or if the
      uncompressed file is a directory, don't remove the original from
      the listing, since it is left in the filesystem.
  12. 01 Jan, 2020 1 commit
  13. 29 Dec, 2019 1 commit
  14. 26 Dec, 2019 1 commit
    • Dmitry Gutov's avatar
      Speed up dired-do-find-regexp · ccd7cd2c
      Dmitry Gutov authored
      * lisp/dired-aux.el (dired-do-find-regexp): Speed up (bug#36857).
      Previously, 'find' was called for every marked file (for plain
      files and directories both).  Now 'find' is only called for
  15. 28 Nov, 2019 1 commit
    • Filipp Gunbin's avatar
      Do not call custom-reevaluate-setting in dired-isearch-filenames-end · 98f8c5fb
      Filipp Gunbin authored
        * lisp/dired-aux.el (dired-isearch-filenames-end)
        (dired-isearch-filenames, dired-isearch-filenames-regexp): Use
        temporary local variable for dired-isearch-filenames instead of
        custom-reevaluate-setting (Bug#30187).  Without this fix, the value
        set in .emacs with plain setq would be lost after one isearch.
  16. 16 Nov, 2019 1 commit
  17. 14 Nov, 2019 1 commit
  18. 12 Nov, 2019 1 commit
    • Juri Linkov's avatar
      * lisp/dired.el (dired-dwim-target): Add new choices (bug#35385) · d0351f4d
      Juri Linkov authored
      * lisp/dired.el (dired-dwim-target): Add choices
      dired-dwim-target-next and dired-dwim-target-recent.
      * lisp/dired-aux.el (dired-dwim-target-next)
      (dired-dwim-target-recent): New functions.
      (dired-dwim-target-directories): Call either of them.
      * doc/emacs/dired.texi (Operating on Files): Mention new
      preferences in dired-dwim-target.
  19. 10 Nov, 2019 1 commit
    • Stefan Kangas's avatar
      Make dired-get-subdir-min obsolete · 0154e41b
      Stefan Kangas authored
      * lisp/dired.el (dired-get-subdir-min): Redefine as obsolete function
      alias for 'cdr'.  (Bug#11571)
      (dired-get-subdir, dired-get-subdir-max, dired-clear-alist)
      (dired-next-subdir, dired-current-directory):
      * lisp/dired-aux.el (dired-rename-subdir-2)
      (dired-alist-sort, dired-insert-subdir-del)
      (dired-insert-subdir-doupdate, dired-goto-subdir)
      (dired-hide-subdir, dired-hide-all): Use 'cdr' instead of
      the above obsolete function.
      (dired-subdir-alist): Doc fix.
      Co-authored-by: default avatarDrew Adams <drew.adams@oracle.com>
  20. 06 Nov, 2019 1 commit
  21. 26 Oct, 2019 1 commit
    • Juri Linkov's avatar
      dired-dwim-target uses most recently visited window instead of next window. · c6667cc6
      Juri Linkov authored
      * doc/emacs/dired.texi (Operating on Files): Document behavior change.
      * lisp/dired-aux.el (dired-dwim-target-directories): New function.
      (dired-dwim-target-directory, dired-dwim-target-defaults): Use it
      to get the most recently used window instead of the next window (bug#35385).
      * lisp/dired.el (dired-dwim-target): Doc fix.
      * test/lisp/dired-tests.el: Remove unnecessary require and pacify
  22. 14 Oct, 2019 2 commits
  23. 23 Sep, 2019 1 commit
  24. 23 Aug, 2019 1 commit
  25. 02 Aug, 2019 1 commit
  26. 01 Aug, 2019 1 commit
  27. 26 Jul, 2019 3 commits
  28. 13 Jul, 2019 1 commit
    • Tino Calancha's avatar
      End predicate `dired-in-this-tree' with '-p' · 4b73c0cd
      Tino Calancha authored
      * lisp/dired.el(dired-in-this-tree-p): Rename from `dired-in-this-tree'.
      Add docstring.
      (dired-in-this-tree): Define an alias to `dired-in-this-tree-p'.
      * lisp/dired-aux.el (dired-tree-down, dired-kill-tree)
      (dired-insert-subdir, dired-rename-subdir): Update all callers (bug#32892).
  29. 08 Jul, 2019 1 commit
  30. 24 Jun, 2019 1 commit
    • Alexander Gramiak's avatar
      Add Zstandard compression support for dired · c32cc627
      Alexander Gramiak authored
      * lisp/dired-aux.el (dired-compress-file-suffixes): Add suffixes for
      zstd compressed tarballs and other files.
      (dired-compress-file): Treat options found in
      `dired-compress-file-suffixes' as arguments instead of part of the
      program name.
  31. 21 Jun, 2019 1 commit
    • Stefan Monnier's avatar
      * lisp/emacs-lisp/bytecomp.el (byte-compile-dynamic): Mark obsolete · 436ccc69
      Stefan Monnier authored
      See bug#11649 for an example problem, and emacs-devel discussion
      «Prickliness of the "invalid byte code" stuff».
      * lisp/wid-edit.el, lisp/wdired.el, lisp/vc/pcvs-util.el:
      * lisp/progmodes/executable.el, lisp/mail/sendmail.el:
      * lisp/emacs-lisp/cl-seq.el, lisp/emacs-lisp/cl-macs.el:
      * lisp/emacs-lisp/cl-lib.el, lisp/emacs-lisp/cl-extra.el:
      * lisp/dired-x.el, lisp/dired-aux.el, lisp/calendar/calendar.el:
      Don't use byte-compile-dynamic any more.
  32. 30 May, 2019 1 commit
  33. 25 May, 2019 1 commit
    • Paul Eggert's avatar
      Go back to "Maintainer: emacs-devel@gnu.org" · f744797a
      Paul Eggert authored
      Restore lines saying "Maintainer: emacs-devel@gnu.org" when there is
      no special maintainer for a file.  Although this wasn't documented
      it was common practice and removing the lines didn't have consensus.
  34. 24 May, 2019 1 commit
    • Dmitry Gutov's avatar
      Support "reverting" Xref buffers (bug#35702) · 62349fe8
      Dmitry Gutov authored
      * lisp/progmodes/xref.el (xref--fetcher): New variable.
      (xref--xref-buffer-mode-map): Add binding for 'g'.
      (xref--revert-xref-buffer): New command.
      (xref--show-xref-buffer): Accept a function as the first argument.
      (xref--show-xrefs): Same.
      (xref--find-xrefs): Pass the above a fetcher function.
      * lisp/progmodes/project.el (project-find-regexp)
      (project-or-external-find-regexp): Same.
      * lisp/dired-aux.el (dired-do-find-regexp): Same.
  35. 22 May, 2019 1 commit
    • Dmitry Gutov's avatar
      Separate xref-find-definitions' behavior from other commands · 49a363c8
      Dmitry Gutov authored
      * lisp/progmodes/xref.el (xref-show-definitions-function):
      New variable.
      (xref--show-defs): Split off from xref--show-xrefs.
      (xref--find-definitions): Use it.
      (xref--not-found-error): New function.
      (xref--show-xrefs): Simplify.  Show the list buffer even when
      there is just one item in the list.  Remove the last argument.
      * lisp/dired-aux.el (dired-do-find-regexp): Update accordingly.