1. 12 Aug, 2017 6 commits
    • Michael Albinus's avatar
      Implement EXCL of write-region for Tramp · ec5cfaa4
      Michael Albinus authored
      * 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.
      ec5cfaa4
    • Eli Zaretskii's avatar
      Adapt Proced display to display-line-numbers · e94b0d4d
      Eli Zaretskii authored
      * lisp/proced.el (proced-header-line): Account for the width taken
      by display-line-numbers.  (Bug#27895)
      e94b0d4d
    • Eli Zaretskii's avatar
      Adapt tabulated list when display-line-number is turned on · a955d795
      Eli Zaretskii authored
      * lisp/emacs-lisp/tabulated-list.el (tabulated-list-mode): Add
      a hook to revert the display when display-line-numbers is turned
      on.  (Bug#27895)
      a955d795
    • Eli Zaretskii's avatar
      Use Gnulib 'tempname' on MS-Windows · 8cc8ad02
      Eli Zaretskii authored
      * lib-src/ntlib.h (mkdir, open): Remove redefinitions.  They are
      now in nt/inc/ms-w32.h.
      * lib-src/ntlib.c (sys_mkdir, sys_open): New functions.
      (mkostemp): Remove.
      
      * src/w32.c (mkostemp): Remove.
      (sys_mkdir): Accept a second (unused) argument.
      * src/fileio.c (Fmake_directory_internal): Remove the WINDOWSNT
      specific call to mkdir.  (Bug#28023)
      
      * nt/inc/ms-w32.h (mkdir): Remove from "#ifdef emacs" and redefine
      to accept 2 arguments.
      (open): Remove from "#ifdef emacs".
      * nt/mingw-cfg.site (ac_cv_func_mkostemp): Remove.
      * nt/gnulib-cfg.mk (OMIT_GNULIB_MODULE_mkostemp)
      (OMIT_GNULIB_MODULE_tempname): Remove.
      8cc8ad02
    • Alexander Gramiak's avatar
      Add new face 'header-line-highlight' · 84288cf4
      Alexander Gramiak authored
      * lisp/faces.el: Define the face.
      * lisp/emacs-lisp/tabulated-list.el (tabulated-list-init-header):
      * lisp/info.el (Info-fontify-node): Use the new face.
      * doc/emacs/display.texi (Standard Faces):
      * etc/NEWS: Document the new face.  (Bug#28033)
      84288cf4
    • Arash Esbati's avatar
      Make a case-sensitive match for strings · 19d2b4a3
      Arash Esbati authored
      * lisp/textmodes/reftex.el (reftex-typekey-check): Temporarily
      let-bind `case-fold-search' to nil in order to be case-sensitive
      when matching a string.  (Bug#27518)
      19d2b4a3
  2. 11 Aug, 2017 3 commits
    • Stephen Berman's avatar
      Fix a minor todo-mode regression · e3ed43f4
      Stephen Berman authored
      * lisp/calendar/todo-mode.el (todo-get-overlay): Wrap in
      save-excursion.  This fixes a regression introduced by the fix
      for bug#27609, whereby trying to raise the priority of the
      first item or lower the priority of the last item, which
      should be noops, moves point to the item's start.  Clarify
      comment.
      
      * test/lisp/calendar/todo-mode-tests.el
      (todo-test-raise-lower-priority): Add test cases for trying to
      raise first item and lower last item.
      (with-todo-test): Clear abbreviated-home-dir, since we change HOME.
      (todo-test-toggle-item-header02): Remove ":expected-result
      :failed" and tests of point after todo-next-item, since the
      effect when using Todo mode is not reproducible in the test
      environment.  Add commentary about this.
      e3ed43f4
    • Paul Eggert's avatar
      Improve performance for rename-file etc. · a56e6e79
      Paul Eggert authored
      Although this does not fix Bug#27986, it is a step forward.
      I plan to propose a more-significant patch later.
      * lisp/files.el (directory-name-p): Move from here ...
      * src/fileio.c (Fdirectory_name_p): ... to here.
      (directory_like, cp_like_target): New static functions.
      (Fcopy_file, Frename_file, Fadd_name_to_file)
      (Fmake_symbolic_link):
      Use them, to avoid directory-testing syscalls on file names that
      must be directories if they exist.  Omit unnecessary
      initializations and CHECK_STRING calls.
      (Frename_file): Don't call file_name_case_insensitive_p
      twice on the same file.  Compare both file names expanded, instead
      of the old name expanded and the new one unexpanded.
      a56e6e79
    • Noam Postavsky's avatar
      Respect buffer-local value of tags-table-list (Bug#27772) · 179499cd
      Noam Postavsky authored
      * lisp/progmodes/etags.el (visit-tags-table-buffer): Save the current
      buffer around the `tags-table-including' calls so as to get buffer
      local variables from the right buffer later.
      * test/lisp/progmodes/etags-tests.el (etags-visit-tags-table-buffer):
      New test.
      * test/lisp/progmodes/etags-tests.el (etags-tests--test-dir): New
      constant.
      (etags-bug-158, etags-bug-23164): Use it so that when running the test
      interactively, setting EMACS_TEST_DIRECTORY is not needed.
      179499cd
  3. 09 Aug, 2017 5 commits
    • Tom Tromey's avatar
      Fix auto-filling regression · 81656add
      Tom Tromey authored
      Bug#28003
      * lisp/newcomment.el (comment-indent-new-line): Check
      comment-auto-fill-only-comments.  Reverts earlier change.
      * lisp/simple.el (internal-auto-fill): Call auto-fill-function, not
      do-auto-fill.
      81656add
    • Paul Eggert's avatar
      Merge from gnulib · 904be8c4
      Paul Eggert authored
      This incorporates:
      2017-08-09 tempname: do not depend on secure_getenv
      2017-08-08 extensions: add _OPENBSD_SOURCE
      2017-08-06 manywarnings: Add support for C++
      2017-08-06 warnings, manywarnings: Add support for multiple languages
      * admin/merge-gnulib: Don't use m4/manywarnings-c++.m4.
      * lib/gnulib.mk.in, m4/gnulib-comp.m4: Regenerate.
      * lib/secure_getenv.c, m4/secure_getenv.m4: Remove.
      * lib/tempname.c, m4/extensions.m4, m4/manywarnings.m4, m4/warnings.m4:
      Copy from gnulib.
      904be8c4
    • Eli Zaretskii's avatar
      Fix crashing emacs-module tests on MS-Windows · 7fc27ea7
      Eli Zaretskii authored
      * src/w32fns.c (syms_of_w32fns) <w32-disable-abort-dialog>: New
      variable.
      (emacs_abort): If w32-disable-abort-dialog is non-nil, abort right
      away, without displaying the Abort dialog, which waits for the user.
      
      * test/src/emacs-module-tests.el (module--test-assertion): Run the
      inferior Emacs with the w32 abort dialog disabled.  Expect the
      status of the aborted Emacs sub-process to be 3 on MS-Windows and
      2 on MS-DOS.
      7fc27ea7
    • Tino Calancha's avatar
      dired-delete-file: Dont't ask for empty dirs · da4438e1
      Tino Calancha authored
      * lisp/dired.el (dired--yes-no-all-quit-help): New defun.
      (dired-delete-file): Use it.  Dont't ask for empty dirs (Bug#27940).
      
      * test/lisp/dired-tests.el (dired-test-with-temp-dirs):
      New auxiliar macro.
      (dired-test-bug27940): Add new test.
      da4438e1
    • Tino Calancha's avatar
      Ask files for deletion in buffer order: top first, botton later · 9ecbdeea
      Tino Calancha authored
      * lisp/dired.el (dired-do-flagged-delete, dired-do-delete):
      Call `nreverse' t invert the output of `dired-map-over-marks'.
      9ecbdeea
  4. 08 Aug, 2017 10 commits
    • Alexander Gramiak's avatar
      Use help-mode xrefs in describe-font · 97237821
      Alexander Gramiak authored
      * lisp/international/mule-diag.el (describe-font): Use help-setup-xref
      (Bug#27890).
      97237821
    • Katsumi Yamaoka's avatar
      Don't try to jump to non-existent part (bug#28013) · 2ef880cc
      Katsumi Yamaoka authored
      * lisp/gnus/gnus-art.el (gnus-article-edit-part): Don't try to jump to
      the next part if there is the only one part in the article (bug#28013).
      2ef880cc
    • Mark Oteiza's avatar
      Replace some uses of eval · 63b5a4a6
      Mark Oteiza authored
      There are a number of places where eval is used unnecessarily to get
      or set the value of a symbol.
      * lisp/calendar/calendar.el (diary-date-forms): Use default-value in
      custom setter.
      * lisp/desktop.el (desktop-clear): Use set-default instead.
      * lisp/international/ogonek.el (ogonek-read-encoding): Use
      symbol-value.
      63b5a4a6
    • Mark Oteiza's avatar
      Convert uses of looking-at in viper-ex to following-char · 884d43b4
      Mark Oteiza authored
      * lisp/emulation/viper-ex.el (viper-get-ex-token): Bind
      (following-char) and use it in the subsequent cond's clauses.
      (viper-ex, ex-quit, viper-get-ex-file): Use following-char instead.
      Convert single branch ifs to when
      884d43b4
    • Mark Oteiza's avatar
      Some cleanup in message.el · 4cb0bdd6
      Mark Oteiza authored
      * lisp/gnus/message.el (message-cross-post-insert-note):
      (message-strip-forbidden-properties): Mark unused args.
      (message-canlock-generate): Remove extinct variable
      sha1-maximum-internal-length.
      (message-make-mail-followup-to): Use loop's thereis clause.
      4cb0bdd6
    • Paul Eggert's avatar
      Document make-temp-name magic limitations · 7d1115e0
      Paul Eggert authored
      * doc/lispref/files.texi (Unique File Names):
      * src/fileio.c (Fmake_temp_name): Document that make-temp-name
      does not guarantee uniqueness on magic file names.
      7d1115e0
    • Tom Tromey's avatar
      Show number of errors in compilation-mode mode-line · 846870e5
      Tom Tromey authored
      Bug#25354
      * lisp/progmodes/compile.el (compilation-num-errors-found): Provide
      default value.
      (compilation-num-warnings-found, compilation-num-infos-found): New
      defvars.
      (compilation-mode-line-errors): New defconst.
      (compilation-face): Remove.
      (compilation-type, compilation--note-type): New functions.
      (compilation-parse-errors): Call compilation--note-type.
      (compilation-start): Include compilation-mode-line-errors in
      mode-line-process.
      (compilation-setup): Initialize compilation-num-* variables to 0.
      (compilation-handle-exit): Include compilation-mode-line-errors in
      mode-line-process.
      * doc/emacs/building.texi (Compilation): Document new feature.
      846870e5
    • Mark Oteiza's avatar
      Do some cleanup in mailcap.el · c3445aed
      Mark Oteiza authored
      * 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.
      c3445aed
    • Tino Calancha's avatar
      query-replace: Undo replacements performed with 'comma · 919ac3ae
      Tino Calancha authored
      During a `query-replace', the char ',' replaces the character
      at point and doesn't move point;  right after, the char 'u'
      must undo such replacement (Bug#27268).
      * lisp/replace.el (replace--push-stack):
      New macro extracted from `perform-replace'.
      (perform-replace): Use it.
      * test/lisp/replace-tests.el (query-replace--undo): Add test.
      919ac3ae
    • Noam Postavsky's avatar
      bec5b602
  5. 07 Aug, 2017 16 commits