summaryrefslogtreecommitdiff
path: root/lisp/misc.el
AgeCommit message (Collapse)Author
2026-01-01; Add 2026 to copyright years.Sean Whitton
2025-03-09Make second arg to defvar-local optionalStefan Kangas
This change allows declaring a variable both special and buffer-local like so: (defvar-local foo) * lisp/subr.el (defvar-local): Make second argument optional. * test/lisp/subr-tests.el (subr-test-defvar-local): New test. * doc/lispref/variables.texi (Creating Buffer-Local): Document above change. * etc/NEWS: * lisp/mb-depth.el (minibuffer-depth-overlay): * lisp/minibuf-eldef.el (minibuf-eldef-initial-input) (minibuf-eldef-initial-buffer-length) (minibuf-eldef-showing-default-in-prompt, minibuf-eldef-overlay): * lisp/misc.el (list-dynamic-libraries--loaded-only-p): * lisp/simple.el (minibuffer-history-isearch-message-overlay): Use above new one-argument form of 'defvar-local'.
2025-01-01Update copyright year to 2025Paul Eggert
Run "TZ=UTC0 admin/update-copyright".
2024-01-02Merge from savannah/emacs-29Po Lu
dc4e6b13296 ; Update copyright years in more files 64b37776318 ; Run set-copyright from admin.el 8e1c56ae467 ; Add 2024 to copyright years # Conflicts: # doc/misc/modus-themes.org # doc/misc/texinfo.tex # etc/NEWS # etc/refcards/ru-refcard.tex # etc/themes/modus-operandi-theme.el # etc/themes/modus-themes.el # etc/themes/modus-vivendi-theme.el # lib/alloca.in.h # lib/binary-io.h # lib/c-ctype.h # lib/c-strcasecmp.c # lib/c-strncasecmp.c # lib/careadlinkat.c # lib/cloexec.c # lib/close-stream.c # lib/diffseq.h # lib/dup2.c # lib/filemode.h # lib/fpending.c # lib/fpending.h # lib/fsusage.c # lib/getgroups.c # lib/getloadavg.c # lib/gettext.h # lib/gettime.c # lib/gettimeofday.c # lib/group-member.c # lib/malloc.c # lib/md5-stream.c # lib/md5.c # lib/md5.h # lib/memmem.c # lib/memrchr.c # lib/nanosleep.c # lib/save-cwd.h # lib/sha1.c # lib/sig2str.c # lib/stdlib.in.h # lib/strtoimax.c # lib/strtol.c # lib/strtoll.c # lib/time_r.c # lib/xalloc-oversized.h # lisp/auth-source-pass.el # lisp/emacs-lisp/lisp-mnt.el # lisp/emacs-lisp/timer.el # lisp/info-look.el # lisp/jit-lock.el # lisp/loadhist.el # lisp/mail/rmail.el # lisp/net/ntlm.el # lisp/net/webjump.el # lisp/progmodes/asm-mode.el # lisp/progmodes/project.el # lisp/progmodes/sh-script.el # lisp/textmodes/flyspell.el # lisp/textmodes/reftex-toc.el # lisp/textmodes/reftex.el # lisp/textmodes/tex-mode.el # lisp/url/url-gw.el # m4/alloca.m4 # m4/clock_time.m4 # m4/d-type.m4 # m4/dirent_h.m4 # m4/dup2.m4 # m4/euidaccess.m4 # m4/fchmodat.m4 # m4/filemode.m4 # m4/fsusage.m4 # m4/getgroups.m4 # m4/getloadavg.m4 # m4/getrandom.m4 # m4/gettime.m4 # m4/gettimeofday.m4 # m4/gnulib-common.m4 # m4/group-member.m4 # m4/inttypes.m4 # m4/malloc.m4 # m4/manywarnings.m4 # m4/mempcpy.m4 # m4/memrchr.m4 # m4/mkostemp.m4 # m4/mktime.m4 # m4/nproc.m4 # m4/nstrftime.m4 # m4/pathmax.m4 # m4/pipe2.m4 # m4/pselect.m4 # m4/pthread_sigmask.m4 # m4/readlink.m4 # m4/realloc.m4 # m4/sig2str.m4 # m4/ssize_t.m4 # m4/stat-time.m4 # m4/stddef_h.m4 # m4/stdint.m4 # m4/stdio_h.m4 # m4/stdlib_h.m4 # m4/stpcpy.m4 # m4/strnlen.m4 # m4/strtoimax.m4 # m4/strtoll.m4 # m4/time_h.m4 # m4/timegm.m4 # m4/timer_time.m4 # m4/timespec.m4 # m4/unistd_h.m4 # m4/warnings.m4 # nt/configure.bat # nt/preprep.c # test/lisp/register-tests.el
2024-01-02; Add 2024 to copyright yearsPo Lu
2023-07-03; * lisp/misc.el (duplicate-region-final-position): Fix version info.Michael Albinus
2023-07-01Add duplicate-region-final-position (bug#64185)Mattias Engdegård
* lisp/misc.el (duplicate-region-final-position): New defcustom. (duplicate-dwim): Use it. * lisp/rect.el (rectangle--duplicate-right): Add displacement argument. * test/lisp/misc-tests.el (misc--duplicate-dwim): Extend test.
2023-07-01Merge from origin/emacs-29Eli Zaretskii
a722e7dd152 Merge branch 'emacs-29' of git.savannah.gnu.org:/srv/git/... 65f146cf1c2 ; * lisp/calculator.el (calculator-need-3-lines): Fix las... 9e8386bdacc Support cons cell as value of ':line-width' box attribute 1d2ba6b363b ; * admin/notes/tree-sitter/treesit_record_change: Update. 02b6be892fa Add missing calls to treesit_record_change in editfns.c e982192e933 Call treesit_record_change in subst-char-in-region (bug#6... ddbb11f5657 ; * lisp/misc.el (duplicate-line-final-position): Fix las... cecbe92d5d9 ; * lisp/misc.el (duplicate-line-final-position): doc pre... 042f0d6a14c ; Fix documentation of ':box' face attribute # Conflicts: # etc/NEWS
2023-06-29; * lisp/misc.el (duplicate-line-final-position): Fix last doc change.Eli Zaretskii
Repeat after me: "The first line of a doc string must be a single complete sentence."
2023-06-29; * lisp/misc.el (duplicate-line-final-position): doc precisionMattias Engdegård
2023-06-29* lisp/misc.el (duplicate-line-final-position): New defcustom (bug#64185).Juri Linkov
* lisp/misc.el (duplicate-line): Use it. * test/lisp/misc-tests.el (misc--duplicate-line): Add tests for duplicate-line-final-position.
2023-06-29* lisp/misc.el (duplicate-line-final-position): New defcustom (bug#64185).Juri Linkov
* lisp/misc.el (duplicate-line): Use it. * test/lisp/misc-tests.el (misc--duplicate-line): Add tests for duplicate-line-final-position. Don't merge to master.
2023-06-28Speed up duplicate-dwim and duplicate-line by another factor 10Mattias Engdegård
* lisp/misc.el (duplicate--insert-copies): New. (duplicate-line, duplicate-dwim): Call it.
2023-06-27Speed up duplicate-line by a factor of 2Mattias Engdegård
* lisp/misc.el (duplicate-line): Add the newline to the string to be inserted instead of inserting it separately. This makes duplicate-line as fast as duplicate-dwim with a contiguous region. Both could easily be made faster yet by making the code more complex.
2023-05-31; * lisp/misc.el (forward-to-word, backward-to-word): Doc fix.Eli Zaretskii
2023-05-31Make forward and backward-to-word arg optionalZaz Brown
* lisp/misc.el (forward-to-word, backward-to-word): Make the argument optional. (Bug#63626) Copyright-paperwork-exempt: yes
2023-01-01; Add 2023 to copyright years.Eli Zaretskii
2022-07-26Add duplicate-dwim (bug#56418)Mattias Engdegård
Like duplicate-line but duplicates the region instead if active. Rectangular regions are duplicated on the right-hand side. The region remains active afterwards, to facilitate further duplication or other operations on the same text. * lisp/rect.el (rectangle--duplicate-right): * lisp/misc.el (duplicate-dwim): New. * test/lisp/misc-tests.el (misc--duplicate-dwim): New test. * etc/NEWS: Announce.
2022-07-03Quote some literal keys to get help-key-binding faceStefan Kangas
* lisp/align.el (align): * lisp/bindings.el (undo-repeat-map): * lisp/calc/calc-embed.el (calc-do-embedded): * lisp/calc/calc-prog.el (calc-user-define-invocation): * lisp/calc/calc-yank.el (calc--edit-mode): * lisp/comint.el (comint-history-isearch) * lisp/dired.el (dired-mode): * lisp/emulation/viper.el (viper-mode): * lisp/erc/erc-button.el (erc-button-face): * lisp/erc/erc-track.el (erc-track-enable-keybindings): * lisp/gnus/gnus-art.el (gnus-article-button-face): * lisp/gnus/gnus-eform.el (gnus-edit-form): * lisp/gnus/gnus-sum.el (gnus-summary-stop-at-end-of-message) (gnus-summary-goto-unread): * lisp/icomplete.el (icomplete-show-matches-on-no-input): * lisp/image-mode.el (image-scroll-up): * lisp/international/iso-transl.el (iso-transl-set-language): * lisp/isearch.el (isearch-forward-regexp): * lisp/misc.el (butterfly): * lisp/outline.el (outline-minor-mode-cycle-filter) (outline-minor-mode-cycle): * lisp/progmodes/grep.el (rgrep): * lisp/progmodes/gud.el (gud-gdb-repeat-map, gud-sdb-repeat-map) (gud-dbx-repeat-map, gud-xdb-repeat-map, gud-perldb-repeat-map) (gud-pdb-repeat-map, gud-guiler-repeat-map, gud-jdb-repeat-map): * lisp/progmodes/idlw-shell.el (idlwave-shell-graphics-window-size) (idlwave-shell-mode): * lisp/progmodes/idlwave.el (idlwave-shell-debug-modifiers) (idlwave-list-shell-load-path-shadows): * lisp/progmodes/python.el (python-shell-get-process-or-error): * lisp/repeat.el (repeat-check-key): * lisp/replace.el (query-replace, query-replace-regexp) (read-regexp): * lisp/simple.el (read-extended-command-predicate): * lisp/tab-bar.el (tab-bar-switch-repeat-map) (tab-bar-move-repeat-map): * lisp/term.el (ansi-term): * lisp/textmodes/reftex-index.el (reftex-index-phrases-set-macro-key): * lisp/vc/emerge.el (emerge-scroll-left, emerge-scroll-right): * lisp/windmove.el: * lisp/winner.el (winner-mode): Quote literal keys to get 'help-key-binding' face. * lisp/comint.el (comint-insert-previous-argument): Use regular quotes.
2022-06-22duplicate-line: fix optional argument and add test (bug#46621)Mattias Engdegård
The test assumes that the current semantics are intended and desired, which may or may not be true, but it's better than not having any at all. * lisp/misc.el (duplicate-line): Don't crash if called with no argument. * test/lisp/misc-tests.el (misc--duplicate-line): New test.
2022-06-18; * lisp/misc.el (duplicate-line): Doc fix.Eli Zaretskii
2022-06-17Fix copy-from-above-command doc string typeLars Ingebrigtsen
* lisp/misc.el (copy-from-above-command): Fix doc string typo.
2022-06-17Add new command `duplicate-line'Lars Ingebrigtsen
* lisp/misc.el (copy-from-above-command): Mention it. (duplicate-line): New command (bug#46621).
2022-05-21zap-to-char: case sensitive for upper-case charactersTino Calancha
In interactive calls, behave case-sensitively if the given char is an upper-case character. Same for zap-up-to-char (Bug#54804). This is analog to what the user-level incremental search feature does. * lisp/misc.el (zap-up-to-char): Add an optional arg INTERACTIVE. Perform a case-sensitive search when INTERACTIVE is non-nil and CHAR is an upper-case character. * lisp/simple.el (zap-to-char): Same. * etc/NEWS (Editing Changes in Emacs 29.1): Announce this change. * test/lisp/misc-tests.el (misc-test-zap-up-to-char): Add test cases. * test/lisp/simple-tests.el (with-zap-to-char-test): Add helper macro. (simple-tests-zap-to-char): Add a test.
2022-01-01; Add 2022 to copyright years.Eli Zaretskii
2021-02-23Small fixesJuri Linkov
* lisp/emacs-lisp/seq.el (seq-contains): Move the ‘declare’ form after the docstring. * lisp/misc.el (copy-from-above-command): Fix whitespace regexp.
2021-01-01Update copyright year to 2021Paul Eggert
Run "TZ=UTC0 admin/update-copyright".
2020-10-24; Prefer https to http in more URLsStefan Kangas
These were all tested and confirmed working.
2020-09-25Use the char history in zap-up-to-charTino Calancha
* lisp/misc.el (zap-up-to-char): Use read-char-from-minibuffer (bug#39154).
2020-04-26Use lexical-binding in misc.el and add testsStefan Kangas
* lisp/misc.el: Use lexical-binding. * test/lisp/misc-tests.el: New file.
2020-04-25Improve list-dynamic-libraries when alist emptyStefan Kangas
* lisp/misc.el (list-dynamic-libraries--refresh): Improve list format and show message when 'dynamic-library-alist' is empty.
2020-01-01Update copyright year to 2020Paul Eggert
Run "TZ=UTC0 admin/update-copyright $(git ls-files)".
2019-05-25Go back to "Maintainer: emacs-devel@gnu.org"Paul Eggert
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.
2019-05-19Fixes for "Maintainer:" and related linesPaul Eggert
Mostly, this just removes "Maintainer: emacs-devel@gnu.org" lines, which are not that useful. It also cleans up and regularizes a few similar lines.
2019-01-01Update copyright year to 2019Paul Eggert
Run 'TZ=UTC0 admin/update-copyright $(git ls-files)'.
2018-01-01Update copyright year to 2018Paul Eggert
Run admin/update-copyright.
2017-09-13Prefer HTTPS to FTP and HTTP in documentationPaul Eggert
Most of this change is to boilerplate commentary such as license URLs. This change was prompted by ftp://ftp.gnu.org's going-away party, planned for November. Change these FTP URLs to https://ftp.gnu.org instead. Make similar changes for URLs to other organizations moving away from FTP. Also, change HTTP to HTTPS for URLs to gnu.org and fsf.org when this works, as this will further help defend against man-in-the-middle attacks (for this part I omitted the MS-DOS and MS-Windows sources and the test tarballs to keep the workload down). HTTPS is not fully working to lists.gnu.org so I left those URLs alone for now.
2017-01-01Merge from origin/emacs-25Paul Eggert
2e2a806 Fix copyright years by hand 5badc81 Update copyright year to 2017
2016-12-31Update copyright year to 2017Paul Eggert
Run admin/update-copyright.
2016-10-22Autoload all commands from misc.elJorgen Schaefer
Only two of the commands there were autoloaded, one of which is an easter egg. * lisp/miscl.el (copy-from-above-command): * lisp/miscl.el (zap-up-to-char): * lisp/miscl.el (mark-beginning-of-buffer): * lisp/miscl.el (mark-end-of-buffer): * lisp/miscl.el (upcase-char): * lisp/miscl.el (forward-to-word): * lisp/miscl.el (backward-to-word): Add autoload cookie.
2016-01-01Update copyright year to 2016Paul Eggert
Run admin/update-copyright.
2015-01-01Update copyright year to 2015Paul Eggert
Run admin/update-copyright.
2014-02-09Replace "Maintainer: FSF" with the emacs-devel mailing addressGlenn Morris
2014-01-01Update copyright year to 2014 by running admin/update-copyright.Paul Eggert
2013-01-01Update copyright notices for 2013.Paul Eggert
2012-08-22misc.el (forward-to-word, backward-to-word): Use (interactive "^p").Bastien Guerry
Thanks to Le Wang for the patch.
2012-04-10Record and display absolute path of DLLs loaded (bug#10424).Juanma Barranquero
* lisp/misc.el (list-dynamic-libraries--loaded): New function. (list-dynamic-libraries--refresh): Use it. * src/w32.c (w32_delayed_load): Record the full path of the library being loaded.
2012-01-05Add 2012 to FSF copyright years for Emacs filesGlenn Morris
2011-06-21lisp/misc.el (list-dynamic-libraries): Fix computation of header fields.Juanma Barranquero
2011-05-10lisp/misc.el: Require tabulated-list.el during compilation.Juanma Barranquero