From 14dcaadddebac4436aa9ed0a71fa1f9fe7729452 Mon Sep 17 00:00:00 2001 From: Daniel Weschke Date: Tue, 11 Mar 2025 21:14:26 +0100 Subject: [PATCH] update packages --- lisp/anaconda-mode/anaconda-mode-pkg.el | 4 +- lisp/anaconda-mode/anaconda-mode.el | 10 +- lisp/anaconda-mode/anaconda-mode.py | 16 +- lisp/company/company-capf.el | 7 +- lisp/company/company-pkg.el | 4 +- lisp/company/company.info | 152 +- lisp/counsel/counsel-pkg.el | 4 +- lisp/counsel/counsel.el | 356 +- lisp/dash/dash.info | 782 ++-- lisp/dashboard/dashboard-pkg.el | 4 +- lisp/dashboard/dashboard.el | 1 + lisp/emacsql-sqlite/emacsql-sqlite-pkg.el | 2 +- lisp/emacsql/emacsql-pkg.el | 4 +- lisp/emacsql/emacsql.el | 4 +- lisp/ess/ess.info | 2606 ++++++------- lisp/git-commit/git-commit-pkg.el | 2 +- lisp/git-commit/git-commit.el | 2 + lisp/helpful/helpful-pkg.el | 4 +- lisp/helpful/helpful.el | 4 +- lisp/ivy/ivy.info | 152 +- lisp/ledger-mode/ledger-mode.info | 156 +- lisp/llama/llama-pkg.el | 9 + lisp/llama/llama.el | 552 +++ lisp/magit-section/magit-section-pkg.el | 6 +- lisp/magit-section/magit-section.el | 100 +- lisp/magit-section/magit-section.info | 38 +- lisp/magit/AUTHORS.md | 1 + lisp/magit/magit-apply.el | 52 +- lisp/magit/magit-base.el | 20 +- lisp/magit/magit-branch.el | 20 +- lisp/magit/magit-clone.el | 12 +- lisp/magit/magit-commit.el | 5 +- lisp/magit/magit-diff.el | 52 +- lisp/magit/magit-ediff.el | 4 +- lisp/magit/magit-git.el | 8 +- lisp/magit/magit-log.el | 8 +- lisp/magit/magit-mode.el | 31 +- lisp/magit/magit-patch.el | 6 +- lisp/magit/magit-pkg.el | 10 +- lisp/magit/magit-process.el | 6 +- lisp/magit/magit-remote.el | 8 +- lisp/magit/magit-sequence.el | 4 +- lisp/magit/magit-status.el | 14 +- lisp/magit/magit-version.el | 2 +- lisp/magit/magit-wip.el | 33 - lisp/magit/magit.el | 8 +- lisp/magit/magit.info | 866 ++--- lisp/markdown-mode/markdown-mode-pkg.el | 4 +- lisp/markdown-mode/markdown-mode.el | 93 +- lisp/ol-notmuch/ol-notmuch-pkg.el | 18 +- lisp/ol-notmuch/ol-notmuch.el | 21 +- lisp/org-appear/org-appear-pkg.el | 6 +- lisp/org-appear/org-appear.el | 14 +- lisp/org-ref/contrib.el | 16 +- lisp/org-ref/doi-utils.el | 16 +- lisp/org-ref/nist-webbook.el | 2 +- lisp/org-ref/openalex.el | 938 ++++- lisp/org-ref/org-ref-arxiv.el | 25 +- lisp/org-ref/org-ref-bibliography-links.el | 8 +- lisp/org-ref/org-ref-bibtex.el | 14 +- lisp/org-ref/org-ref-citation-links.el | 52 +- lisp/org-ref/org-ref-compat.el | 8 +- lisp/org-ref/org-ref-core.el | 7 +- lisp/org-ref/org-ref-export.el | 62 +- lisp/org-ref/org-ref-glossary.el | 238 +- lisp/org-ref/org-ref-helm.el | 2 +- lisp/org-ref/org-ref-isbn.el | 4 +- lisp/org-ref/org-ref-ivy.el | 2 +- lisp/org-ref/org-ref-label-link.el | 2 +- lisp/org-ref/org-ref-latex.el | 208 +- lisp/org-ref/org-ref-misc-links.el | 2 +- lisp/org-ref/org-ref-natbib-bbl-citeproc.el | 10 +- lisp/org-ref/org-ref-pdf.el | 2 +- lisp/org-ref/org-ref-pgk.el | 4 +- lisp/org-ref/org-ref-pkg.el | 7 +- lisp/org-ref/org-ref-publish.el | 2 +- lisp/org-ref/org-ref-pubmed.el | 2 +- lisp/org-ref/org-ref-ref-links.el | 10 +- lisp/org-ref/org-ref-sci-id.el | 2 +- lisp/org-ref/org-ref-scifinder.el | 4 +- lisp/org-ref/org-ref-scopus.el | 2 +- lisp/org-ref/org-ref-url-utils.el | 2 +- lisp/org-ref/org-ref-utils.el | 47 +- lisp/org-ref/org-ref-worldcat.el | 2 +- lisp/org-ref/org-ref-wos.el | 2 +- lisp/org-ref/org-ref.el | 6 +- lisp/org-ref/x2bib.el | 8 +- lisp/org-roam-bibtex/orb-pdf-scrapper.el | 3 +- lisp/org-roam-bibtex/org-roam-bibtex-pkg.el | 6 +- lisp/org-roam-bibtex/org-roam-bibtex.el | 2 +- lisp/org-roam/org-roam-capture.el | 5 +- lisp/org-roam/org-roam-db.el | 109 +- lisp/org-roam/org-roam-export.el | 2 +- lisp/org-roam/org-roam-graph.el | 2 +- lisp/org-roam/org-roam-id.el | 39 +- lisp/org-roam/org-roam-log.el | 2 +- lisp/org-roam/org-roam-migrate.el | 2 +- lisp/org-roam/org-roam-mode.el | 43 +- lisp/org-roam/org-roam-node.el | 52 +- lisp/org-roam/org-roam-overlay.el | 2 +- lisp/org-roam/org-roam-pkg.el | 8 +- lisp/org-roam/org-roam-protocol.el | 2 +- lisp/org-roam/org-roam-utils.el | 47 +- lisp/org-roam/org-roam.el | 25 +- lisp/org-roam/org-roam.info | 832 ++--- lisp/orgit/orgit-pkg.el | 18 +- lisp/orgit/orgit.el | 16 +- lisp/ox-pandoc/ox-pandoc-pkg.el | 4 +- lisp/ox-pandoc/ox-pandoc.el | 85 +- lisp/ox-tufte/ox-tufte-autoloads.el | 6 + lisp/ox-tufte/ox-tufte-pkg.el | 8 +- lisp/ox-tufte/ox-tufte.el | 459 ++- lisp/ox-tufte/src/README.org | 78 +- lisp/page-break-lines/page-break-lines-pkg.el | 6 +- lisp/page-break-lines/page-break-lines.el | 48 +- lisp/parsebib/parsebib-pkg.el | 4 +- lisp/parsebib/parsebib.el | 1307 ++++--- lisp/pdf-tools/build/server/autobuild | 15 +- lisp/pdf-tools/pdf-annot.el | 18 +- lisp/pdf-tools/pdf-loader.el | 2 +- lisp/pdf-tools/pdf-outline.el | 14 +- lisp/pdf-tools/pdf-tools-pkg.el | 4 +- lisp/pdf-tools/pdf-tools.el | 6 +- lisp/pdf-tools/pdf-util.el | 20 +- lisp/pdf-tools/pdf-view.el | 29 +- lisp/php-mode/php-align.el | 2 +- lisp/php-mode/php-complete.el | 2 +- lisp/php-mode/php-defs.el | 2 +- lisp/php-mode/php-face.el | 43 +- lisp/php-mode/php-flymake.el | 5 +- lisp/php-mode/php-format.el | 2 +- lisp/php-mode/php-ide-phpactor.el | 10 +- lisp/php-mode/php-ide.el | 15 +- lisp/php-mode/php-mode-debug.el | 2 +- lisp/php-mode/php-mode-pkg.el | 6 +- lisp/php-mode/php-mode.el | 125 +- lisp/php-mode/php-project.el | 4 +- lisp/php-mode/php.el | 85 +- lisp/popup/popup-pkg.el | 4 +- lisp/popup/popup.el | 2 +- lisp/popwin/popwin-pkg.el | 8 +- lisp/popwin/popwin.el | 2 + lisp/pos-tip/pos-tip-pkg.el | 2 +- lisp/pos-tip/pos-tip.el | 4 +- lisp/posframe/posframe-pkg.el | 4 +- lisp/posframe/posframe.el | 50 +- lisp/powershell/powershell-pkg.el | 4 +- lisp/powershell/powershell.el | 4 +- lisp/spacemacs-theme/spacemacs-theme-pkg.el | 2 +- lisp/spacemacs-theme/spacemacs-theme.el | 30 +- .../string-inflection-pkg.el | 2 +- lisp/string-inflection/string-inflection.el | 202 +- lisp/swiper/swiper-pkg.el | 10 +- lisp/swiper/swiper.el | 48 +- lisp/transient/gpl.info | 10 +- lisp/transient/transient-pkg.el | 12 +- lisp/transient/transient.el | 3259 +++++++++++------ lisp/transient/transient.info | 1889 ++++++---- lisp/treemacs-magit/treemacs-magit-pkg.el | 4 +- lisp/treemacs-magit/treemacs-magit.el | 2 +- lisp/treemacs/Changelog.org | 8 +- lisp/treemacs/icons/default/svgrepo/inbox.png | Bin 0 -> 4953 bytes .../icons/default/svgrepo/mail-plus.png | Bin 27424 -> 3121 bytes lisp/treemacs/icons/default/svgrepo/mail.png | Bin 17662 -> 4522 bytes lisp/treemacs/icons/default/vsc/terraform.png | Bin 0 -> 1040 bytes lisp/treemacs/treemacs-annotations.el | 23 +- lisp/treemacs/treemacs-async.el | 55 +- lisp/treemacs/treemacs-bookmarks.el | 2 +- lisp/treemacs/treemacs-compatibility.el | 35 +- lisp/treemacs/treemacs-core-utils.el | 12 +- lisp/treemacs/treemacs-customization.el | 35 +- lisp/treemacs/treemacs-diagnostics.el | 2 +- lisp/treemacs/treemacs-dirs-to-collapse.py | 61 +- lisp/treemacs/treemacs-dom.el | 2 +- lisp/treemacs/treemacs-extensions.el | 10 +- lisp/treemacs/treemacs-faces.el | 2 +- lisp/treemacs/treemacs-file-management.el | 2 +- lisp/treemacs/treemacs-filewatch-mode.el | 2 +- lisp/treemacs/treemacs-find-ignored-files.py | 5 +- lisp/treemacs/treemacs-follow-mode.el | 2 +- lisp/treemacs/treemacs-fringe-indicator.el | 23 +- .../treemacs/treemacs-git-commit-diff-mode.el | 8 +- lisp/treemacs/treemacs-git-commit-diff.py | 3 +- lisp/treemacs/treemacs-git-status.py | 10 +- lisp/treemacs/treemacs-header-line.el | 3 +- lisp/treemacs/treemacs-hydras.el | 2 +- lisp/treemacs/treemacs-icons.el | 40 +- lisp/treemacs/treemacs-interface.el | 175 +- lisp/treemacs/treemacs-logging.el | 2 +- lisp/treemacs/treemacs-macros.el | 6 +- lisp/treemacs/treemacs-mode.el | 12 +- lisp/treemacs/treemacs-mouse-interface.el | 8 +- lisp/treemacs/treemacs-peek-mode.el | 12 +- lisp/treemacs/treemacs-persistence.el | 12 +- lisp/treemacs/treemacs-pkg.el | 4 +- lisp/treemacs/treemacs-project-follow-mode.el | 2 +- lisp/treemacs/treemacs-rendering.el | 78 +- lisp/treemacs/treemacs-scope.el | 2 +- .../treemacs-single-file-git-status.py | 15 +- lisp/treemacs/treemacs-tag-follow-mode.el | 2 +- lisp/treemacs/treemacs-tags.el | 6 +- lisp/treemacs/treemacs-themes.el | 2 +- lisp/treemacs/treemacs-treelib.el | 64 +- lisp/treemacs/treemacs-visuals.el | 5 +- lisp/treemacs/treemacs-workspaces.el | 7 +- lisp/treemacs/treemacs.el | 49 +- lisp/use-package/doclicense.info | 6 +- lisp/use-package/docstyle.info | 2 +- lisp/use-package/use-package.info | 278 +- .../visual-fill-column-pkg.el | 4 +- lisp/visual-fill-column/visual-fill-column.el | 54 +- lisp/vterm/elisp.c | 5 +- lisp/vterm/elisp.h | 3 +- lisp/vterm/vterm-module.c | 33 +- lisp/vterm/vterm-module.h | 2 + lisp/vterm/vterm-pkg.el | 4 +- lisp/vterm/vterm.el | 232 +- lisp/web-mode/web-mode-pkg.el | 4 +- lisp/web-mode/web-mode.el | 311 +- lisp/which-key/which-key-pkg.el | 9 +- lisp/which-key/which-key.el | 1002 ++--- lisp/with-editor/with-editor-pkg.el | 14 +- lisp/with-editor/with-editor.el | 150 +- lisp/with-editor/with-editor.info | 82 +- .../snippets/bibtex-mode/.yas-setup.el | 1 + .../snippets/bibtex-mode/bookinbook | 2 +- .../snippets/bibtex-mode/collection | 2 +- .../snippets/bibtex-mode/dataset | 2 +- .../snippets/bibtex-mode/electronic | 2 +- .../snippets/bibtex-mode/inreference | 2 +- .../snippets/bibtex-mode/mvbook | 2 +- .../snippets/bibtex-mode/mvcollection | 2 +- .../snippets/bibtex-mode/mvreference | 2 +- .../snippets/bibtex-mode/online | 2 +- .../snippets/bibtex-mode/patent | 2 +- .../snippets/bibtex-mode/periodical | 2 +- .../snippets/bibtex-mode/reference | 2 +- .../snippets/bibtex-mode/report | 2 +- .../snippets/bibtex-mode/set | 2 +- .../snippets/bibtex-mode/suppbook | 2 +- .../snippets/bibtex-mode/suppcollection | 2 +- .../snippets/bibtex-mode/suppperiodical | 2 +- .../snippets/bibtex-mode/thesis | 2 +- .../snippets/bibtex-mode/xdata | 2 +- .../snippets/c++-mode/.yas-setup.el | 1 + .../snippets/c++-mode/class11 | 24 +- .../yasnippet-snippets/snippets/c++-mode/forr | 7 + .../snippets/c++-mode/lambda | 7 + .../snippets/cc-mode/file_description | 2 +- .../snippets/cc-mode/function_description | 2 +- .../snippets/cc-mode/member_description | 2 +- lisp/yasnippet-snippets/snippets/js-mode/for | 2 +- .../snippets/latex-mode/corollary | 8 + .../snippets/latex-mode/lemma | 8 + .../snippets/latex-mode/theorem | 8 + .../snippets/php-mode/.yas-setup.el | 2 +- .../snippets/php-mode/{ticks => strict-types} | 6 +- .../snippets/prog-mode/.yas-setup.el | 13 +- .../snippets/prog-mode/commentblock | 17 +- .../snippets/prog-mode/fixme | 2 +- .../snippets/prog-mode/spdxcopyright | 6 + .../snippets/prog-mode/spdxlicense | 6 + .../snippets/python-mode/.yas-setup.el | 32 +- .../snippets/python-mode/__abs__ | 7 + .../snippets/python-mode/__add__ | 7 + .../snippets/python-mode/__aenter__ | 8 + .../snippets/python-mode/__aexit__ | 7 + .../snippets/python-mode/__aiter__ | 7 + .../snippets/python-mode/__and__ | 7 + .../snippets/python-mode/__anext__ | 7 + .../snippets/python-mode/__await__ | 7 + .../snippets/python-mode/__bool__ | 7 + .../snippets/python-mode/__bytes__ | 7 + .../snippets/python-mode/__call__ | 7 + .../snippets/python-mode/__ceil__ | 7 + .../snippets/python-mode/__class_getitem__ | 7 + .../snippets/python-mode/__cmp__ | 7 + .../snippets/python-mode/__complex__ | 7 + .../snippets/python-mode/__contains__ | 8 +- .../snippets/python-mode/__del__ | 7 + .../snippets/python-mode/__delattr__ | 7 + .../snippets/python-mode/__delete__ | 7 + .../snippets/python-mode/__delitem__ | 7 + .../snippets/python-mode/__dir__ | 7 + .../snippets/python-mode/__div__ | 7 + .../snippets/python-mode/__divmod__ | 7 + .../snippets/python-mode/__enter__ | 6 +- .../snippets/python-mode/{eq => __eq__} | 6 +- .../snippets/python-mode/__exit__ | 8 +- .../snippets/python-mode/__float__ | 7 + .../snippets/python-mode/__floor__ | 7 + .../snippets/python-mode/__floordiv__ | 7 + .../snippets/python-mode/__format__ | 7 + .../snippets/python-mode/__ge__ | 7 + .../snippets/python-mode/__get__ | 7 + .../snippets/python-mode/__getattr__ | 7 + .../snippets/python-mode/__getattribute__ | 7 + .../snippets/python-mode/__getitem__ | 8 +- .../snippets/python-mode/__gt__ | 7 + .../snippets/python-mode/__hash__ | 7 + .../snippets/python-mode/__iadd__ | 7 + .../snippets/python-mode/__iand__ | 7 + .../snippets/python-mode/__idiv__ | 7 + .../snippets/python-mode/__ifloordiv__ | 7 + .../snippets/python-mode/__ilshift__ | 7 + .../snippets/python-mode/__imatmul__ | 7 + .../snippets/python-mode/__imod__ | 7 + .../snippets/python-mode/__imul__ | 7 + .../snippets/python-mode/__index__ | 7 + .../snippets/python-mode/{init => __init__} | 6 +- .../snippets/python-mode/__init_subclass__ | 8 + .../snippets/python-mode/__instancecheck__ | 7 + .../snippets/python-mode/__int__ | 7 + .../snippets/python-mode/__invert__ | 7 + .../snippets/python-mode/__ior__ | 7 + .../snippets/python-mode/__ipow__ | 7 + .../snippets/python-mode/__irshift__ | 7 + .../snippets/python-mode/__isub__ | 7 + .../snippets/python-mode/{iter => __iter__} | 6 +- .../snippets/python-mode/__itruediv__ | 7 + .../snippets/python-mode/__ixor__ | 7 + .../snippets/python-mode/__le__ | 7 + .../snippets/python-mode/__len__ | 6 +- .../snippets/python-mode/__length_hint__ | 7 + .../snippets/python-mode/__lshift__ | 7 + .../snippets/python-mode/__lt__ | 7 + .../snippets/python-mode/__matmul__ | 7 + .../snippets/python-mode/__missing__ | 7 + .../snippets/python-mode/__mod__ | 7 + .../snippets/python-mode/__mul__ | 7 + .../snippets/python-mode/__ne__ | 7 + .../snippets/python-mode/__neg__ | 7 + .../snippets/python-mode/__new__ | 4 +- .../snippets/python-mode/__next__ | 7 + .../snippets/python-mode/__or__ | 7 + .../snippets/python-mode/__pos__ | 7 + .../snippets/python-mode/__pow__ | 7 + .../snippets/python-mode/__prepare__ | 7 + .../snippets/python-mode/__radd__ | 7 + .../snippets/python-mode/__rand__ | 7 + .../snippets/python-mode/__rdivmod__ | 7 + .../snippets/python-mode/{repr => __repr__} | 6 +- .../snippets/python-mode/__reversed__ | 7 + .../snippets/python-mode/__rfloordiv__ | 7 + .../snippets/python-mode/__rlshift__ | 7 + .../snippets/python-mode/__rmatmul__ | 7 + .../snippets/python-mode/__rmod__ | 7 + .../snippets/python-mode/__rmul__ | 7 + .../snippets/python-mode/__ror__ | 7 + .../snippets/python-mode/__round__ | 7 + .../snippets/python-mode/__rpow__ | 7 + .../snippets/python-mode/__rrshift__ | 7 + .../snippets/python-mode/__rshift__ | 7 + .../snippets/python-mode/__rsub__ | 7 + .../snippets/python-mode/__rtruediv__ | 7 + .../snippets/python-mode/__rxor__ | 7 + .../snippets/python-mode/__set__ | 7 + .../snippets/python-mode/__set_name__ | 7 + .../snippets/python-mode/__setattr__ | 7 + .../snippets/python-mode/__setitem__ | 8 +- .../snippets/python-mode/__slots__ | 7 + .../snippets/python-mode/{str => __str__} | 6 +- .../snippets/python-mode/__sub__ | 7 + .../snippets/python-mode/__subclasscheck__ | 7 + .../snippets/python-mode/__truediv__ | 7 + .../snippets/python-mode/__trunc__ | 7 + .../snippets/python-mode/__xor__ | 7 + .../snippets/python-mode/all | 3 +- .../snippets/python-mode/arg_positional | 4 +- .../snippets/python-mode/ase | 6 + .../snippets/python-mode/asne | 6 + .../snippets/python-mode/asr | 7 + .../snippets/python-mode/assert | 2 +- .../snippets/python-mode/assertEqual | 2 +- .../snippets/python-mode/assertFalse | 2 +- .../snippets/python-mode/assertIn | 2 +- .../snippets/python-mode/assertNotEqual | 2 +- .../snippets/python-mode/assertNotIn | 2 +- .../snippets/python-mode/assertRaises | 2 +- .../snippets/python-mode/assertTrue | 2 +- .../snippets/python-mode/bang | 2 +- .../snippets/python-mode/celery_pdb | 2 +- .../snippets/python-mode/class_doxygen_doc | 2 +- .../snippets/python-mode/classmethod | 2 +- .../snippets/python-mode/dec | 2 +- .../snippets/python-mode/def | 7 + .../snippets/python-mode/deftest | 2 +- .../snippets/python-mode/django_test_class | 4 +- .../snippets/python-mode/doc | 2 +- .../snippets/python-mode/doctest | 4 +- .../snippets/python-mode/env | 6 + .../snippets/python-mode/for | 2 +- .../snippets/python-mode/from | 7 +- .../snippets/python-mode/function_docstring | 4 +- .../snippets/python-mode/function_doxygen_doc | 2 +- .../snippets/python-mode/ife | 1 + .../snippets/python-mode/ifmain | 2 +- .../snippets/python-mode/import | 2 +- .../snippets/python-mode/init_docstring | 2 +- .../snippets/python-mode/interact | 2 +- .../snippets/python-mode/ipdb | 2 +- .../snippets/python-mode/lambda | 2 +- .../snippets/python-mode/list | 2 +- .../snippets/python-mode/logger_name | 2 +- .../snippets/python-mode/main | 2 +- .../snippets/python-mode/metaclass | 6 - .../snippets/python-mode/method | 2 +- .../snippets/python-mode/method_docstring | 2 +- .../python-mode/method_docstring_numpy | 2 +- .../snippets/python-mode/not_impl | 2 +- .../snippets/python-mode/np | 2 +- .../snippets/python-mode/parse_args | 2 +- .../snippets/python-mode/parser | 2 +- .../snippets/python-mode/pass | 2 +- .../snippets/python-mode/pdb | 2 +- .../snippets/python-mode/print | 2 +- .../snippets/python-mode/prop | 3 +- .../snippets/python-mode/pudb | 2 +- .../snippets/python-mode/reg | 2 +- .../snippets/python-mode/return | 2 +- .../snippets/python-mode/self | 2 +- .../snippets/python-mode/self_without_dot | 2 +- .../snippets/python-mode/selfassign | 2 +- .../snippets/python-mode/setdef | 2 +- .../snippets/python-mode/size | 2 +- .../snippets/python-mode/super | 7 - .../snippets/python-mode/test_file | 2 +- .../snippets/python-mode/try | 3 +- .../snippets/python-mode/tryelse | 5 +- .../snippets/python-mode/unicode | 7 - .../snippets/python-mode/unicode_literals | 6 - .../snippets/python-mode/uv-script | 11 + .../snippets/python-mode/while | 2 +- .../snippets/python-mode/with | 2 +- .../snippets/python-mode/with-open | 8 + .../snippets/python-mode/with_statement | 6 - .../yasnippet-snippets-pkg.el | 4 +- lisp/yasnippet-snippets/yasnippet-snippets.el | 11 +- lisp/yasnippet/yasnippet-pkg.el | 4 +- lisp/yasnippet/yasnippet.el | 578 +-- 440 files changed, 13229 insertions(+), 8718 deletions(-) create mode 100644 lisp/llama/llama-pkg.el create mode 100644 lisp/llama/llama.el create mode 100644 lisp/treemacs/icons/default/svgrepo/inbox.png create mode 100644 lisp/treemacs/icons/default/vsc/terraform.png create mode 100644 lisp/yasnippet-snippets/snippets/c++-mode/forr create mode 100644 lisp/yasnippet-snippets/snippets/c++-mode/lambda create mode 100644 lisp/yasnippet-snippets/snippets/latex-mode/corollary create mode 100644 lisp/yasnippet-snippets/snippets/latex-mode/lemma create mode 100644 lisp/yasnippet-snippets/snippets/latex-mode/theorem rename lisp/yasnippet-snippets/snippets/php-mode/{ticks => strict-types} (54%) create mode 100644 lisp/yasnippet-snippets/snippets/prog-mode/spdxcopyright create mode 100644 lisp/yasnippet-snippets/snippets/prog-mode/spdxlicense create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__abs__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__add__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__aenter__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__aexit__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__aiter__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__and__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__anext__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__await__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__bool__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__bytes__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__call__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__ceil__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__class_getitem__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__cmp__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__complex__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__del__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__delattr__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__delete__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__delitem__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__dir__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__div__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__divmod__ rename lisp/yasnippet-snippets/snippets/python-mode/{eq => __eq__} (51%) create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__float__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__floor__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__floordiv__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__format__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__ge__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__get__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__getattr__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__getattribute__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__gt__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__hash__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__iadd__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__iand__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__idiv__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__ifloordiv__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__ilshift__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__imatmul__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__imod__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__imul__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__index__ rename lisp/yasnippet-snippets/snippets/python-mode/{init => __init__} (73%) create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__init_subclass__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__instancecheck__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__int__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__invert__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__ior__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__ipow__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__irshift__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__isub__ rename lisp/yasnippet-snippets/snippets/python-mode/{iter => __iter__} (52%) create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__itruediv__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__ixor__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__le__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__length_hint__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__lshift__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__lt__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__matmul__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__missing__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__mod__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__mul__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__ne__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__neg__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__next__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__or__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__pos__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__pow__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__prepare__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__radd__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__rand__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__rdivmod__ rename lisp/yasnippet-snippets/snippets/python-mode/{repr => __repr__} (55%) create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__reversed__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__rfloordiv__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__rlshift__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__rmatmul__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__rmod__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__rmul__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__ror__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__round__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__rpow__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__rrshift__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__rshift__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__rsub__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__rtruediv__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__rxor__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__set__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__set_name__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__setattr__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__slots__ rename lisp/yasnippet-snippets/snippets/python-mode/{str => __str__} (55%) create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__sub__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__subclasscheck__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__truediv__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__trunc__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/__xor__ create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/ase create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/asne create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/asr create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/def create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/env delete mode 100644 lisp/yasnippet-snippets/snippets/python-mode/metaclass delete mode 100644 lisp/yasnippet-snippets/snippets/python-mode/super delete mode 100644 lisp/yasnippet-snippets/snippets/python-mode/unicode delete mode 100644 lisp/yasnippet-snippets/snippets/python-mode/unicode_literals create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/uv-script create mode 100644 lisp/yasnippet-snippets/snippets/python-mode/with-open delete mode 100644 lisp/yasnippet-snippets/snippets/python-mode/with_statement diff --git a/lisp/anaconda-mode/anaconda-mode-pkg.el b/lisp/anaconda-mode/anaconda-mode-pkg.el index 28d73550..78d0db34 100644 --- a/lisp/anaconda-mode/anaconda-mode-pkg.el +++ b/lisp/anaconda-mode/anaconda-mode-pkg.el @@ -1,10 +1,10 @@ -(define-package "anaconda-mode" "20231123.1806" "Code navigation, documentation lookup and completion for Python" +(define-package "anaconda-mode" "20250310.1512" "Code navigation, documentation lookup and completion for Python" '((emacs "25.1") (pythonic "0.1.0") (dash "2.6.0") (s "1.9") (f "0.16.2")) - :commit "92a6295622df7fae563d6b599e2dc8640e940ddf" :authors + :commit "28b3e0088ac7113390aa006bf277c8aa14e561a2" :authors '(("Artem Malyshev" . "proofit404@gmail.com")) :maintainers '(("Artem Malyshev" . "proofit404@gmail.com")) diff --git a/lisp/anaconda-mode/anaconda-mode.el b/lisp/anaconda-mode/anaconda-mode.el index f4a06b2f..2bcc03b3 100644 --- a/lisp/anaconda-mode/anaconda-mode.el +++ b/lisp/anaconda-mode/anaconda-mode.el @@ -94,7 +94,7 @@ (declare-function posframe-show "posframe") ;;; Server. -(defvar anaconda-mode-server-version "0.1.16" +(defvar anaconda-mode-server-version "0.1.17" "Server version needed to run `anaconda-mode'.") (defvar anaconda-mode-process-name "anaconda-mode" @@ -784,14 +784,14 @@ Show ERROR-MESSAGE if result is empty." (defun turn-on-anaconda-eldoc-mode () "Turn on `anaconda-eldoc-mode'." (add-hook 'eldoc-documentation-functions - 'anaconda-mode-eldoc-function nil 't) - (eldoc-mode +1)) + #'anaconda-mode-eldoc-function nil 't) + (unless (bound-and-true-p eldoc-mode) + (eldoc-mode +1))) (defun turn-off-anaconda-eldoc-mode () "Turn off `anaconda-eldoc-mode'." (remove-hook 'eldoc-documentation-functions - 'anaconda-mode-eldoc-function 't) - (eldoc-mode -1)) + #'anaconda-mode-eldoc-function 't)) (provide 'anaconda-mode) diff --git a/lisp/anaconda-mode/anaconda-mode.py b/lisp/anaconda-mode/anaconda-mode.py index 6f65a364..225de368 100644 --- a/lisp/anaconda-mode/anaconda-mode.py +++ b/lisp/anaconda-mode/anaconda-mode.py @@ -1,4 +1,3 @@ - from __future__ import print_function import sys import os @@ -25,7 +24,7 @@ if IS_PY2: jedi_dep = ('jedi', '0.17.2') server_directory += '-py2' else: - jedi_dep = ('jedi', '0.19.1') + jedi_dep = ('jedi', '0.19.2') server_directory += '-py3' service_factory_dep = ('service_factory', '0.1.6') @@ -71,10 +70,19 @@ def install_deps_setuptools(): instrument_installation() def install_deps_pip(): + import pathlib + import shutil import subprocess - cmd = [sys.executable, '-m', 'pip', 'install', '--target', server_directory] + import tempfile + import venv + temp_dir = pathlib.Path(tempfile.mkdtemp()) + venv.create(temp_dir, with_pip=True) + cmd = [temp_dir / 'bin' / 'pip', 'install', '--target', server_directory] cmd.extend(missing_dependencies) - subprocess.check_call(cmd) + try: + subprocess.check_call(cmd) + finally: + shutil.rmtree(temp_dir) instrument_installation() if missing_dependencies: diff --git a/lisp/company/company-capf.el b/lisp/company/company-capf.el index baeacaa2..8d159608 100644 --- a/lisp/company/company-capf.el +++ b/lisp/company/company-capf.el @@ -238,7 +238,8 @@ so we can't just use the preceding variable instead.") (defun company-capf--post-completion (arg) (let* ((res company-capf--current-completion-data) (exit-function (plist-get (nthcdr 4 res) :exit-function)) - (table (nth 3 res))) + (table (nth 3 res)) + (prefix (nth 0 (company-capf--prefix)))) (if exit-function ;; Follow the example of `completion--done'. (funcall exit-function arg @@ -247,8 +248,8 @@ so we can't just use the preceding variable instead.") ;; particular candidate explicitly (it only checks whether ;; further completions exist). Whereas company user can press ;; RET (or use implicit completion with company-tng). - (if (= (car (completion-boundaries arg table nil "")) - (length arg)) + (if (= (car (completion-boundaries prefix table nil "")) + (length prefix)) 'exact 'finished))))) diff --git a/lisp/company/company-pkg.el b/lisp/company/company-pkg.el index bbde59f6..34245b98 100644 --- a/lisp/company/company-pkg.el +++ b/lisp/company/company-pkg.el @@ -1,6 +1,6 @@ -(define-package "company" "20250223.352" "Modular text completion framework" +(define-package "company" "20250228.258" "Modular text completion framework" '((emacs "26.1")) - :commit "5bb6f6d3d44ed919378e6968a06feed442165545" :maintainers + :commit "8d599ebc8a9aca27c0a6157aeb31c5b7f05ed0a3" :maintainers '(("Dmitry Gutov" . "dmitry@gutov.dev")) :maintainer '("Dmitry Gutov" . "dmitry@gutov.dev") diff --git a/lisp/company/company.info b/lisp/company/company.info index 1cae4936..df6622a5 100644 --- a/lisp/company/company.info +++ b/lisp/company/company.info @@ -1,4 +1,4 @@ -This is company.info, produced by makeinfo version 6.8 from +This is company.info, produced by makeinfo version 7.1.1 from company.texi. This user manual is for Company version 1.0.3-snapshot @@ -47,7 +47,7 @@ Copyright © 2021-2024 Free Software Foundation, Inc. * Troubleshooting:: When Something Goes Wrong * Index:: -— The Detailed Node Listing — +-- The Detailed Node Listing -- Overview @@ -122,8 +122,8 @@ configurable through the user option ‘completion-styles’, which see. For illustrations on how Company visualizes the matches, *note Frontends::. -The package’s name ‘Company’ is based on the combination of the two -words: ‘Complete’ and ‘Anything’. These words reflect the package’s +The package's name ‘Company’ is based on the combination of the two +words: ‘Complete’ and ‘Anything’. These words reflect the package's commitment to handling completion candidates and its extensible nature allowing it to cover a wide range of usage scenarios. @@ -154,10 +154,10 @@ commands for the user to operate with. For more details, *note Customization:: and *note Commands::. Also, Company is bundled with an alternative workflow configuration -“company-tng” — defining ‘company-tng-frontend’, ‘company-tng-mode’, and -‘company-tng-map’ — that allows performing completion with just . -To enable this configuration, add the following line to the Emacs -initialization file (*note (emacs)Init File::): +“company-tng” -- defining ‘company-tng-frontend’, ‘company-tng-mode’, +and ‘company-tng-map’ -- that allows performing completion with just +. To enable this configuration, add the following line to the +Emacs initialization file (*note (emacs)Init File::): (add-hook 'after-init-hook 'company-tng-mode) @@ -216,7 +216,7 @@ File: company.info, Node: Usage Basics, Next: Commands, Prev: Initial Setup, 2.3 Usage Basics ================ -By default — having _company-mode_ enabled (*note Initial Setup::) — a +By default -- having _company-mode_ enabled (*note Initial Setup::) -- a tooltip with completion candidates is shown when the user types a few characters. @@ -228,7 +228,7 @@ respectively key bindings ‘C-n’ and ‘C-p’, then do one of the following: • Hit to choose a selected candidate for completion. • Hit to expand the “common part” of all completions. Exactly - what that means, can vary by backend. In the simplest case it’s + what that means, can vary by backend. In the simplest case it's the longest string that all completion start with, but when a backend returns _non-prefix matches_, it can implement the same kind of expansion logic for the input string. @@ -261,8 +261,8 @@ commands of the out-of-the-box Company. ‘TAB’ ‘’ - Insert the _common part_ of all completion candidates or — if no - _common part_ is present — select the next candidate + Insert the _common part_ of all completion candidates or -- if no + _common part_ is present -- select the next candidate (‘company-complete-common-or-cycle’). In the latter case, wraparound is implicitly enabled (*note company-selection-wrap-around::). @@ -360,7 +360,7 @@ core settings that influence its overall behavior. than the default value of ‘3’. -- User Option: company-idle-delay - This is the second of the options that configure Company’s + This is the second of the options that configure Company's auto-start behavior (together with ‘company-minimum-prefix-length’). The value of this option defines how fast Company is going to react to the typed input, such that @@ -390,7 +390,7 @@ core settings that influence its overall behavior. (setq company-global-modes '(not erc-mode message-mode eshell-mode)) -- User Option: company-selection-wrap-around - Enable this option to loop (cycle) the candidates’ selection: after + Enable this option to loop (cycle) the candidates' selection: after selecting the last candidate on the list, a command to select the next candidate does so with the first candidate. By default, this option is disabled, which means the selection of the next candidate @@ -398,7 +398,7 @@ core settings that influence its overall behavior. influenced by this option similarly. -- User Option: company-require-match - To allow typing in characters that don’t match the candidates, set + To allow typing in characters that don't match the candidates, set the value of this option to ‘nil’. For an opposite behavior (that is, to disallow non-matching input), set it to ‘t’. By default, Company is configured to require a matching input only if the user @@ -484,7 +484,7 @@ listed below. -- Function: company-pseudo-tooltip-unless-just-one-frontend This is one of the default frontends. It starts displaying a tooltip only if more than one completion candidate is available, - which nicely combines — and it is done so by default — with + which nicely combines -- and it is done so by default -- with ‘company-preview-if-just-one-frontend’, *note Preview Frontends::. -- Function: company-pseudo-tooltip-frontend @@ -535,7 +535,7 @@ user options. [image src="./images/small/tooltip-annotations.png"] -- User Option: company-tooltip-annotation-padding - Adds left padding to the candidates’ annotations. It is disabled + Adds left padding to the candidates' annotations. It is disabled by default. If ‘company-tooltip-align-annotations’ is enabled, ‘company-tooltip-annotation-padding’ defines the minimum spacing between a candidate and annotation, with the default value of 1. @@ -545,7 +545,7 @@ user options. -- User Option: company-tooltip-limit Controls the maximum number of the candidates shown simultaneously in the tooltip (the default value is ‘10’). When the number of the - available candidates is larger than this option’s value, Company + available candidates is larger than this option's value, Company paginates the results. (setq company-tooltip-limit 4) @@ -622,7 +622,7 @@ user options. Candidates Icons ---------------- -An “icon” is an image or a text that represents a candidate’s kind; it +An “icon” is an image or a text that represents a candidate's kind; it is displayed in front of a candidate. The term “kind” here stands for a high-level category a candidate fits into. (Such as ‘array’, ‘function’, ‘file’, ‘string’, ‘color’, etc. For an extended list of the @@ -631,7 +631,7 @@ the variable ‘company-vscode-icons-mapping’.) -- User Option: company-format-margin-function Allows setting a function to format the left margin of a tooltip - inner area; namely, to output candidate’s _icons_. The predefined + inner area; namely, to output candidate's _icons_. The predefined formatting functions are listed below. The user may also set this option to a custom function. To disable left margin formatting, set the value of the option to ‘nil’ (this way control over the @@ -664,7 +664,7 @@ The following user options influence appearance of the _text_ and _dot_ _icons_. -- User Option: company-text-icons-mapping - Lists candidates’ _kinds_ with their corresponding _icons_ + Lists candidates' _kinds_ with their corresponding _icons_ configurations. -- User Option: company-text-face-extra-attributes @@ -676,7 +676,7 @@ _icons_. [image src="./images/small/tooltip-icon-face.png"] -- User Option: company-text-icons-add-background - If this option is enabled, when an _icon_ doesn’t have a background + If this option is enabled, when an _icon_ doesn't have a background configured by ‘company-text-icons-mapping’, then a generated background is applied. @@ -696,8 +696,8 @@ Faces Out-of-the-box Company defines and configures distinguished faces (*note (emacs)Faces::) for light and dark themes. Moreover, some of the built-in and third-party themes fine-tune Company to fit their palettes. -That is why there’s often no real need to make such adjustments on the -user’s side. However, this chapter presents some hints on where to +That is why there's often no real need to make such adjustments on the +user's side. However, this chapter presents some hints on where to start customizing Company interface. Namely, the look of a tooltip is controlled by the ‘company-tooltip*’ @@ -770,7 +770,7 @@ File: company.info, Node: Echo Frontends, Next: Candidates Search, Prev: Prev 4.3 Echo Frontends ================== -The frontends listed in this section display information in the Emacs’s +The frontends listed in this section display information in the Emacs's echo area, *note (emacs)Echo Area::. -- Function: company-echo-metadata-frontend @@ -781,7 +781,7 @@ echo area, *note (emacs)Echo Area::. [image src="./images/small/echo-meta.png"] -The last pair of the built-in frontends isn’t that commonly used and not +The last pair of the built-in frontends isn't that commonly used and not as full-featured as the previously reviewed _tooltip-_ and _preview-_ frontends, but still, feel free to play with them and have some fun! @@ -814,7 +814,7 @@ File: company.info, Node: Candidates Search, Next: Filter Candidates, Prev: E By default, when _company-mode_ is in action, a key binding ‘C-s’ starts looking for matches to additionally typed characters among the displayed candidates. When a search is initiated, an indicator -‘Search: CHARACTERS’ is shown in the Emacs’s mode line. +‘Search: CHARACTERS’ is shown in the Emacs's mode line. To quit the search mode, hit ‘C-g’. @@ -1016,7 +1016,7 @@ roughly outlined groups of the backends. Some of the backends expose user options for customization; a few of these options are introduced below. For those who would like to fetch -the full list of a backend’s user options, we suggest doing one of the +the full list of a backend's user options, we suggest doing one of the following: • Execute command ‘M-x customize-group ’. @@ -1041,7 +1041,7 @@ File: company.info, Node: Code Completion, Next: Text Completion, Up: Package --------------------- -- Function: company-capf - The current trend in the Emacs’s world is to delegate completion + The current trend in the Emacs's world is to delegate completion logic to the hook ‘completion-at-point-functions’ (CAPF) assigned to by the major or minor modes. It supports a common subset of features which is well-supported across different completion UIs. @@ -1063,8 +1063,8 @@ File: company.info, Node: Code Completion, Next: Text Completion, Up: Package -- User Option: company-capf-disabled-functions List of completion functions which should be ignored by this backend. By default it contains the functions that duplicate the - built-in backends but don’t support the corresponding configuration - options and/or alter the intended priority of the default backends’ + built-in backends but don't support the corresponding configuration + options and/or alter the intended priority of the default backends' configuration. -- Function: company-dabbrev-code @@ -1113,7 +1113,7 @@ File: company.info, Node: Code Completion, Next: Text Completion, Up: Package interface of the program ‘clang’, but without any advanced caching across calls, or automatic detection of the project structure. Which makes it more suitable for small to medium projects, - especially if you’re willing to customize + especially if you're willing to customize ‘company-clang-arguments’. Otherwise we recommend using one of the LSP clients available for Emacs, together with the backend ‘company-capf’. @@ -1137,7 +1137,7 @@ File: company.info, Node: Code Completion, Next: Text Completion, Up: Package program _etags_, *note (emacs)Tags Tables::. -- User Option: company-etags-ignore-case - Non-nil to ignore case in this backend’s completions. + Non-nil to ignore case in this backend's completions. -- User Option: company-etags-everywhere Non-nil to offer completions in comments and strings. It can also @@ -1159,7 +1159,7 @@ File: company.info, Node: Text Completion, Next: File Name Completion, Prev: This backend works similarly to the built-in Emacs package _dabbrev_, searching for completion candidates inside the contents of the open buffer(s). It is one of the often used backends, and - it has several interesting options for configuration. Let’s review + it has several interesting options for configuration. Let's review a few of them. -- User Option: company-dabbrev-minimum-length @@ -1202,7 +1202,7 @@ File: company.info, Node: Text Completion, Next: File Name Completion, Prev: ‘nil’, ‘Enjoy’ is suggested as a completion candidate for the typed ‘Enj’ letters, but not for ‘enj’. When the option is set to ‘t’, ‘Enjoy’ is suggested as a candidate for both ‘Enj’ - and ‘enj’ input; note that ‘enj’ prefix is “overwritten” by + and ‘enj’ input; note that ‘enj’ prefix is "overwritten" by completing with the ‘Enjoy’ candidate. The third, default, type of behavior solves this issue, keeping the case of the typed prefix (and still collecting candidates @@ -1221,7 +1221,7 @@ File: company.info, Node: Text Completion, Next: File Name Completion, Prev: being suggested. When the option is set to ‘t’, the down-cased candidate ‘enjoy’ is suggested. By default, this option is set to ‘case-replace’, meaning taking a value of the - Emacs’s variable ‘case-replace’ (‘t’ is the current default). + Emacs's variable ‘case-replace’ (‘t’ is the current default). -- Function: company-ispell @@ -1231,7 +1231,7 @@ File: company.info, Node: Text Completion, Next: File Name Completion, Prev: _Ispell_ uses only one dictionary at a time (combining several dictionaries into one file is an accepted practice). By default, _company-ispell_ suggests candidates from a dictionary specified by - the Emacs’s setting ‘ispell-complete-word-dict’. + the Emacs's setting ‘ispell-complete-word-dict’. -- User Option: company-ispell-dictionary Optionally, set a file path for _company-ispell_ to use @@ -1252,7 +1252,7 @@ File: company.info, Node: File Name Completion, Next: Template Expansion, Pre -- User Option: company-files-exclusions It may be desirable to exclude directories or files from the list of suggested completion candidates. For example, - someone’s setup might look this way: + someone's setup might look this way: (setq company-files-exclusions '(".git/" ".DS_Store")) @@ -1378,7 +1378,7 @@ Based on the value of the ‘Used backend’ in the output of the command caused by a function listed there. To identify to which package it belongs, type ‘M-x find-function ’. -If the aforementioned steps didn’t help to find the cause of the issue, +If the aforementioned steps didn't help to find the cause of the issue, then file a bug report to the Company Issue Tracker (https://github.com/company-mode/company-mode/issues), attaching the following information: @@ -1775,45 +1775,45 @@ Concept Index  Tag Table: -Node: Top573 +Node: Top575 Node: Overview2002 Node: Terminology2410 -Node: Structure3717 -Node: Getting Started5208 -Node: Installation5486 -Node: Initial Setup5869 -Node: Usage Basics6717 -Node: Commands7695 -Ref: Commands-Footnote-110093 -Node: Customization10260 -Node: Customization Interface10732 -Node: Configuration File11265 -Ref: company-selection-wrap-around13579 -Node: Frontends16072 -Node: Tooltip Frontends17041 -Ref: Tooltip Frontends-Footnote-127755 -Node: Preview Frontends27992 -Ref: Preview Frontends-Footnote-129250 -Node: Echo Frontends29377 -Node: Candidates Search30910 -Node: Filter Candidates32244 -Node: Quick Access a Candidate33024 -Node: Backends34642 -Node: Backends Usage Basics35672 -Ref: Backends Usage Basics-Footnote-137104 -Node: Grouped Backends37188 -Node: Package Backends38699 -Node: Code Completion39628 -Node: Text Completion45155 -Node: File Name Completion49589 -Node: Template Expansion51137 -Node: Candidates Post-Processing51856 -Node: Troubleshooting54433 -Node: Index56106 -Node: Key Index56269 -Node: Variable Index57768 -Node: Function Index62621 -Node: Concept Index67321 +Node: Structure3713 +Node: Getting Started5203 +Node: Installation5481 +Node: Initial Setup5864 +Node: Usage Basics6712 +Node: Commands7686 +Ref: Commands-Footnote-110082 +Node: Customization10249 +Node: Customization Interface10721 +Node: Configuration File11254 +Ref: company-selection-wrap-around13566 +Node: Frontends16055 +Node: Tooltip Frontends17024 +Ref: Tooltip Frontends-Footnote-127720 +Node: Preview Frontends27957 +Ref: Preview Frontends-Footnote-129215 +Node: Echo Frontends29342 +Node: Candidates Search30871 +Node: Filter Candidates32203 +Node: Quick Access a Candidate32983 +Node: Backends34601 +Node: Backends Usage Basics35631 +Ref: Backends Usage Basics-Footnote-137063 +Node: Grouped Backends37147 +Node: Package Backends38658 +Node: Code Completion39585 +Node: Text Completion45102 +Node: File Name Completion49526 +Node: Template Expansion51072 +Node: Candidates Post-Processing51791 +Node: Troubleshooting54368 +Node: Index56039 +Node: Key Index56202 +Node: Variable Index57701 +Node: Function Index62554 +Node: Concept Index67254  End Tag Table diff --git a/lisp/counsel/counsel-pkg.el b/lisp/counsel/counsel-pkg.el index aef6b1e8..54380b5a 100644 --- a/lisp/counsel/counsel-pkg.el +++ b/lisp/counsel/counsel-pkg.el @@ -1,8 +1,8 @@ -(define-package "counsel" "20250224.2125" "Various completion functions using Ivy" +(define-package "counsel" "20250304.939" "Various completion functions using Ivy" '((emacs "24.5") (ivy "0.15.0") (swiper "0.15.0")) - :commit "7a0d554aaf4ebbb2c45f2451d77747df4f7e2742" :authors + :commit "db61f55bc281c28beb723ef17cfe74f59580d2f4" :authors '(("Oleh Krehel" . "ohwoeowho@gmail.com")) :maintainers '(("Basil L. Contovounesios" . "basil@contovou.net")) diff --git a/lisp/counsel/counsel.el b/lisp/counsel/counsel.el index b4269065..55aee579 100644 --- a/lisp/counsel/counsel.el +++ b/lisp/counsel/counsel.el @@ -5670,8 +5670,11 @@ You can insert or kill the name of the selected font." map)) (defun counsel-kmacro-kill () - "Kill the line, or delete the keyboard macro." + "Kill the line, or delete the currently selected keyboard macro." + (declare (modes minibuffer-mode)) (interactive) + (unless (window-minibuffer-p) + (user-error "No completion session is active")) (if (not (eolp)) (ivy-kill-line) (counsel-kmacro-action-delete-kmacro @@ -5680,36 +5683,41 @@ You can insert or kill the name of the selected font." (ivy-state-collection ivy-last))) (ivy--kill-current-candidate))) -(defvar kmacro-ring) -(defvar kmacro-initial-counter-value) (defvar kmacro-counter) -(defvar kmacro-counter-value-start) (defvar kmacro-counter-format-start) +(defvar kmacro-ring) +(declare-function kmacro-cycle-ring-next "kmacro" (&optional arg)) +(declare-function kmacro-cycle-ring-previous "kmacro" (&optional arg)) +(declare-function kmacro-delete-ring-head "kmacro" (&optional arg)) +(declare-function kmacro-ring-head "kmacro" ()) +(declare-function kmacro-set-counter "kmacro" (arg)) +(declare-function kmacro-set-format "kmacro" (format)) +(declare-function kmacro-split-ring-element "kmacro" (elt)) ;;;###autoload (defun counsel-kmacro () - "Interactively choose and run a keyboard macro. + "Interactively choose and execute a keyboard macro. -With prefix argument, run macro that many times. +With a prefix argument, execute the macro that many times. -Macros are run using the current value of `kmacro-counter-value' -and their respective counter format. Displayed next to each macro is -the counter's format and initial value. +Macros are executed using their respective `kmacro-counter' value and +counter format; these values are also displayed next to each completion +candidate. -One can use actions to copy the counter format or initial counter -value of a macro, using them for a new macro." +The default actions include the ability to copy one macro's counter +value or format as the basis for another macro execution or definition. + +The following key bindings are also available: +\\{counsel-kmacro-map}" (interactive) - (if (or last-kbd-macro kmacro-ring) - (ivy-read - (concat "Execute macro (counter at " - (number-to-string (or kmacro-initial-counter-value kmacro-counter)) - "): ") - (counsel--kmacro-candidates) - :keymap counsel-kmacro-map - :require-match t - :action #'counsel-kmacro-action-run - :caller 'counsel-kmacro) - (user-error "No keyboard macros defined"))) + (require 'kmacro) + (ivy-read "Execute macro: " + (or (counsel--kmacro-candidates) + (user-error "No keyboard macros defined")) + :keymap counsel-kmacro-map + :require-match t + :action #'counsel-kmacro-action-run + :caller 'counsel-kmacro)) (ivy-configure 'counsel-kmacro :format-fn #'counsel--kmacro-format-function) @@ -5722,176 +5730,186 @@ value of a macro, using them for a new macro." "Transform FORMATTED-KMACRO into a string for `counsel-kmacro'." (ivy--format-function-generic (lambda (str) (ivy--add-face str 'ivy-current-match)) - (lambda (str) str) + #'identity formatted-kmacro (propertize counsel-kmacro-separator 'face 'ivy-separator))) +(defmacro counsel--with-kmacro (kmacro &rest body) + "Split KMACRO slots into corresponding dynvars around BODY." + (declare (debug t) (indent 1)) + `(let ((last-kbd-macro nil) + (kmacro-counter nil) + (kmacro-counter-format-start nil)) + ;; Works with both older triplets and Emacs 29 OClosures. + (kmacro-split-ring-element ,kmacro) + ,@body)) + +(defun counsel--format-kmacro () + "Return string representation of current keyboard macro." + (format "(%s,%s): %s" kmacro-counter-format-start kmacro-counter + (condition-case err + (format-kbd-macro last-kbd-macro 1) + ;; Recover from error in `edmacro-fix-menu-commands', + ;; especially prior to mouse event support in Emacs 27. + (error + (format (propertize "[Unprintable macro: %s]" 'face 'warning) + (error-message-string err)))))) + (defun counsel--kmacro-candidates () - "Create the list of keyboard macros used by `counsel-kmacro'. -This is a combination of `kmacro-ring' and, together in a list, -`last-kbd-macro', `kmacro-counter-format-start', and -`kmacro-counter-value-start'." - (mapcar - (lambda (kmacro) - (cons - (concat "(" (nth 2 kmacro) "," (number-to-string (nth 1 kmacro)) "): " - (condition-case nil - (format-kbd-macro (if (listp kmacro) (car kmacro) kmacro) 1) - ;; Recover from error from `edmacro-fix-menu-commands'. - (error "Warning: Cannot display macros containing mouse clicks"))) - kmacro)) - (cons - (if (listp last-kbd-macro) - last-kbd-macro - (list - last-kbd-macro - kmacro-counter-value-start - kmacro-counter-format-start)) - kmacro-ring))) + "Return an alist of known keyboard macros for `counsel-kmacro'. +The cdrs are the original `kmacro' objects from `kmacro-ring-head' and +`kmacro-ring'; the cars are a corresponding string representation." + (mapcar (lambda (km) + (cons (counsel--with-kmacro km + (counsel--format-kmacro)) + km)) + (let ((head (kmacro-ring-head))) + (and head (cons head kmacro-ring))))) -(defun counsel-kmacro-action-run (x) - "Run keyboard macro." - (let* ((actual-kmacro (cdr x)) - (kmacro-keys (nth 0 actual-kmacro)) - (kmacro-counter-format-start (nth 2 actual-kmacro))) - ;; With prefix argument, call the macro that many times. - (kmacro-call-macro (or current-prefix-arg 1) t nil kmacro-keys))) +(defun counsel--kmacro-exec (kmacro n) + "Execute KMACRO ring item N times." + (funcall (if (and (fboundp 'kmacro-p) (kmacro-p kmacro)) + #'funcall ;; Emacs 29 OClosure. + 'kmacro-exec-ring-item) + kmacro n)) -(defun counsel-kmacro-action-delete-kmacro (x) - "Delete a keyboard macro from within `counsel-kmacro'. +(defun counsel-kmacro-action-run (candidate) + "Execute keyboard macro from `counsel-kmacro' CANDIDATE. +With a prefix argument, execute the macro that many times." + ;; Action prefix overrides `counsel-kmacro' prefix. + (let* ((pre (or ivy-current-prefix-arg current-prefix-arg)) + (km (cdr candidate)) + (head (equal km (kmacro-ring-head)))) + (counsel--kmacro-exec km (prefix-numeric-value pre)) + (when head + ;; Executing pseudo `kmacro-ring-head' updates that object's counter, + ;; but not the current `kmacro-counter', so reconcile them here. + (kmacro-split-ring-element km)) + ;; Update state for next `ivy-call'. + (counsel--with-kmacro km + (setcar candidate (counsel--format-kmacro)))) + (setf (ivy-state-current ivy-last) (car candidate)) + (setf (ivy-state-preselect ivy-last) ivy--index) + (ivy--reset-state ivy-last)) -Either delete a macro from `kmacro-ring', or set `last-kbd-macro' +(defun counsel-kmacro-action-delete-kmacro (candidate) + "Delete the keyboard macro in `counsel-kmacro' CANDIDATE. +Either delete it from `kmacro-ring', or set `last-kbd-macro' to the popped head of the ring." - (let ((actual-macro (cdr x))) - (if (eq (nth 0 actual-macro) last-kbd-macro) - (setq last-kbd-macro - (if (eq kmacro-ring nil) - nil - (let ((prev-macro (pop kmacro-ring))) - (if (listp prev-macro) - (nth 0 prev-macro) - prev-macro)))) - (setq kmacro-ring (delq actual-macro kmacro-ring))))) + (let ((km (cdr candidate))) + (if (memq km kmacro-ring) + (setq kmacro-ring (delq km kmacro-ring)) + (kmacro-delete-ring-head))) + ;; Update state for next `ivy-call'. + ;; TODO: Is `ivy--kill-current-candidate' required? + (let ((kms (ivy-state-collection ivy-last))) + (setf (ivy-state-collection ivy-last) (delq candidate kms)) + (setf (ivy-state-preselect ivy-last) + (max 0 (min ivy--index (1- (length kms)))))) + (ivy--reset-state ivy-last)) -(defun counsel-kmacro-action-copy-initial-counter-value (x) - "Pass an existing keyboard macro's original value to `kmacro-set-counter'. -This value will be used by the next executed macro, or as an -initial value by the next macro defined. +(defun counsel-kmacro-action-copy-initial-counter-value (candidate) + "Pass `counsel-kmacro' CANDIDATE's counter value to `kmacro-set-counter'. +This value will be used by the next executed macro, or as a +starting value by the next macro defined. -Note that calling an existing macro that itself uses a counter -effectively resets the initial counter value for the next defined macro -to 0." - ;; NOTE: - ;; Calling `kmacro-start-macro' without an argument sets `kmacro-counter' - ;; to 0 if `kmacro-initial-counter'is nil, and sets `kmacro-initial-counter' - ;; to nil regardless. - ;; Using `kmacro-insert-counter' sets `kmacro-initial-counter' to nil. - (let* ((actual-kmacro (cdr x)) - (number (nth 1 actual-kmacro))) - (kmacro-set-counter number))) +Note that executing an existing macro that itself uses a counter +effectively resets the starting counter value for the next macro +definition to 0." + (kmacro-set-counter (counsel--with-kmacro (cdr candidate) + kmacro-counter))) -(defun counsel-kmacro-action-copy-counter-format-for-new-macro (x) - "Set the default keyboard macro counter format. -This sets `kmacro-default-counter-format' to the counter format -of an existing keyboard macro. +(defun counsel-kmacro-action-copy-counter-format-for-new-macro (candidate) + "Pass `counsel-kmacro' CANDIDATE's counter format to `kmacro-set-format'. -This will apply to the next macro a user defines." - (let* ((actual-kmacro (cdr x)) - (format (nth 2 actual-kmacro))) - (kmacro-set-format format))) +When no keyboard macro is being defined or executed, this affects the +default for all subsequent macro definitions." + (kmacro-set-format (counsel--with-kmacro (cdr candidate) + kmacro-counter-format-start))) -(declare-function kmacro-cycle-ring-previous "kmacro" (&optional arg)) -(declare-function kmacro-set-format "kmacro" (format)) -(declare-function kmacro-set-counter "kmacro" (arg)) +(defun counsel--kmacro-cycle-until (kmacro) + "Cycle macro ring until KMACRO is the head; return number of steps." + (let ((i 0) + ;; Purely defensive; infloop should never happen. + ;; Purely defensive; infloop should never happen. + ;; Purely defensive; infloop should never happen.[Quit] + (fuel (* 4 (1+ (length kmacro-ring))))) + (while (not (equal kmacro (kmacro-ring-head))) + (unless (natnump (cl-decf fuel)) + (error "`counsel-kmacro' bug: exceeded cycle limit")) + (kmacro-cycle-ring-previous) + (cl-incf i)) + i)) -(defun counsel-kmacro-action-cycle-ring-to-macro (x) +(defun counsel-kmacro-action-cycle-ring-to-macro (candidate) "Cycle `kmacro-ring' until `last-kbd-macro' is the selected macro. -This is convenient when using \\[kmacro-end-or-call-macro] to call macros. -Note that cycling the ring changes the starting value of the current macro -to changes the current macro counter." - (let ((actual-kmacro (cdr x))) - (unless (equal last-kbd-macro - (if (listp last-kbd-macro) - last-kbd-macro - (car actual-kmacro))) - (while (not (equal actual-kmacro - (car kmacro-ring))) - (kmacro-cycle-ring-previous)) - ;; Once selected macro is at the head of the ring, - ;; cycle one last time. - (kmacro-cycle-ring-previous)))) +This is convenient when using \\[kmacro-end-or-call-macro] to call macros." + (counsel--kmacro-cycle-until (cdr candidate)) + ;; Update state for next `ivy-call'. + (setf (ivy-state-collection ivy-last) (counsel--kmacro-candidates)) + (ivy--reset-state ivy-last)) -(defun counsel-kmacro-action-set-saved-starting-counter (x) - "Set the starting counter value of the chosen macro. +(defun counsel-kmacro-action-set-saved-starting-counter (candidate) + "Set the counter value of `counsel-kmacro' CANDIDATE. +Interactively reads a new counter value from the minibuffer. -By default, sets to current value of the counter. It has no -effect when selecting the current macro. +Note that this requires cycling the keyboard macro ring until CANDIDATE, +and then cycling back." + (let* ((km (cdr candidate)) + (cnt (counsel--with-kmacro km kmacro-counter)) + (cnt (if (zerop cnt) cnt (list 0 cnt))) + (i (counsel--kmacro-cycle-until km))) + (setq kmacro-counter (read-number "New macro counter: " cnt)) + (dotimes (_ i) (kmacro-cycle-ring-next))) + ;; Update state for next `ivy-call'. + (setf (ivy-state-collection ivy-last) (counsel--kmacro-candidates)) + (setf (ivy-state-preselect ivy-last) ivy--index) + ;; Emacs 28 seems to have some bug where the text of the candidates + ;; in the minibuffer is not immediately refreshed. + (ivy--reset-state ivy-last)) -Normally, when cycling keyboard macro ring with \\[kmacro-cycle-ring-previous] -or \\[kmacro-cycle-ring-next], the current value of the macro counter is -included with the current macro definition. Then, when cycling -back, that counter value is restored. This function is meant to -achieve something similar when cycling macros in the context of -using `counsel-kmacro', which does not use different counter -values when running different macros." - (let ((actual-kmacro (cdr x)) - (default-kmacro-counter-string (number-to-string kmacro-counter))) - (setq kmacro-ring (mapcar (lambda (this-macro-in-ring) - (if (equal this-macro-in-ring actual-kmacro) - (list (car this-macro-in-ring) - (read-from-minibuffer (concat "Set initial counter for macro (default: " - default-kmacro-counter-string - "): ") - nil nil t nil - default-kmacro-counter-string) - (cl-caddr this-macro-in-ring)) - this-macro-in-ring)) - kmacro-ring)))) +(defun counsel-kmacro-action-execute-after-prompt (candidate) + "Execute selected keyboard macro with a different counter and format. -(defun counsel-kmacro-action-execute-after-prompt (x) - "Execute an existing keyboard macro, prompting for a starting counter value, a -counter format, and the number of times to execute the macro. +Prompt for the number of times to execute the macro, the starting +counter, and the counter format. The corresponding values from the +selected `counsel-kmacro' CANDIDATE serve as defaults. If this action +is called with a prefix argument, its numeric value also serves as a +default option for the number of iterations and counter. -If called with a prefix, will suggest that value for both the -counter value and iteration amount." - (let* ((default-string (if current-prefix-arg - (number-to-string current-prefix-arg) - nil)) - (actual-kmacro (cdr x)) - (kmacro-keys (nth 0 actual-kmacro)) - (kmacro-starting-counter (number-to-string (nth 1 actual-kmacro))) - (kmacro-starting-format (nth 2 actual-kmacro)) - (number-of-iterations - (read-from-minibuffer - (concat "Enter number of iterations for macro (default: " - (or default-string (number-to-string 2)) - "): ") - nil nil t nil - (or default-string (number-to-string 2)))) - (kmacro-initial-counter-value - (read-from-minibuffer - (concat "Enter a starting counter for macro (default: " - (or default-string kmacro-starting-counter) - "): ") - nil nil t nil - (or default-string kmacro-starting-counter))) - (kmacro-counter-format-start - (symbol-name (read-from-minibuffer - (concat "Enter format for macro counter (default: " - kmacro-starting-format - "): ") - nil nil t nil - kmacro-starting-format)))) - (kmacro-call-macro number-of-iterations t nil kmacro-keys))) +The existing CANDIDATE, its counter and format, are left unchanged." + (let* ((pre (or ivy-current-prefix-arg current-prefix-arg)) + (pre (and pre (prefix-numeric-value pre)))) + (counsel--with-kmacro (cdr candidate) + (let ((times (read-number "Number of macro iterations: " + (let ((def '(1 2))) + (if pre (cons pre def) def))))) + (setq kmacro-counter + (read-number "Macro counter value: " + (if pre (list pre kmacro-counter) kmacro-counter))) + (setq kmacro-counter-format-start + (let ((prompt "Macro counter format") + (def kmacro-counter-format-start)) + (read-string (if (fboundp 'format-prompt) + (format-prompt prompt def) + (format "%s (default: %s): " prompt def)) + nil nil def))) + (counsel--kmacro-exec (kmacro-ring-head) times))))) (ivy-set-actions 'counsel-kmacro - '(("c" counsel-kmacro-action-cycle-ring-to-macro "cycle to") - ("d" counsel-kmacro-action-delete-kmacro "delete") - ("e" counsel-kmacro-action-execute-after-prompt "execute after prompt") - ("f" counsel-kmacro-action-copy-counter-format-for-new-macro "copy counter format for new macro") - ("s" counsel-kmacro-action-set-saved-starting-counter "set this counter value") - ("v" counsel-kmacro-action-copy-initial-counter-value "copy initial counter value"))) + `(("c" ,#'counsel-kmacro-action-cycle-ring-to-macro + "cycle to") + ("d" ,#'counsel-kmacro-action-delete-kmacro + "delete") + ("e" ,#'counsel-kmacro-action-execute-after-prompt + "execute after prompt") + ("f" ,#'counsel-kmacro-action-copy-counter-format-for-new-macro + "copy counter format for new macro") + ("s" ,#'counsel-kmacro-action-set-saved-starting-counter + "set this counter value") + ("v" ,#'counsel-kmacro-action-copy-initial-counter-value + "copy starting counter value"))) ;;** `counsel-geiser-doc-look-up-manual' (declare-function geiser-doc-manual-for-symbol "ext:geiser-doc") diff --git a/lisp/dash/dash.info b/lisp/dash/dash.info index 72f8198a..5caf7dde 100644 --- a/lisp/dash/dash.info +++ b/lisp/dash/dash.info @@ -1,16 +1,16 @@ -This is dash.info, produced by makeinfo version 6.8 from dash.texi. +This is dash.info, produced by makeinfo version 7.1.1 from dash.texi. This manual is for Dash version 2.19.1. - Copyright © 2012–2024 Free Software Foundation, Inc. + Copyright © 2012-2024 Free Software Foundation, Inc. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.3 or any later version published by the Free Software - Foundation; with the Invariant Sections being “GNU General Public - License,” and no Front-Cover Texts or Back-Cover Texts. A copy of - the license is included in the section entitled “GNU Free - Documentation License”. + Foundation; with the Invariant Sections being "GNU General Public + License," and no Front-Cover Texts or Back-Cover Texts. A copy of + the license is included in the section entitled "GNU Free + Documentation License". INFO-DIR-SECTION Emacs START-INFO-DIR-ENTRY * Dash: (dash.info). A modern list library for GNU Emacs. @@ -24,15 +24,15 @@ Dash This manual is for Dash version 2.19.1. - Copyright © 2012–2024 Free Software Foundation, Inc. + Copyright © 2012-2024 Free Software Foundation, Inc. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.3 or any later version published by the Free Software - Foundation; with the Invariant Sections being “GNU General Public - License,” and no Front-Cover Texts or Back-Cover Texts. A copy of - the license is included in the section entitled “GNU Free - Documentation License”. + Foundation; with the Invariant Sections being "GNU General Public + License," and no Front-Cover Texts or Back-Cover Texts. A copy of + the license is included in the section entitled "GNU Free + Documentation License". * Menu: @@ -46,7 +46,7 @@ Appendices * GPL:: Conditions for copying and changing Dash. * Index:: Index including functions and macros. - — The Detailed Node Listing — + -- The Detailed Node Listing -- Installation @@ -108,7 +108,7 @@ File: dash.info, Node: Using in a package, Next: Fontification of special vari ====================== If you use Dash in your own package, be sure to list it as a dependency -in the library’s headers as follows (*note (elisp)Library Headers::). +in the library's headers as follows (*note (elisp)Library Headers::). ;; Package-Requires: ((dash "2.19.1")) @@ -214,7 +214,7 @@ The results are collected in order and returned as a new list. -- Function: -map (fn list) Apply FN to each item in LIST and return the list of results. - This function’s anaphoric counterpart is ‘--map’. + This function's anaphoric counterpart is ‘--map’. (-map (lambda (num) (* num num)) '(1 2 3 4)) ⇒ (1 4 9 16) @@ -275,7 +275,7 @@ The results are collected in order and returned as a new list. arguments: the index of the current element within LIST, and the element itself. - This function’s anaphoric counterpart is ‘--map-indexed’. + This function's anaphoric counterpart is ‘--map-indexed’. For a side-effecting variant, see also ‘-each-indexed’ (*note -each-indexed::). @@ -294,7 +294,7 @@ The results are collected in order and returned as a new list. corresponding element of LIST, and RESULT is the value obtained by calling FN on ITEM. - This function’s anaphoric counterpart is ‘--annotate’. + This function's anaphoric counterpart is ‘--annotate’. (-annotate #'1+ '(1 2 3)) ⇒ ((2 . 1) (3 . 2) (4 . 3)) @@ -316,7 +316,7 @@ The results are collected in order and returned as a new list. structure, in case you need to splice several lists at marked positions (for example with keywords). - This function’s anaphoric counterpart is ‘--splice’. + This function's anaphoric counterpart is ‘--splice’. See also: ‘-splice-list’ (*note -splice-list::), ‘-insert-at’ (*note -insert-at::). @@ -374,7 +374,7 @@ Functions returning a sublist of the original list. Alias: ‘-select’. - This function’s anaphoric counterpart is ‘--filter’. + This function's anaphoric counterpart is ‘--filter’. For similar operations, see also ‘-keep’ (*note -keep::) and ‘-remove’ (*note -remove::). @@ -392,7 +392,7 @@ Functions returning a sublist of the original list. Alias: ‘-reject’. - This function’s anaphoric counterpart is ‘--remove’. + This function's anaphoric counterpart is ‘--remove’. For similar operations, see also ‘-keep’ (*note -keep::) and ‘-filter’ (*note -filter::). @@ -407,13 +407,13 @@ Functions returning a sublist of the original list. -- Function: -remove-first (pred list) Remove the first item from LIST for which PRED returns non-‘nil’. This is a non-destructive operation, but only the front of LIST - leading up to the removed item is a copy; the rest is LIST’s + leading up to the removed item is a copy; the rest is LIST's original tail. If no item is removed, then the result is a complete copy. Alias: ‘-reject-first’. - This function’s anaphoric counterpart is ‘--remove-first’. + This function's anaphoric counterpart is ‘--remove-first’. See also ‘-map-first’ (*note -map-first::), ‘-remove-item’ (*note -remove-item::), and ‘-remove-last’ (*note -remove-last::). @@ -432,7 +432,7 @@ Functions returning a sublist of the original list. Alias: ‘-reject-last’. - This function’s anaphoric counterpart is ‘--remove-last’. + This function's anaphoric counterpart is ‘--remove-last’. See also ‘-map-last’ (*note -map-last::), ‘-remove-item’ (*note -remove-item::), and ‘-remove-first’ (*note -remove-first::). @@ -543,7 +543,7 @@ Functions returning a sublist of the original list. successive elements from the start of LIST for which PRED returns non-‘nil’. - This function’s anaphoric counterpart is ‘--take-while’. + This function's anaphoric counterpart is ‘--take-while’. For another variant, see also ‘-drop-while’ (*note -drop-while::). @@ -560,7 +560,7 @@ Functions returning a sublist of the original list. of LIST starting from its first element for which PRED returns ‘nil’. - This function’s anaphoric counterpart is ‘--drop-while’. + This function's anaphoric counterpart is ‘--drop-while’. For another variant, see also ‘-take-while’ (*note -take-while::). @@ -573,7 +573,7 @@ Functions returning a sublist of the original list. -- Function: -select-by-indices (indices list) Return a list whose elements are elements from LIST selected as - ‘(nth i list)‘ for all i from INDICES. + '(nth i list)' for all i from INDICES. (-select-by-indices '(4 10 2 3 6) '("v" "e" "l" "o" "c" "i" "r" "a" "p" "t" "o" "r")) ⇒ ("c" "o" "l" "o" "r") @@ -664,7 +664,7 @@ Functions returning a modified copy of the input list. them back. Conses of two atoms are considered "terminals", that is, they - aren’t flattened further. + aren't flattened further. See also: ‘-flatten-n’ (*note -flatten-n::) @@ -818,7 +818,7 @@ Functions reducing lists to a single value (which may also be a list). applying FN to that result and the second element, etc. If LIST is empty, return INIT without calling FN. - This function’s anaphoric counterpart is ‘--reduce-from’. + This function's anaphoric counterpart is ‘--reduce-from’. For other folds, see also ‘-reduce’ (*note -reduce::) and ‘-reduce-r’ (*note -reduce-r::). @@ -845,7 +845,7 @@ Functions reducing lists to a single value (which may also be a list). applications of FN, and its last link with INIT, and evaluating the resulting expression. - This function’s anaphoric counterpart is ‘--reduce-r-from’. + This function's anaphoric counterpart is ‘--reduce-r-from’. For other folds, see also ‘-reduce-r’ (*note -reduce-r::) and ‘-reduce’ (*note -reduce::). @@ -864,7 +864,7 @@ Functions reducing lists to a single value (which may also be a list). element, return it without calling FN. If LIST is empty, return the result of calling FN with no arguments. - This function’s anaphoric counterpart is ‘--reduce’. + This function's anaphoric counterpart is ‘--reduce’. For other folds, see also ‘-reduce-from’ (*note -reduce-from::) and ‘-reduce-r’ (*note -reduce-r::). @@ -892,7 +892,7 @@ Functions reducing lists to a single value (which may also be a list). applications of FN, ignoring its last link, and evaluating the resulting expression. - This function’s anaphoric counterpart is ‘--reduce-r’. + This function's anaphoric counterpart is ‘--reduce-r’. For other folds, see also ‘-reduce-r-from’ (*note -reduce-r-from::) and ‘-reduce’ (*note -reduce::). @@ -905,12 +905,12 @@ Functions reducing lists to a single value (which may also be a list). ⇒ "3-2-1" -- Function: -reductions-from (fn init list) - Return a list of FN’s intermediate reductions across LIST. That + Return a list of FN's intermediate reductions across LIST. That is, a list of the intermediate values of the accumulator when ‘-reduce-from’ (*note -reduce-from::) (which see) is called with the same arguments. - This function’s anaphoric counterpart is ‘--reductions-from’. + This function's anaphoric counterpart is ‘--reductions-from’. For other folds, see also ‘-reductions’ (*note -reductions::) and ‘-reductions-r’ (*note -reductions-r::). @@ -923,12 +923,12 @@ Functions reducing lists to a single value (which may also be a list). ⇒ ("INIT" "(FN INIT 1)" "(FN (FN INIT 1) 2)" "(FN (FN (FN INIT 1) 2) 3)") -- Function: -reductions-r-from (fn init list) - Return a list of FN’s intermediate reductions across reversed LIST. + Return a list of FN's intermediate reductions across reversed LIST. That is, a list of the intermediate values of the accumulator when ‘-reduce-r-from’ (*note -reduce-r-from::) (which see) is called with the same arguments. - This function’s anaphoric counterpart is ‘--reductions-r-from’. + This function's anaphoric counterpart is ‘--reductions-r-from’. For other folds, see also ‘-reductions’ (*note -reductions::) and ‘-reductions-r’ (*note -reductions-r::). @@ -941,12 +941,12 @@ Functions reducing lists to a single value (which may also be a list). ⇒ ("(FN 1 (FN 2 (FN 3 INIT)))" "(FN 2 (FN 3 INIT))" "(FN 3 INIT)" "INIT") -- Function: -reductions (fn list) - Return a list of FN’s intermediate reductions across LIST. That + Return a list of FN's intermediate reductions across LIST. That is, a list of the intermediate values of the accumulator when ‘-reduce’ (*note -reduce::) (which see) is called with the same arguments. - This function’s anaphoric counterpart is ‘--reductions’. + This function's anaphoric counterpart is ‘--reductions’. For other folds, see also ‘-reductions’ (*note -reductions::) and ‘-reductions-r’ (*note -reductions-r::). @@ -959,12 +959,12 @@ Functions reducing lists to a single value (which may also be a list). ⇒ (1 "(FN 1 2)" "(FN (FN 1 2) 3)") -- Function: -reductions-r (fn list) - Return a list of FN’s intermediate reductions across reversed LIST. + Return a list of FN's intermediate reductions across reversed LIST. That is, a list of the intermediate values of the accumulator when ‘-reduce-r’ (*note -reduce-r::) (which see) is called with the same arguments. - This function’s anaphoric counterpart is ‘--reductions-r’. + This function's anaphoric counterpart is ‘--reductions-r’. For other folds, see also ‘-reductions-r-from’ (*note -reductions-r-from::) and ‘-reductions’ (*note -reductions::). @@ -1213,7 +1213,7 @@ Reductions of one or more lists to a boolean value. Alias: ‘-any’. - This function’s anaphoric counterpart is ‘--some’. + This function's anaphoric counterpart is ‘--some’. (-some #'stringp '(1 "2" 3)) ⇒ t @@ -1231,7 +1231,7 @@ Reductions of one or more lists to a boolean value. This function is like ‘-every-p’, but on success returns the last non-‘nil’ result of PRED instead of just ‘t’. - This function’s anaphoric counterpart is ‘--every’. + This function's anaphoric counterpart is ‘--every’. (-every #'numberp '(1 2 3)) ⇒ t @@ -1263,7 +1263,7 @@ Reductions of one or more lists to a boolean value. Alias: ‘-all-p’, ‘-every-p’, ‘-every?’. - This function’s anaphoric counterpart is ‘--all?’. + This function's anaphoric counterpart is ‘--all?’. (-all? #'numberp '(1 2 3)) ⇒ t @@ -1531,7 +1531,7 @@ Functions partitioning the input list into a list of lists. -- Function: -partition-after-pred (pred list) Partition LIST after each element for which PRED returns non-‘nil’. - This function’s anaphoric counterpart is ‘--partition-after-pred’. + This function's anaphoric counterpart is ‘--partition-after-pred’. (-partition-after-pred #'booleanp ()) ⇒ () @@ -1624,7 +1624,7 @@ predicates. PRED is called with one argument, the current list element, until it returns non-‘nil’, at which point the search terminates. - This function’s anaphoric counterpart is ‘--find-index’. + This function's anaphoric counterpart is ‘--find-index’. See also: ‘-first’ (*note -first::), ‘-find-last-index’ (*note -find-last-index::). @@ -1643,7 +1643,7 @@ predicates. Predicate PRED is called with one argument each time, namely the current list element. - This function’s anaphoric counterpart is ‘--find-last-index’. + This function's anaphoric counterpart is ‘--find-last-index’. See also: ‘-last’ (*note -last::), ‘-find-index’ (*note -find-index::). @@ -1663,7 +1663,7 @@ predicates. result. The returned indices are in ascending order, i.e., in the same order as they appear in LIST. - This function’s anaphoric counterpart is ‘--find-indices’. + This function's anaphoric counterpart is ‘--find-indices’. See also: ‘-find-index’ (*note -find-index::), ‘-elem-indices’ (*note -elem-indices::). @@ -1887,7 +1887,7 @@ Other list functions not fit to be classified elsewhere. LIST1 and as second argument the next element of LIST2 at the corresponding position. The result is as long as the shorter list. - This function’s anaphoric counterpart is ‘--zip-with’. + This function's anaphoric counterpart is ‘--zip-with’. For other zips, see also ‘-zip-lists’ (*note -zip-lists::) and ‘-zip-fill’ (*note -zip-fill::). @@ -2087,7 +2087,7 @@ Other list functions not fit to be classified elsewhere. The results are flattened, ignoring the tensor structure of the result. This is equivalent to calling: - (-flatten-n (1- (length lists)) (apply ’-table fn lists)) + (-flatten-n (1- (length lists)) (apply '-table fn lists)) but the implementation here is much more efficient. @@ -2110,7 +2110,7 @@ Other list functions not fit to be classified elsewhere. Alias: ‘-find’. - This function’s anaphoric counterpart is ‘--first’. + This function's anaphoric counterpart is ‘--first’. (-first #'natnump '(-1 0 1)) ⇒ 0 @@ -2583,8 +2583,8 @@ control. (-let [PATTERN SOURCE] ...). ‘-let’ (*note -let::) uses a convention of not binding places - (symbols) starting with _ whenever it’s possible. You can use this - to skip over entries you don’t care about. However, this is not + (symbols) starting with _ whenever it's possible. You can use this + to skip over entries you don't care about. However, this is not *always* possible (as a result of implementation) and these symbols might get bound to undefined values. @@ -2651,7 +2651,7 @@ control. patterns be optionally left out and derived from the key name in the following fashion: - - a key :foo is converted into ‘foo’ pattern, - a key ’bar is + - a key :foo is converted into ‘foo’ pattern, - a key 'bar is converted into ‘bar’ pattern, - a key "baz" is converted into ‘baz’ pattern. @@ -2665,11 +2665,11 @@ control. Thus the patterns are normalized as follows: - ;; derive all the missing patterns (&plist :foo ’bar "baz") => - (&plist :foo foo ’bar bar "baz" baz) + ;; derive all the missing patterns (&plist :foo 'bar "baz") => + (&plist :foo foo 'bar bar "baz" baz) - ;; we can specify some but not others (&plist :foo ’bar - explicit-bar) => (&plist :foo foo ’bar explicit-bar) + ;; we can specify some but not others (&plist :foo 'bar + explicit-bar) => (&plist :foo foo 'bar explicit-bar) ;; nothing happens, we store :foo in x (&plist :foo x) => (&plist :foo x) @@ -2808,7 +2808,7 @@ Functions iterating over lists for side effect only. Its anaphoric counterpart is ‘--each’. - For access to the current element’s index in LIST, see + For access to the current element's index in LIST, see ‘-each-indexed’ (*note -each-indexed::). (let (l) (-each '(1 2 3) (lambda (x) (push x l))) l) @@ -2879,7 +2879,7 @@ Functions iterating over lists for side effect only. a single argument on successive integers running from 0, inclusive, to NUM, exclusive. FN is not called if NUM is less than 1. - This function’s anaphoric counterpart is ‘--dotimes’. + This function's anaphoric counterpart is ‘--dotimes’. (let (s) (-dotimes 3 (lambda (n) (push n s))) s) ⇒ (2 1 0) @@ -2997,8 +2997,8 @@ Functions that manipulate and compose other functions. For example, the following pairs of expressions are morally equivalent: - (funcall (-on #’+ #’1+) 1 2 3) = (+ (1+ 1) (1+ 2) (1+ 3)) (funcall - (-on #’+ #’1+)) = (+) + (funcall (-on #'+ #'1+) 1 2 3) = (+ (1+ 1) (1+ 2) (1+ 3)) (funcall + (-on #'+ #'1+)) = (+) (-sort (-on #'< #'length) '((1 2 3) (1) (1 2))) ⇒ ((1) (1 2) (1 2 3)) @@ -3013,7 +3013,7 @@ Functions that manipulate and compose other functions. For example, the following two expressions are morally equivalent: - (funcall (-flip #’-) 1 2) = (- 2 1) + (funcall (-flip #'-) 1 2) = (- 2 1) See also: ‘-rotate-args’ (*note -rotate-args::). @@ -3182,17 +3182,17 @@ Functions that manipulate and compose other functions. This function satisfies the following laws: - (-compose (-prodfn f g ...) (-prodfn f’ g’ ...)) = (-prodfn - (-compose f f’) (-compose g g’) ...) + (-compose (-prodfn f g ...) (-prodfn f' g' ...)) = (-prodfn + (-compose f f') (-compose g g') ...) - (-prodfn f g ...) = (-juxt (-compose f (-partial #’nth 0)) - (-compose g (-partial #’nth 1)) ...) + (-prodfn f g ...) = (-juxt (-compose f (-partial #'nth 0)) + (-compose g (-partial #'nth 1)) ...) - (-compose (-prodfn f g ...) (-juxt f’ g’ ...)) = (-juxt (-compose f - f’) (-compose g g’) ...) + (-compose (-prodfn f g ...) (-juxt f' g' ...)) = (-juxt (-compose f + f') (-compose g g') ...) - (-compose (-partial #’nth n) (-prod f1 f2 ...)) = (-compose fn - (-partial #’nth n)) + (-compose (-partial #'nth n) (-prod f1 f2 ...)) = (-compose fn + (-partial #'nth n)) (funcall (-prodfn #'1+ #'1- #'number-to-string) '(1 2 3)) ⇒ (2 1 "3") @@ -3222,7 +3222,7 @@ File: dash.info, Node: Contribute, Next: Contributors, Up: Development ============== Yes, please do. Pure functions in the list manipulation realm only, -please. There’s a suite of examples/tests in ‘dev/examples.el’, so +please. There's a suite of examples/tests in ‘dev/examples.el’, so remember to add tests for your additions, or they may get broken later. Run the tests with ‘make check’. Regenerate the docs with ‘make @@ -3232,7 +3232,7 @@ always in sync: $ cp dev/pre-commit.sh .git/hooks/pre-commit - Oh, and don’t edit ‘README.md’ or ‘dash.texi’ directly, as they are + Oh, and don't edit ‘README.md’ or ‘dash.texi’ directly, as they are auto-generated. Instead, change their respective templates ‘readme-template.md’ or ‘dash-template.texi’. @@ -3308,7 +3308,7 @@ Appendix A GNU Free Documentation License author and publisher a way to get credit for their work, while not being considered responsible for modifications made by others. - This License is a kind of “copyleft”, which means that derivative + This License is a kind of "copyleft", which means that derivative works of the document must themselves be free in the same sense. It complements the GNU General Public License, which is a copyleft license designed for free software. @@ -3329,18 +3329,18 @@ Appendix A GNU Free Documentation License be distributed under the terms of this License. Such a notice grants a world-wide, royalty-free license, unlimited in duration, to use that work under the conditions stated herein. The - “Document”, below, refers to any such manual or work. Any member - of the public is a licensee, and is addressed as “you”. You accept + "Document", below, refers to any such manual or work. Any member + of the public is a licensee, and is addressed as "you". You accept the license if you copy, modify or distribute the work in a way requiring permission under copyright law. - A “Modified Version” of the Document means any work containing the + A "Modified Version" of the Document means any work containing the Document or a portion of it, either copied verbatim, or with modifications and/or translated into another language. - A “Secondary Section” is a named appendix or a front-matter section + A "Secondary Section" is a named appendix or a front-matter section of the Document that deals exclusively with the relationship of the - publishers or authors of the Document to the Document’s overall + publishers or authors of the Document to the Document's overall subject (or to related matters) and contains nothing that could fall directly within that overall subject. (Thus, if the Document is in part a textbook of mathematics, a Secondary Section may not @@ -3349,7 +3349,7 @@ Appendix A GNU Free Documentation License of legal, commercial, philosophical, ethical or political position regarding them. - The “Invariant Sections” are certain Secondary Sections whose + The "Invariant Sections" are certain Secondary Sections whose titles are designated, as being those of Invariant Sections, in the notice that says that the Document is released under this License. If a section does not fit the above definition of Secondary then it @@ -3357,13 +3357,13 @@ Appendix A GNU Free Documentation License contain zero Invariant Sections. If the Document does not identify any Invariant Sections then there are none. - The “Cover Texts” are certain short passages of text that are + The "Cover Texts" are certain short passages of text that are listed, as Front-Cover Texts or Back-Cover Texts, in the notice that says that the Document is released under this License. A Front-Cover Text may be at most 5 words, and a Back-Cover Text may be at most 25 words. - A “Transparent” copy of the Document means a machine-readable copy, + A "Transparent" copy of the Document means a machine-readable copy, represented in a format whose specification is available to the general public, that is suitable for revising the document straightforwardly with generic text editors or (for images composed @@ -3375,7 +3375,7 @@ Appendix A GNU Free Documentation License been arranged to thwart or discourage subsequent modification by readers is not Transparent. An image format is not Transparent if used for any substantial amount of text. A copy that is not - “Transparent” is called “Opaque”. + "Transparent" is called "Opaque". Examples of suitable formats for Transparent copies include plain ASCII without markup, Texinfo input format, LaTeX input format, @@ -3388,23 +3388,23 @@ Appendix A GNU Free Documentation License the machine-generated HTML, PostScript or PDF produced by some word processors for output purposes only. - The “Title Page” means, for a printed book, the title page itself, + The "Title Page" means, for a printed book, the title page itself, plus such following pages as are needed to hold, legibly, the material this License requires to appear in the title page. For - works in formats which do not have any title page as such, “Title - Page” means the text near the most prominent appearance of the - work’s title, preceding the beginning of the body of the text. + works in formats which do not have any title page as such, "Title + Page" means the text near the most prominent appearance of the + work's title, preceding the beginning of the body of the text. - The “publisher” means any person or entity that distributes copies + The "publisher" means any person or entity that distributes copies of the Document to the public. - A section “Entitled XYZ” means a named subunit of the Document + A section "Entitled XYZ" means a named subunit of the Document whose title either is precisely XYZ or contains XYZ in parentheses following text that translates XYZ in another language. (Here XYZ stands for a specific section name mentioned below, such as - “Acknowledgements”, “Dedications”, “Endorsements”, or “History”.) - To “Preserve the Title” of such a section when you modify the - Document means that it remains a section “Entitled XYZ” according + "Acknowledgements", "Dedications", "Endorsements", or "History".) + To "Preserve the Title" of such a section when you modify the + Document means that it remains a section "Entitled XYZ" according to this definition. The Document may include Warranty Disclaimers next to the notice @@ -3434,7 +3434,7 @@ Appendix A GNU Free Documentation License If you publish printed copies (or copies in media that commonly have printed covers) of the Document, numbering more than 100, and - the Document’s license notice requires Cover Texts, you must + the Document's license notice requires Cover Texts, you must enclose the copies in covers that carry, clearly and legibly, all these Cover Texts: Front-Cover Texts on the front cover, and Back-Cover Texts on the back cover. Both covers must also clearly @@ -3506,15 +3506,15 @@ Appendix A GNU Free Documentation License the Addendum below. G. Preserve in that license notice the full lists of Invariant - Sections and required Cover Texts given in the Document’s + Sections and required Cover Texts given in the Document's license notice. H. Include an unaltered copy of this License. - I. Preserve the section Entitled “History”, Preserve its Title, + I. Preserve the section Entitled "History", Preserve its Title, and add to it an item stating at least the title, year, new authors, and publisher of the Modified Version as given on the - Title Page. If there is no section Entitled “History” in the + Title Page. If there is no section Entitled "History" in the Document, create one stating the title, year, authors, and publisher of the Document as given on its Title Page, then add an item describing the Modified Version as stated in the @@ -3524,12 +3524,12 @@ Appendix A GNU Free Documentation License for public access to a Transparent copy of the Document, and likewise the network locations given in the Document for previous versions it was based on. These may be placed in the - “History” section. You may omit a network location for a work + "History" section. You may omit a network location for a work that was published at least four years before the Document itself, or if the original publisher of the version it refers to gives permission. - K. For any section Entitled “Acknowledgements” or “Dedications”, + K. For any section Entitled "Acknowledgements" or "Dedications", Preserve the Title of the section, and preserve in the section all the substance and tone of each of the contributor acknowledgements and/or dedications given therein. @@ -3538,11 +3538,11 @@ Appendix A GNU Free Documentation License in their text and in their titles. Section numbers or the equivalent are not considered part of the section titles. - M. Delete any section Entitled “Endorsements”. Such a section + M. Delete any section Entitled "Endorsements". Such a section may not be included in the Modified Version. N. Do not retitle any existing section to be Entitled - “Endorsements” or to conflict in title with any Invariant + "Endorsements" or to conflict in title with any Invariant Section. O. Preserve any Warranty Disclaimers. @@ -3551,15 +3551,15 @@ Appendix A GNU Free Documentation License appendices that qualify as Secondary Sections and contain no material copied from the Document, you may at your option designate some or all of these sections as invariant. To do this, add their - titles to the list of Invariant Sections in the Modified Version’s + titles to the list of Invariant Sections in the Modified Version's license notice. These titles must be distinct from any other section titles. - You may add a section Entitled “Endorsements”, provided it contains + You may add a section Entitled "Endorsements", provided it contains nothing but endorsements of your Modified Version by various - parties—for example, statements of peer review or that the text has - been approved by an organization as the authoritative definition of - a standard. + parties--for example, statements of peer review or that the text + has been approved by an organization as the authoritative + definition of a standard. You may add a passage of up to five words as a Front-Cover Text, and a passage of up to 25 words as a Back-Cover Text, to the end of @@ -3597,10 +3597,10 @@ Appendix A GNU Free Documentation License combined work. In the combination, you must combine any sections Entitled - “History” in the various original documents, forming one section - Entitled “History”; likewise combine any sections Entitled - “Acknowledgements”, and any sections Entitled “Dedications”. You - must delete all sections Entitled “Endorsements.” + "History" in the various original documents, forming one section + Entitled "History"; likewise combine any sections Entitled + "Acknowledgements", and any sections Entitled "Dedications". You + must delete all sections Entitled "Endorsements." 6. COLLECTIONS OF DOCUMENTS @@ -3621,16 +3621,16 @@ Appendix A GNU Free Documentation License A compilation of the Document or its derivatives with other separate and independent documents or works, in or on a volume of a - storage or distribution medium, is called an “aggregate” if the + storage or distribution medium, is called an "aggregate" if the copyright resulting from the compilation is not used to limit the - legal rights of the compilation’s users beyond what the individual + legal rights of the compilation's users beyond what the individual works permit. When the Document is included in an aggregate, this License does not apply to the other works in the aggregate which are not themselves derivative works of the Document. If the Cover Text requirement of section 3 is applicable to these copies of the Document, then if the Document is less than one half - of the entire aggregate, the Document’s Cover Texts may be placed + of the entire aggregate, the Document's Cover Texts may be placed on covers that bracket the Document within the aggregate, or the electronic equivalent of covers if the Document is in electronic form. Otherwise they must appear on printed covers that bracket @@ -3652,8 +3652,8 @@ Appendix A GNU Free Documentation License this License or a notice or disclaimer, the original version will prevail. - If a section in the Document is Entitled “Acknowledgements”, - “Dedications”, or “History”, the requirement (section 4) to + If a section in the Document is Entitled "Acknowledgements", + "Dedications", or "History", the requirement (section 4) to Preserve its Title (section 1) will typically require changing the actual title. @@ -3694,7 +3694,7 @@ Appendix A GNU Free Documentation License Each version of the License is given a distinguishing version number. If the Document specifies that a particular numbered - version of this License “or any later version” applies to it, you + version of this License "or any later version" applies to it, you have the option of following the terms and conditions either of that specified version or of any later version that has been published (not as a draft) by the Free Software Foundation. If the @@ -3702,29 +3702,29 @@ Appendix A GNU Free Documentation License choose any version ever published (not as a draft) by the Free Software Foundation. If the Document specifies that a proxy can decide which future versions of this License can be used, that - proxy’s public statement of acceptance of a version permanently + proxy's public statement of acceptance of a version permanently authorizes you to choose that version for the Document. 11. RELICENSING - “Massive Multiauthor Collaboration Site” (or “MMC Site”) means any + "Massive Multiauthor Collaboration Site" (or "MMC Site") means any World Wide Web server that publishes copyrightable works and also provides prominent facilities for anybody to edit those works. A public wiki that anybody can edit is an example of such a server. - A “Massive Multiauthor Collaboration” (or “MMC”) contained in the + A "Massive Multiauthor Collaboration" (or "MMC") contained in the site means any set of copyrightable works thus published on the MMC site. - “CC-BY-SA” means the Creative Commons Attribution-Share Alike 3.0 + "CC-BY-SA" means the Creative Commons Attribution-Share Alike 3.0 license published by Creative Commons Corporation, a not-for-profit corporation with a principal place of business in San Francisco, California, as well as future copyleft versions of that license published by that same organization. - “Incorporate” means to publish or republish a Document, in whole or + "Incorporate" means to publish or republish a Document, in whole or in part, as part of another Document. - An MMC is “eligible for relicensing” if it is licensed under this + An MMC is "eligible for relicensing" if it is licensed under this License, and if all works that were first published under this License somewhere other than this MMC, and subsequently incorporated in whole or in part into the MMC, (1) had no cover @@ -3751,7 +3751,7 @@ notices just after the title page: Free Documentation License''. If you have Invariant Sections, Front-Cover Texts and Back-Cover -Texts, replace the “with...Texts.” line with this: +Texts, replace the "with...Texts." line with this: with the Invariant Sections being LIST THEIR TITLES, with the Front-Cover Texts being LIST, and with the Back-Cover Texts @@ -3788,7 +3788,7 @@ and other kinds of works. The licenses for most software and other practical works are designed to take away your freedom to share and change the works. By contrast, the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program—to make sure it remains free +share and change all versions of a program--to make sure it remains free software for all its users. We, the Free Software Foundation, use the GNU General Public License for most of our software; it applies also to any other work released this way by its authors. You can apply it to @@ -3816,16 +3816,16 @@ know their rights. (1) assert copyright on the software, and (2) offer you this License giving you legal permission to copy, distribute and/or modify it. - For the developers’ and authors’ protection, the GPL clearly explains -that there is no warranty for this free software. For both users’ and -authors’ sake, the GPL requires that modified versions be marked as + For the developers' and authors' protection, the GPL clearly explains +that there is no warranty for this free software. For both users' and +authors' sake, the GPL requires that modified versions be marked as changed, so that their problems will not be attributed erroneously to authors of previous versions. Some devices are designed to deny users access to install or run modified versions of the software inside them, although the manufacturer can do so. This is fundamentally incompatible with the aim of -protecting users’ freedom to change the software. The systematic +protecting users' freedom to change the software. The systematic pattern of such abuse occurs in the area of products for individuals to use, which is precisely where it is most unacceptable. Therefore, we have designed this version of the GPL to prohibit the practice for those @@ -3848,25 +3848,25 @@ TERMS AND CONDITIONS 0. Definitions. - “This License” refers to version 3 of the GNU General Public + "This License" refers to version 3 of the GNU General Public License. - “Copyright” also means copyright-like laws that apply to other + "Copyright" also means copyright-like laws that apply to other kinds of works, such as semiconductor masks. - “The Program” refers to any copyrightable work licensed under this - License. Each licensee is addressed as “you”. “Licensees” and - “recipients” may be individuals or organizations. + "The Program" refers to any copyrightable work licensed under this + License. Each licensee is addressed as "you". "Licensees" and + "recipients" may be individuals or organizations. - To “modify” a work means to copy from or adapt all or part of the + To "modify" a work means to copy from or adapt all or part of the work in a fashion requiring copyright permission, other than the - making of an exact copy. The resulting work is called a “modified - version” of the earlier work or a work “based on” the earlier work. + making of an exact copy. The resulting work is called a "modified + version" of the earlier work or a work "based on" the earlier work. - A “covered work” means either the unmodified Program or a work + A "covered work" means either the unmodified Program or a work based on the Program. - To “propagate” a work means to do anything with it that, without + To "propagate" a work means to do anything with it that, without permission, would make you directly or secondarily liable for infringement under applicable copyright law, except executing it on a computer or modifying a private copy. Propagation includes @@ -3874,12 +3874,12 @@ TERMS AND CONDITIONS available to the public, and in some countries other activities as well. - To “convey” a work means any kind of propagation that enables other + To "convey" a work means any kind of propagation that enables other parties to make or receive copies. Mere interaction with a user through a computer network, with no transfer of a copy, is not conveying. - An interactive user interface displays “Appropriate Legal Notices” + An interactive user interface displays "Appropriate Legal Notices" to the extent that it includes a convenient and prominently visible feature that (1) displays an appropriate copyright notice, and (2) tells the user that there is no warranty for the work (except to @@ -3891,33 +3891,33 @@ TERMS AND CONDITIONS 1. Source Code. - The “source code” for a work means the preferred form of the work - for making modifications to it. “Object code” means any non-source + The "source code" for a work means the preferred form of the work + for making modifications to it. "Object code" means any non-source form of a work. - A “Standard Interface” means an interface that either is an + A "Standard Interface" means an interface that either is an official standard defined by a recognized standards body, or, in the case of interfaces specified for a particular programming language, one that is widely used among developers working in that language. - The “System Libraries” of an executable work include anything, + The "System Libraries" of an executable work include anything, other than the work as a whole, that (a) is included in the normal form of packaging a Major Component, but which is not part of that Major Component, and (b) serves only to enable use of the work with that Major Component, or to implement a Standard Interface for which an implementation is available to the public in source code - form. A “Major Component”, in this context, means a major + form. A "Major Component", in this context, means a major essential component (kernel, window system, and so on) of the specific operating system (if any) on which the executable work runs, or a compiler used to produce the work, or an object code interpreter used to run it. - The “Corresponding Source” for a work in object code form means all + The "Corresponding Source" for a work in object code form means all the source code needed to generate, install, and (for an executable work) run the object code and to modify the work, including scripts to control those activities. However, it does not include the - work’s System Libraries, or general-purpose tools or generally + work's System Libraries, or general-purpose tools or generally available free programs which are used unmodified in performing those activities but which are not part of the work. For example, Corresponding Source includes interface definition files associated @@ -3961,7 +3961,7 @@ TERMS AND CONDITIONS the conditions stated below. Sublicensing is not allowed; section 10 makes it unnecessary. - 3. Protecting Users’ Legal Rights From Anti-Circumvention Law. + 3. Protecting Users' Legal Rights From Anti-Circumvention Law. No covered work shall be deemed part of an effective technological measure under any applicable law fulfilling obligations under @@ -3974,12 +3974,12 @@ TERMS AND CONDITIONS circumvention is effected by exercising rights under this License with respect to the covered work, and you disclaim any intention to limit operation or modification of the work as a means of - enforcing, against the work’s users, your or third parties’ legal + enforcing, against the work's users, your or third parties' legal rights to forbid circumvention of technological measures. 4. Conveying Verbatim Copies. - You may convey verbatim copies of the Program’s source code as you + You may convey verbatim copies of the Program's source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice; keep intact all notices stating that this License and any @@ -4003,7 +4003,7 @@ TERMS AND CONDITIONS b. The work must carry prominent notices stating that it is released under this License and any conditions added under section 7. This requirement modifies the requirement in - section 4 to “keep intact all notices”. + section 4 to "keep intact all notices". c. You must license the entire work, as a whole, under this License to anyone who comes into possession of a copy. This @@ -4023,9 +4023,9 @@ TERMS AND CONDITIONS works, which are not by their nature extensions of the covered work, and which are not combined with it such as to form a larger program, in or on a volume of a storage or distribution medium, is - called an “aggregate” if the compilation and its resulting + called an "aggregate" if the compilation and its resulting copyright are not used to limit the access or legal rights of the - compilation’s users beyond what the individual works permit. + compilation's users beyond what the individual works permit. Inclusion of a covered work in an aggregate does not cause this License to apply to the other parts of the aggregate. @@ -4083,13 +4083,13 @@ TERMS AND CONDITIONS excluded from the Corresponding Source as a System Library, need not be included in conveying the object code work. - A “User Product” is either (1) a “consumer product”, which means + A "User Product" is either (1) a "consumer product", which means any tangible personal property which is normally used for personal, family, or household purposes, or (2) anything designed or sold for incorporation into a dwelling. In determining whether a product is a consumer product, doubtful cases shall be resolved in favor of coverage. For a particular product received by a particular user, - “normally used” refers to a typical or common use of that class of + "normally used" refers to a typical or common use of that class of product, regardless of the status of the particular user or of the way in which the particular user actually uses, or expects or is expected to use, the product. A product is a consumer product @@ -4097,7 +4097,7 @@ TERMS AND CONDITIONS industrial or non-consumer uses, unless such uses represent the only significant mode of use of the product. - “Installation Information” for a User Product means any methods, + "Installation Information" for a User Product means any methods, procedures, authorization keys, or other information required to install and execute modified versions of a covered work in that User Product from a modified version of its Corresponding Source. @@ -4133,7 +4133,7 @@ TERMS AND CONDITIONS 7. Additional Terms. - “Additional permissions” are terms that supplement the terms of + "Additional permissions" are terms that supplement the terms of this License by making exceptions from one or more of its conditions. Additional permissions that are applicable to the entire Program shall be treated as though they were included in @@ -4178,8 +4178,8 @@ TERMS AND CONDITIONS the recipient, for any liability that these contractual assumptions directly impose on those licensors and authors. - All other non-permissive additional terms are considered “further - restrictions” within the meaning of section 10. If the Program as + All other non-permissive additional terms are considered "further + restrictions" within the meaning of section 10. If the Program as you received it, or any part of it, contains a notice stating that it is governed by this License along with a term that is a further restriction, you may remove that term. If a license document @@ -4245,12 +4245,12 @@ TERMS AND CONDITIONS responsible for enforcing compliance by third parties with this License. - An “entity transaction” is a transaction transferring control of an + An "entity transaction" is a transaction transferring control of an organization, or substantially all assets of one, or subdividing an organization, or merging organizations. If propagation of a covered work results from an entity transaction, each party to that transaction who receives a copy of the work also receives whatever - licenses to the work the party’s predecessor in interest had or + licenses to the work the party's predecessor in interest had or could give under the previous paragraph, plus a right to possession of the Corresponding Source of the work from the predecessor in interest, if the predecessor has it or can get it with reasonable @@ -4267,31 +4267,31 @@ TERMS AND CONDITIONS 11. Patents. - A “contributor” is a copyright holder who authorizes use under this + A "contributor" is a copyright holder who authorizes use under this License of the Program or a work on which the Program is based. - The work thus licensed is called the contributor’s “contributor - version”. + The work thus licensed is called the contributor's "contributor + version". - A contributor’s “essential patent claims” are all patent claims + A contributor's "essential patent claims" are all patent claims owned or controlled by the contributor, whether already acquired or hereafter acquired, that would be infringed by some manner, permitted by this License, of making, using, or selling its contributor version, but do not include claims that would be infringed only as a consequence of further modification of the - contributor version. For purposes of this definition, “control” + contributor version. For purposes of this definition, "control" includes the right to grant patent sublicenses in a manner consistent with the requirements of this License. Each contributor grants you a non-exclusive, worldwide, - royalty-free patent license under the contributor’s essential + royalty-free patent license under the contributor's essential patent claims, to make, use, sell, offer for sale, import and otherwise run, modify and propagate the contents of its contributor version. - In the following three paragraphs, a “patent license” is any + In the following three paragraphs, a "patent license" is any express agreement or commitment, however denominated, not to enforce a patent (such as an express permission to practice a - patent or covenant not to sue for patent infringement). To “grant” + patent or covenant not to sue for patent infringement). To "grant" such a patent license to a party means to make such an agreement or commitment not to enforce a patent against the party. @@ -4304,9 +4304,9 @@ TERMS AND CONDITIONS yourself of the benefit of the patent license for this particular work, or (3) arrange, in a manner consistent with the requirements of this License, to extend the patent license to downstream - recipients. “Knowingly relying” means you have actual knowledge + recipients. "Knowingly relying" means you have actual knowledge that, but for the patent license, your conveying the covered work - in a country, or your recipient’s use of the covered work in a + in a country, or your recipient's use of the covered work in a country, would infringe one or more identifiable patents in that country that you have reason to believe are valid. @@ -4318,7 +4318,7 @@ TERMS AND CONDITIONS patent license you grant is automatically extended to all recipients of the covered work and works based on it. - A patent license is “discriminatory” if it does not include within + A patent license is "discriminatory" if it does not include within the scope of its coverage, prohibits the exercise of, or is conditioned on the non-exercise of one or more of the rights that are specifically granted under this License. You may not convey a @@ -4338,7 +4338,7 @@ TERMS AND CONDITIONS any implied license or other defenses to infringement that may otherwise be available to you under applicable patent law. - 12. No Surrender of Others’ Freedom. + 12. No Surrender of Others' Freedom. If conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they @@ -4371,7 +4371,7 @@ TERMS AND CONDITIONS Each version is given a distinguishing version number. If the Program specifies that a certain numbered version of the GNU - General Public License “or any later version” applies to it, you + General Public License "or any later version" applies to it, you have the option of following the terms and conditions either of that numbered version or of any later version published by the Free Software Foundation. If the Program does not specify a version @@ -4380,7 +4380,7 @@ TERMS AND CONDITIONS If the Program specifies that a proxy can decide which future versions of the GNU General Public License can be used, that - proxy’s public statement of acceptance of a version permanently + proxy's public statement of acceptance of a version permanently authorizes you to choose that version for the Program. Later license versions may give you additional or different @@ -4392,7 +4392,7 @@ TERMS AND CONDITIONS THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE - COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM “AS IS” + COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE @@ -4436,7 +4436,7 @@ terms. To do so, attach the following notices to the program. It is safest to attach them to the start of each source file to most effectively state the exclusion of warranty; and each file should have at least the -“copyright” line and a pointer to where the full notice is found. +"copyright" line and a pointer to where the full notice is found. ONE LINE TO GIVE THE PROGRAM'S NAME AND A BRIEF IDEA OF WHAT IT DOES. Copyright (C) YEAR NAME OF AUTHOR @@ -4467,11 +4467,11 @@ notice like this when it starts in an interactive mode: The hypothetical commands ‘show w’ and ‘show c’ should show the appropriate parts of the General Public License. Of course, your -program’s commands might be different; for a GUI interface, you would -use an “about box”. +program's commands might be different; for a GUI interface, you would +use an "about box". You should also get your employer (if you work as a programmer) or -school, if any, to sign a “copyright disclaimer” for the program, if +school, if any, to sign a "copyright disclaimer" for the program, if necessary. For more information on this, and how to apply and follow the GNU GPL, see . @@ -4491,10 +4491,6 @@ Index [index] * Menu: -* !cdr: Destructive operations. - (line 16) -* !cons: Destructive operations. - (line 8) * -->: Threading macros. (line 35) * ->: Threading macros. (line 9) * ->>: Threading macros. (line 22) @@ -4514,9 +4510,9 @@ Index * -compose: Function combinators. (line 49) * -concat: List to list. (line 23) +* -cons-pair?: Predicates. (line 154) * -cons*: Other list operations. (line 19) -* -cons-pair?: Predicates. (line 154) * -const: Function combinators. (line 128) * -contains?: Predicates. (line 100) @@ -4720,6 +4716,10 @@ Index (line 98) * -zip-with: Other list operations. (line 80) +* !cdr: Destructive operations. + (line 16) +* !cons: Destructive operations. + (line 8) * dash-fontify-mode: Fontification of special variables. (line 6) * dash-register-info-lookup: Info symbol lookup. (line 6) @@ -4729,216 +4729,216 @@ Index  Tag Table: -Node: Top742 -Node: Installation2397 -Node: Using in a package3159 -Node: Fontification of special variables3504 -Node: Info symbol lookup4294 -Node: Functions4877 -Node: Maps6361 -Ref: -map6658 -Ref: -map-when7031 -Ref: -map-first7605 -Ref: -map-last8200 -Ref: -map-indexed8790 -Ref: -annotate9476 -Ref: -splice10080 -Ref: -splice-list11155 -Ref: -mapcat11614 -Ref: -copy11987 -Node: Sublist selection12175 -Ref: -filter12368 -Ref: -remove12921 -Ref: -remove-first13470 -Ref: -remove-last14318 -Ref: -remove-item15048 -Ref: -non-nil15448 -Ref: -slice15730 -Ref: -take16259 -Ref: -take-last16677 -Ref: -drop17114 -Ref: -drop-last17561 -Ref: -take-while17993 -Ref: -drop-while18620 -Ref: -select-by-indices19253 -Ref: -select-columns19764 -Ref: -select-column20467 -Node: List to list20930 -Ref: -keep21122 -Ref: -concat21698 -Ref: -flatten22226 -Ref: -flatten-n22988 -Ref: -replace23372 -Ref: -replace-first23833 -Ref: -replace-last24328 -Ref: -insert-at24816 -Ref: -replace-at25141 -Ref: -update-at25528 -Ref: -remove-at26069 -Ref: -remove-at-indices26696 -Node: Reductions27386 -Ref: -reduce-from27582 -Ref: -reduce-r-from28306 -Ref: -reduce29569 -Ref: -reduce-r30320 -Ref: -reductions-from31598 -Ref: -reductions-r-from32404 -Ref: -reductions33234 -Ref: -reductions-r33945 -Ref: -count34690 -Ref: -sum34920 -Ref: -running-sum35108 -Ref: -product35429 -Ref: -running-product35637 -Ref: -inits35978 -Ref: -tails36223 -Ref: -common-prefix36468 -Ref: -common-suffix36762 -Ref: -min37056 -Ref: -min-by37282 -Ref: -max37803 -Ref: -max-by38028 -Ref: -frequencies38554 -Node: Unfolding39169 -Ref: -iterate39410 -Ref: -unfold39857 -Ref: -repeat40662 -Ref: -cycle40946 -Node: Predicates41343 -Ref: -some41520 -Ref: -every41949 -Ref: -any?42663 -Ref: -all?43012 -Ref: -none?43754 -Ref: -only-some?44074 -Ref: -contains?44619 -Ref: -is-prefix?45125 -Ref: -is-suffix?45457 -Ref: -is-infix?45789 -Ref: -cons-pair?46149 -Node: Partitioning46480 -Ref: -split-at46668 -Ref: -split-with47332 -Ref: -split-on47972 -Ref: -split-when48643 -Ref: -separate49286 -Ref: -partition49820 -Ref: -partition-all50269 -Ref: -partition-in-steps50694 -Ref: -partition-all-in-steps51240 -Ref: -partition-by51754 -Ref: -partition-by-header52132 -Ref: -partition-after-pred52733 -Ref: -partition-before-pred53186 -Ref: -partition-before-item53571 -Ref: -partition-after-item53878 -Ref: -group-by54180 -Node: Indexing54613 -Ref: -elem-index54815 -Ref: -elem-indices55302 -Ref: -find-index55761 -Ref: -find-last-index56430 -Ref: -find-indices57081 -Ref: -grade-up57843 -Ref: -grade-down58250 -Node: Set operations58664 -Ref: -union58847 -Ref: -difference59277 -Ref: -intersection59705 -Ref: -powerset60134 -Ref: -permutations60411 -Ref: -distinct60849 -Ref: -same-items?61243 -Node: Other list operations61852 -Ref: -rotate62077 -Ref: -cons*62430 -Ref: -snoc62852 -Ref: -interpose63264 -Ref: -interleave63558 -Ref: -iota63924 -Ref: -zip-with64407 -Ref: -zip-pair65215 -Ref: -zip-lists65781 -Ref: -zip-lists-fill66579 -Ref: -zip67289 -Ref: -zip-fill68316 -Ref: -unzip-lists69230 -Ref: -unzip69853 -Ref: -pad70846 -Ref: -table71331 -Ref: -table-flat72117 -Ref: -first73122 -Ref: -last73655 -Ref: -first-item74001 -Ref: -second-item74413 -Ref: -third-item74830 -Ref: -fourth-item75205 -Ref: -fifth-item75583 -Ref: -last-item75958 -Ref: -butlast76319 -Ref: -sort76564 -Ref: -list77058 -Ref: -fix77627 -Node: Tree operations78116 -Ref: -tree-seq78312 -Ref: -tree-map79173 -Ref: -tree-map-nodes79613 -Ref: -tree-reduce80477 -Ref: -tree-reduce-from81359 -Ref: -tree-mapreduce81959 -Ref: -tree-mapreduce-from82818 -Ref: -clone84103 -Node: Threading macros84441 -Ref: ->84666 -Ref: ->>85154 -Ref: -->85657 -Ref: -as->86214 -Ref: -some->86668 -Ref: -some->>87053 -Ref: -some-->87500 -Ref: -doto88067 -Node: Binding88620 -Ref: -when-let88827 -Ref: -when-let*89288 -Ref: -if-let89817 -Ref: -if-let*90183 -Ref: -let90806 -Ref: -let*96896 -Ref: -lambda97833 -Ref: -setq98639 -Node: Side effects99440 -Ref: -each99634 -Ref: -each-while100161 -Ref: -each-indexed100781 -Ref: -each-r101373 -Ref: -each-r-while101815 -Ref: -dotimes102459 -Node: Destructive operations103012 -Ref: !cons103230 -Ref: !cdr103434 -Node: Function combinators103627 -Ref: -partial103831 -Ref: -rpartial104349 -Ref: -juxt104997 -Ref: -compose105449 -Ref: -applify106056 -Ref: -on106486 -Ref: -flip107258 -Ref: -rotate-args107782 -Ref: -const108411 -Ref: -cut108753 -Ref: -not109233 -Ref: -orfn109777 -Ref: -andfn110570 -Ref: -iteratefn111357 -Ref: -fixfn112059 -Ref: -prodfn113633 -Node: Development114784 -Node: Contribute115073 -Node: Contributors116085 -Node: FDL118178 -Node: GPL143498 -Node: Index181247 +Node: Top734 +Node: Installation2377 +Node: Using in a package3139 +Node: Fontification of special variables3482 +Node: Info symbol lookup4272 +Node: Functions4855 +Node: Maps6339 +Ref: -map6636 +Ref: -map-when7007 +Ref: -map-first7581 +Ref: -map-last8176 +Ref: -map-indexed8766 +Ref: -annotate9450 +Ref: -splice10052 +Ref: -splice-list11125 +Ref: -mapcat11584 +Ref: -copy11957 +Node: Sublist selection12145 +Ref: -filter12338 +Ref: -remove12889 +Ref: -remove-first13436 +Ref: -remove-last14280 +Ref: -remove-item15008 +Ref: -non-nil15408 +Ref: -slice15690 +Ref: -take16219 +Ref: -take-last16637 +Ref: -drop17074 +Ref: -drop-last17521 +Ref: -take-while17953 +Ref: -drop-while18578 +Ref: -select-by-indices19209 +Ref: -select-columns19716 +Ref: -select-column20419 +Node: List to list20882 +Ref: -keep21074 +Ref: -concat21650 +Ref: -flatten22178 +Ref: -flatten-n22938 +Ref: -replace23322 +Ref: -replace-first23783 +Ref: -replace-last24278 +Ref: -insert-at24766 +Ref: -replace-at25091 +Ref: -update-at25478 +Ref: -remove-at26019 +Ref: -remove-at-indices26646 +Node: Reductions27336 +Ref: -reduce-from27532 +Ref: -reduce-r-from28254 +Ref: -reduce29515 +Ref: -reduce-r30264 +Ref: -reductions-from31540 +Ref: -reductions-r-from32342 +Ref: -reductions33168 +Ref: -reductions-r33875 +Ref: -count34616 +Ref: -sum34846 +Ref: -running-sum35034 +Ref: -product35355 +Ref: -running-product35563 +Ref: -inits35904 +Ref: -tails36149 +Ref: -common-prefix36394 +Ref: -common-suffix36688 +Ref: -min36982 +Ref: -min-by37208 +Ref: -max37729 +Ref: -max-by37954 +Ref: -frequencies38480 +Node: Unfolding39095 +Ref: -iterate39336 +Ref: -unfold39783 +Ref: -repeat40588 +Ref: -cycle40872 +Node: Predicates41269 +Ref: -some41446 +Ref: -every41873 +Ref: -any?42585 +Ref: -all?42934 +Ref: -none?43674 +Ref: -only-some?43994 +Ref: -contains?44539 +Ref: -is-prefix?45045 +Ref: -is-suffix?45377 +Ref: -is-infix?45709 +Ref: -cons-pair?46069 +Node: Partitioning46400 +Ref: -split-at46588 +Ref: -split-with47252 +Ref: -split-on47892 +Ref: -split-when48563 +Ref: -separate49206 +Ref: -partition49740 +Ref: -partition-all50189 +Ref: -partition-in-steps50614 +Ref: -partition-all-in-steps51160 +Ref: -partition-by51674 +Ref: -partition-by-header52052 +Ref: -partition-after-pred52653 +Ref: -partition-before-pred53104 +Ref: -partition-before-item53489 +Ref: -partition-after-item53796 +Ref: -group-by54098 +Node: Indexing54531 +Ref: -elem-index54733 +Ref: -elem-indices55220 +Ref: -find-index55679 +Ref: -find-last-index56346 +Ref: -find-indices56995 +Ref: -grade-up57755 +Ref: -grade-down58162 +Node: Set operations58576 +Ref: -union58759 +Ref: -difference59189 +Ref: -intersection59617 +Ref: -powerset60046 +Ref: -permutations60323 +Ref: -distinct60761 +Ref: -same-items?61155 +Node: Other list operations61764 +Ref: -rotate61989 +Ref: -cons*62342 +Ref: -snoc62764 +Ref: -interpose63176 +Ref: -interleave63470 +Ref: -iota63836 +Ref: -zip-with64319 +Ref: -zip-pair65125 +Ref: -zip-lists65691 +Ref: -zip-lists-fill66489 +Ref: -zip67199 +Ref: -zip-fill68226 +Ref: -unzip-lists69140 +Ref: -unzip69763 +Ref: -pad70756 +Ref: -table71241 +Ref: -table-flat72027 +Ref: -first73030 +Ref: -last73561 +Ref: -first-item73907 +Ref: -second-item74319 +Ref: -third-item74736 +Ref: -fourth-item75111 +Ref: -fifth-item75489 +Ref: -last-item75864 +Ref: -butlast76225 +Ref: -sort76470 +Ref: -list76964 +Ref: -fix77533 +Node: Tree operations78022 +Ref: -tree-seq78218 +Ref: -tree-map79079 +Ref: -tree-map-nodes79519 +Ref: -tree-reduce80383 +Ref: -tree-reduce-from81265 +Ref: -tree-mapreduce81865 +Ref: -tree-mapreduce-from82724 +Ref: -clone84009 +Node: Threading macros84347 +Ref: ->84572 +Ref: ->>85060 +Ref: -->85563 +Ref: -as->86120 +Ref: -some->86574 +Ref: -some->>86959 +Ref: -some-->87406 +Ref: -doto87973 +Node: Binding88526 +Ref: -when-let88733 +Ref: -when-let*89194 +Ref: -if-let89723 +Ref: -if-let*90089 +Ref: -let90712 +Ref: -let*96788 +Ref: -lambda97725 +Ref: -setq98531 +Node: Side effects99332 +Ref: -each99526 +Ref: -each-while100051 +Ref: -each-indexed100671 +Ref: -each-r101263 +Ref: -each-r-while101705 +Ref: -dotimes102349 +Node: Destructive operations102900 +Ref: !cons103118 +Ref: !cdr103322 +Node: Function combinators103515 +Ref: -partial103719 +Ref: -rpartial104237 +Ref: -juxt104885 +Ref: -compose105337 +Ref: -applify105944 +Ref: -on106374 +Ref: -flip107138 +Ref: -rotate-args107660 +Ref: -const108289 +Ref: -cut108631 +Ref: -not109111 +Ref: -orfn109655 +Ref: -andfn110448 +Ref: -iteratefn111235 +Ref: -fixfn111937 +Ref: -prodfn113511 +Node: Development114638 +Node: Contribute114927 +Node: Contributors115935 +Node: FDL118028 +Node: GPL143147 +Node: Index180693  End Tag Table diff --git a/lisp/dashboard/dashboard-pkg.el b/lisp/dashboard/dashboard-pkg.el index 4dfcd911..8b4cc18d 100644 --- a/lisp/dashboard/dashboard-pkg.el +++ b/lisp/dashboard/dashboard-pkg.el @@ -1,6 +1,6 @@ -(define-package "dashboard" "20250212.1925" "A startup screen extracted from Spacemacs" +(define-package "dashboard" "20250227.121" "A startup screen extracted from Spacemacs" '((emacs "27.1")) - :commit "9adf24569d76e428fb98a562f1f1e087dc9d608d" :authors + :commit "9616e5b5e793c3d8228a8fccf7b9ef7ace365005" :authors '(("Rakan Al-Hneiti" . "rakan.alhneiti@gmail.com")) :maintainers '(("Jen-Chieh" . "jcs090218@gmail.com") diff --git a/lisp/dashboard/dashboard.el b/lisp/dashboard/dashboard.el index 545ea971..2d6cb759 100644 --- a/lisp/dashboard/dashboard.el +++ b/lisp/dashboard/dashboard.el @@ -62,6 +62,7 @@ (define-key map (kbd "C-i") #'widget-forward) (define-key map [backtab] #'widget-backward) (define-key map (kbd "RET") #'dashboard-return) + (define-key map (kbd "") #'widget-button-click) (define-key map [mouse-1] #'dashboard-mouse-1) (define-key map (kbd "}") #'dashboard-next-section) (define-key map (kbd "{") #'dashboard-previous-section) diff --git a/lisp/emacsql-sqlite/emacsql-sqlite-pkg.el b/lisp/emacsql-sqlite/emacsql-sqlite-pkg.el index d44da01e..2a7eefdb 100644 --- a/lisp/emacsql-sqlite/emacsql-sqlite-pkg.el +++ b/lisp/emacsql-sqlite/emacsql-sqlite-pkg.el @@ -1,4 +1,4 @@ -(define-package "emacsql-sqlite" "20250223.1743" "Code used by multiple SQLite back-ends" 'nil :commit "e4f1dcae91f91c5fa6dc1b0097a6c524e98fdf2b" :authors +(define-package "emacsql-sqlite" "20250301.1637" "Code used by multiple SQLite back-ends" 'nil :commit "f111b0acc79eadeeb3c6c1332d943f11fd6932ff" :authors '(("Jonas Bernoulli" . "emacs.emacsql@jonas.bernoulli.dev")) :maintainers '(("Jonas Bernoulli" . "emacs.emacsql@jonas.bernoulli.dev")) diff --git a/lisp/emacsql/emacsql-pkg.el b/lisp/emacsql/emacsql-pkg.el index 4bbf29fc..d084c5e0 100644 --- a/lisp/emacsql/emacsql-pkg.el +++ b/lisp/emacsql/emacsql-pkg.el @@ -1,6 +1,6 @@ -(define-package "emacsql" "20250223.1743" "High-level SQL database front-end" +(define-package "emacsql" "20250301.1637" "High-level SQL database front-end" '((emacs "26.1")) - :commit "e4f1dcae91f91c5fa6dc1b0097a6c524e98fdf2b" :authors + :commit "f111b0acc79eadeeb3c6c1332d943f11fd6932ff" :authors '(("Christopher Wellons" . "wellons@nullprogram.com")) :maintainers '(("Jonas Bernoulli" . "emacs.emacsql@jonas.bernoulli.dev")) diff --git a/lisp/emacsql/emacsql.el b/lisp/emacsql/emacsql.el index d345d177..1b299ea2 100644 --- a/lisp/emacsql/emacsql.el +++ b/lisp/emacsql/emacsql.el @@ -6,7 +6,7 @@ ;; Maintainer: Jonas Bernoulli ;; Homepage: https://github.com/magit/emacsql -;; Package-Version: 4.1.0 +;; Package-Version: 4.2.0 ;; Package-Requires: ((emacs "26.1")) ;; SPDX-License-Identifier: Unlicense @@ -32,7 +32,7 @@ "The EmacSQL SQL database front-end." :group 'comm) -(defconst emacsql-version "4.1.0") +(defconst emacsql-version "4.2.0") (defvar emacsql-global-timeout 30 "Maximum number of seconds to wait before bailing out on a SQL command. diff --git a/lisp/ess/ess.info b/lisp/ess/ess.info index d528d46f..b17a2d86 100644 --- a/lisp/ess/ess.info +++ b/lisp/ess/ess.info @@ -1,4 +1,4 @@ -This is ess.info, produced by makeinfo version 6.8 from ess.texi. +This is ess.info, produced by makeinfo version 7.1.1 from ess.texi. INFO-DIR-SECTION Emacs START-INFO-DIR-ENTRY @@ -89,16 +89,16 @@ Emacsen, current versions only support GNU Emacs. There are two main ways of interacting with ESS: through "regular" modes or "inferior" modes. Regular modes act like normal Emacs major modes. ESS major modes are displayed in the mode-line in the format -'ESS[dialect]', where 'dialect' can take values such as 'R', 'SAS', or -'S'. +‘ESS[dialect]’, where ‘dialect’ can take values such as ‘R’, ‘SAS’, or +‘S’. ESS also provides easy access to an "inferior process," which is an Emacs buffer associated with a running process. This can be an R session, for example. These inferior processes are referred to as -inferior ESS ('iESS'), and are shown in the modeline by 'iESS -[dialect]'. +inferior ESS (‘iESS’), and are shown in the modeline by ‘iESS +[dialect]’. - Currently, the documentation contains many references to ''R'' where + Currently, the documentation contains many references to ‘'R'’ where actually any supported (statistics) language is meant, i.e., 'R' could also mean 'S' or 'SAS.' @@ -160,52 +160,52 @@ File: ess.info, Node: Current Features, Up: Features 1.1.1 Features Overview ----------------------- - * Languages Supported: - * S family (R, S, and S+ AKA S-PLUS) - * SAS - * BUGS/JAGS - * Stata - * Julia - * Editing source code (S family, SAS, BUGS/JAGS, Stata, Julia) - * Syntactic indentation and highlighting of source code - * Partial evaluation of code - * Loading and error-checking of code - * Source code revision maintenance - * Batch execution (SAS, BUGS/JAGS) - * Use of imenu to provide links to appropriate functions - * Interacting with the process (S family, SAS, Stata, Julia) - * Command-line editing - * Searchable Command history - * Command-line completion of S family object names and file + • Languages Supported: + • S family (R, S, and S+ AKA S-PLUS) + • SAS + • BUGS/JAGS + • Stata + • Julia + • Editing source code (S family, SAS, BUGS/JAGS, Stata, Julia) + • Syntactic indentation and highlighting of source code + • Partial evaluation of code + • Loading and error-checking of code + • Source code revision maintenance + • Batch execution (SAS, BUGS/JAGS) + • Use of imenu to provide links to appropriate functions + • Interacting with the process (S family, SAS, Stata, Julia) + • Command-line editing + • Searchable Command history + • Command-line completion of S family object names and file names - * Quick access to object lists and search lists - * Transcript recording - * Interface to the help system - * Transcript manipulation (S family, Stata) - * Recording and saving transcript files - * Manipulating and editing saved transcripts - * Re-evaluating commands from transcript files - * Interaction with Help Pages and other Documentation (R) - * Fast Navigation - * Sending Examples to running ESS process. - * Fast Transfer to Further Help Pages - * Help File Editing (R) - * Syntactic indentation and highlighting of source code. - * Sending Examples to running ESS process. - * Previewing + • Quick access to object lists and search lists + • Transcript recording + • Interface to the help system + • Transcript manipulation (S family, Stata) + • Recording and saving transcript files + • Manipulating and editing saved transcripts + • Re-evaluating commands from transcript files + • Interaction with Help Pages and other Documentation (R) + • Fast Navigation + • Sending Examples to running ESS process. + • Fast Transfer to Further Help Pages + • Help File Editing (R) + • Syntactic indentation and highlighting of source code. + • Sending Examples to running ESS process. + • Previewing For source code buffers, ESS offers several features: - * Support for multiple indentation styles R code *Note Indenting::. + • Support for multiple indentation styles R code *Note Indenting::. - * Facilities for loading and error-checking source files, including a + • Facilities for loading and error-checking source files, including a keystroke to jump straight to the position of an error in a source file. *Note Error Checking::. - * Source code revision maintenance, which allows you to keep historic + • Source code revision maintenance, which allows you to keep historic versions of R source files. *Note Source Files::. - * Facilities for evaluating R code such as portions of source files, + • Facilities for evaluating R code such as portions of source files, or line-by-line evaluation of files (useful for debugging). *Note Evaluating code::. @@ -214,25 +214,25 @@ inferior ESS (iESS) process (a connection between your buffer and the statistical package which is waiting for you to input commands). These include: - * Command-line editing for fixing mistakes in commands before they + • Command-line editing for fixing mistakes in commands before they are entered. *Note Command-line editing::. - * Searchable command history for recalling previously-submitted + • Searchable command history for recalling previously-submitted commands. *Note Command History::. - * Command-line completion of both object and file names for quick + • Command-line completion of both object and file names for quick entry. *Note Completion::. - * Hot-keys for quick entry of commonly-used commands in 'R' such as - 'objects()', and 'search()'. *Note Hot keys::. + • Hot-keys for quick entry of commonly-used commands in 'R' such as + ‘objects()’, and ‘search()’. *Note Hot keys::. - * Transcript recording for a complete record of all the actions in an + • Transcript recording for a complete record of all the actions in an R session. *Note Transcript::. - * Interface to the help system, with a specialized mode for viewing R + • Interface to the help system, with a specialized mode for viewing R help files. *Note Help::. - * Object editing. ESS allows you to edit more than one function + • Object editing. ESS allows you to edit more than one function simultaneously in dedicated Emacs buffers. The ESS process may continue to be used while functions are being edited. *Note Edit buffer::. @@ -240,7 +240,7 @@ include: Finally, ESS provides features for re-submitting commands from saved transcript files, including: - * Evaluation of previously entered commands, stripping away + • Evaluation of previously entered commands, stripping away unnecessary prompts. *Note Transcript resubmit::.  @@ -251,90 +251,90 @@ File: ess.info, Node: New features, Next: Credits, Prev: Features, Up: Intro Changes and New Features in 25.01.0: - * polymode: In our transition from literate libraries (such as noweb + • polymode: In our transition from literate libraries (such as noweb documented below with respect to 19.04), we now recommend the polymode packages as a more suitable replacement. Furthermore, we suggest the related polymodes including poly-noweb, poly-markdown and poly-R (installed in that order). The package polymode itself, as well as the polymodes packages, are all on MELPA rather than ELPA. Therefore, you need to add MELPA to the list of installation - archives as follows. '(add-to-list 'package-archives - '("melpa-stable" . "https://stable.melpa.org/packages/"))' for 'M-x - package-install' + archives as follows. ‘(add-to-list 'package-archives + '("melpa-stable" . "https://stable.melpa.org/packages/"))’ for ‘M-x + package-install’ - * ESS[R]: The shorthand notation for lambda functions and the + • ESS[R]: The shorthand notation for lambda functions and the question mark are now fontified as keywords. Contributed by Maxime Pettinger. - * ESS[SAS]: Developed new comprehensive lists of PROCs and functions - for syntax highlighting. See 'etc/proc.sas' and 'etc/func.sas'. + • ESS[SAS]: Developed new comprehensive lists of PROCs and functions + for syntax highlighting. See ‘etc/proc.sas’ and ‘etc/func.sas’. Changes and New Features in 24.01.1: - * Revert a bug introduced with the 'ess-request-a-process' change + • Revert a bug introduced with the ‘ess-request-a-process’ change Changes and New Features in 24.01.0: - * fix docstring warnings in ess-custom + • fix docstring warnings in ess-custom - * :package-version is now set to "VERSION" in ess-custom. By make + • :package-version is now set to "VERSION" in ess-custom. By make this is replaced with "24.01.0" (or similar). - * Better "collaboration" with org-mode. Now 'ess-request-a-process' - obeys 'ess-gen-proc-buffer-name-function', thanks to Ihor + • Better "collaboration" with org-mode. Now ‘ess-request-a-process’ + obeys ‘ess-gen-proc-buffer-name-function’, thanks to Ihor Radchenko. Changes and New Features in 19.04 (unreleased): - * ESS[R]: When a background command is interrupted with C-g, ESS now + • ESS[R]: When a background command is interrupted with C-g, ESS now asks the user if they want to disable background evaluations altogether. This is a resiliency measure against cases where background evals cause cascading errors or hangs. - * ESS[R]: Background commands now propagate errors to Emacs. + • ESS[R]: Background commands now propagate errors to Emacs. - * ESS[R]: Background commands can now be disabled by process instad + • ESS[R]: Background commands can now be disabled by process instad of globally. For instance when a process has failed to initialize properly, background evals are disabled for that particular process to avoid cascading errors. Other processes may still use background commands. - * ESS[R]: ESSR commands are now more robust when ESSR is not in - scope. This can happen when using 'browser()' in an environment + • ESS[R]: ESSR commands are now more robust when ESSR is not in + scope. This can happen when using ‘browser()’ in an environment that doesn't inherit from the search path. - * ESS[R]: Unexpected exits are now detected during startup. In that + • ESS[R]: Unexpected exits are now detected during startup. In that case an error is thrown with advice about how to recover. - * ESS[R]: 'options(width = )' is now set on startup based on the + • ESS[R]: ‘options(width = )’ is now set on startup based on the width of the inferior window. - * ESS[R]: Add support for R projects and start R by default in the + • ESS[R]: Add support for R projects and start R by default in the project folder. - * ESS[R]: Backticked symbols in the process buffer are no longer + • ESS[R]: Backticked symbols in the process buffer are no longer fontified as strings. - * ESS[R]: 'ess-command' now runs R code in a sandboxed environment. - Use '.ess.environment()' to inspect the current environment. + • ESS[R]: ‘ess-command’ now runs R code in a sandboxed environment. + Use ‘.ess.environment()’ to inspect the current environment. - * ESS[R]: Added support for new syntax in R 4.0 and R 4.1. This + • ESS[R]: Added support for new syntax in R 4.0 and R 4.1. This concerns raw strings, lambda functions, and the pipe operator. - * ESS[R]: Highlight error locations in rlang style backtraces + • ESS[R]: Highlight error locations in rlang style backtraces - * ESS[R]: Fixed issue that caused ESS-help to hang when usage blocks + • ESS[R]: Fixed issue that caused ESS-help to hang when usage blocks include R comments (#1025). Fix contributed by Bill Evans. - * ESS: New 'ess-elisp-trace-mode' minor mode. Toggle it to start or - stop tracing all 'ess'-prefixed functions with 'trace-function'. + • ESS: New ‘ess-elisp-trace-mode’ minor mode. Toggle it to start or + stop tracing all ‘ess’-prefixed functions with ‘trace-function’. Tracing is useful for debugging background ESS behaviour. - * ESS[R]: 'ess-get-help-aliases-list' now caches the aliases on the R + • ESS[R]: ‘ess-get-help-aliases-list’ now caches the aliases on the R side. This should speed up help lookup when the search path has changed and the aliases are read again. - * ESS: 'ess-command' now uses a default timeout of 30 seconds. It + • ESS: ‘ess-command’ now uses a default timeout of 30 seconds. It should normally be avoided with long-running tasks because it causes Emacs to block while the command is running. If the timeout is reached, an error is thrown. An interrupt is also sent to the @@ -342,129 +342,129 @@ Changes and New Features in 25.01.0: This is a behaviour change: you will now have to explicitly opt in blocking the whole Emacs UI for more than 30 seconds by supplying a - larger timeout (use 'most-positive-fixnum' for infinity). + larger timeout (use ‘most-positive-fixnum’ for infinity). - * ESS: 'ess-wait-for-process' now returns nil if a timeout is + • ESS: ‘ess-wait-for-process’ now returns nil if a timeout is reached. - * ESS: 'ess-get-words-from-vector' gains a 'timeout' argument. + • ESS: ‘ess-get-words-from-vector’ gains a ‘timeout’ argument. - * ESS[R]: Fixed performance issue with argument completions. The + • ESS[R]: Fixed performance issue with argument completions. The help summary for the argument is no longer displayed in the echo area. This fixes delays and hangs (#1062). - * ESS[R]: 'ess-command' is now more robust and resilient to hangs and - custom prompts (#1043). It also strips continuation prompts ('+' + • ESS[R]: ‘ess-command’ is now more robust and resilient to hangs and + custom prompts (#1043). It also strips continuation prompts (‘+’ prompts) automatically and reliably (#1116). - * ESS[R]: 'ess-command' now handles sinked consoles correctly. + • ESS[R]: ‘ess-command’ now handles sinked consoles correctly. - * ESS[R]: 'ess-command' no longer changes '.Last.value'. As a + • ESS[R]: ‘ess-command’ no longer changes ‘.Last.value’. As a result, background tasks like completions no longer affect the last value binding (#1058). - * ESS[R]: Namespaced evaluation is disable in roxygen examples + • ESS[R]: Namespaced evaluation is disable in roxygen examples (#1026). Part of this change is that namespaced evaluation has become a buffer-local rather than process-local setting (#1046). This makes it possible to disable namespaced evaluation in specific buffers or contexts. - * iESS: Inferior processes can now properly reuse frames (#987). + • iESS: Inferior processes can now properly reuse frames (#987). Fixed issue that caused the current buffer to be incorrectly - displayed in the new frame when 'display-buffer' is set to pop up + displayed in the new frame when ‘display-buffer’ is set to pop up frames. - * ESS[R]: Better support for tramp. Fixed package evaluation on + • ESS[R]: Better support for tramp. Fixed package evaluation on remote servers with Tramp (#950); process reloading (#1001); and an evaluation issue (#1024). These fixes were contributed by David Pritchard. - * ESS[R]: Automatic offsetting of R process output is now disabled by + • ESS[R]: Automatic offsetting of R process output is now disabled by default because it produces undesirable output in some situations. - To re-enable, set 'inferior-ess-fix-misaligned-output' to t. + To re-enable, set ‘inferior-ess-fix-misaligned-output’ to t. - * ESS[R]: Improved 'xref' lookup ('M-.'). Function locations are now + • ESS[R]: Improved ‘xref’ lookup (‘M-.’). Function locations are now always detected for package libraries listed in - 'ess-r-package-library-paths'. + ‘ess-r-package-library-paths’. - * ESS[R]: Evaluated lines starting with the Roxygen prefix are now + • ESS[R]: Evaluated lines starting with the Roxygen prefix are now always stripped from the prefix, so they can be sent to the process - easily. Previously, this was only the case inside the 'examples' + easily. Previously, this was only the case inside the ‘examples’ field. Since roxygen is switching to R markdown, it becomes useful to evaluate chunks of R outside examples. - * stata support is now obsolete since we were unable to elicit FSF + • stata support is now obsolete since we were unable to elicit FSF paperwork from some of the original authors: see the lisp/obsolete sub-directory on the ESS github repo - * 'ess-set-working-directory' no longer changes the active directory - (as defined by the buffer-local variable 'default-directory') of + • ‘ess-set-working-directory’ no longer changes the active directory + (as defined by the buffer-local variable ‘default-directory’) of the buffer where the command is called. Instead, the active directory of the inferior buffer is updated to the new working directory. - * The default of ess-eval-visibly is now ''nowait'. With this change + • The default of ess-eval-visibly is now ‘'nowait’. With this change you should no longer experience freezes while evaluating code. - * ESS[R]: There is a new menu entry for reloading the R process. It - is otherwise bound to 'C-c C-e C-r'. Reloading now reuses the same + • ESS[R]: There is a new menu entry for reloading the R process. It + is otherwise bound to ‘C-c C-e C-r’. Reloading now reuses the same process name and start arguments that were used to start the process. - * iESS: Process runners now return the inferior buffer. Note that + • iESS: Process runners now return the inferior buffer. Note that callers of inferior runners should not assume that the current buffer has been set to the inferior buffer. Instead, use - 'with-current-buffer' with the return value of the inferior. + ‘with-current-buffer’ with the return value of the inferior. - * iESS[SAS]: The SAS keymap was only set in iESS buffers called + • iESS[SAS]: The SAS keymap was only set in iESS buffers called '*SAS*'. This is now fixed. - * ESS[R]: Fixed longstanding indentation issues involving '::' and - ':::' operators. + • ESS[R]: Fixed longstanding indentation issues involving ‘::’ and + ‘:::’ operators. - * Implement a more reliable check for the process busy state. + • Implement a more reliable check for the process busy state. Background actions such as completion and directory synchronization should not block the process and should not cause printing of the extraneous output to the interpreter. - * Activate 'goto-address-mode' for url and email highlighting in + • Activate ‘goto-address-mode’ for url and email highlighting in inferior buffers. - * 'smart-underscore' and 'ess-smart-S-assign-key' have been removed. + • ‘smart-underscore’ and ‘ess-smart-S-assign-key’ have been removed. Users who liked the previous behavior (i.e. underscore inserting - "<-") should bind 'ess-insert-assign' to the underscore in their - Emacs initialization file. For example, '(define-key - ess-r-mode-map "_" #'ess-insert-assign)' and '(define-key - inferior-ess-r-mode-map "_" #'ess-insert-assign)' will activate it + "<-") should bind ‘ess-insert-assign’ to the underscore in their + Emacs initialization file. For example, ‘(define-key + ess-r-mode-map "_" #'ess-insert-assign)’ and ‘(define-key + inferior-ess-r-mode-map "_" #'ess-insert-assign)’ will activate it in all ESS R buffers. - * ESS major modes are now defined using 'define-derived-mode'. This + • ESS major modes are now defined using 'define-derived-mode'. This makes ESS major modes respect modern conventions such as having -mode-hook and -mode-map. Users are encouraged to place customizations under the appropriate mode. - * New option ess-auto-width controls setting the width option on + • New option ess-auto-width controls setting the width option on window changes. Users can change it to 'frame, 'window, or an integer. See the documentation for details. - 'ess-auto-width-visible' controls visibility. + ‘ess-auto-width-visible’ controls visibility. - * ESS now respects 'display-buffer-alist'. Users can now use - 'display-buffer-alist' to manage how and where windows appear. For + • ESS now respects ‘display-buffer-alist’. Users can now use + ‘display-buffer-alist’ to manage how and where windows appear. For more information and examples, see *Note (ess)Controlling buffer display::. - * 'ess-roxy-mode' can now be enabled in non-R buffers. This is + • ‘ess-roxy-mode’ can now be enabled in non-R buffers. This is primarily intended to support roxygen documentation for cpp buffers. Preview functionality is not supported outside R buffers. - * ESS[R]: DESCRIPTION files now open in 'conf-colon-mode'. + • ESS[R]: DESCRIPTION files now open in ‘conf-colon-mode’. - * 'ess-style' now has effects when set as a file or directory local + • ‘ess-style’ now has effects when set as a file or directory local variable. - * 'ess-default-style' is now obsolete, use 'ess-style' instead. + • ‘ess-default-style’ is now obsolete, use ‘ess-style’ instead. - * Options for 'ess-gen-proc-buffer-name-function' have been renamed. + • Options for 'ess-gen-proc-buffer-name-function' have been renamed. ess-gen-proc-buffer-name:projectile-or-simple was renamed to ess-gen-proc-buffer-name:project-or-simple and ess-gen-proc-buffer-name:projectile-or-directory was renamed to @@ -472,89 +472,89 @@ Changes and New Features in 25.01.0: suggests, these now rely on project.el (included with Emacs) rather than projectile.el, which is a third-party package. - * Eldoc fully honors 'eldoc-echo-area-use-multiline-p' + • Eldoc fully honors ‘eldoc-echo-area-use-multiline-p’ - * ESS[R]: 'ess-r-rhub-check-package' gained new 'RECOMMENDED'. + • ESS[R]: ‘ess-r-rhub-check-package’ gained new ‘RECOMMENDED’. - * ESS[R]: devtools commands ask about saving modified buffers before + • ESS[R]: devtools commands ask about saving modified buffers before running. Users can disable the questioning with - 'ess-save-silently'. + ‘ess-save-silently’. - * ESS[R] help pages now provide links to other help topics. This is + • ESS[R] help pages now provide links to other help topics. This is similar with what you would see with, for example - 'options(help_type = ``html'')' but works with the plain-text - version as well. This only works with 'options(useFancyQuotes = - TRUE)' (the default). + ‘options(help_type = ``html'')’ but works with the plain-text + version as well. This only works with ‘options(useFancyQuotes = + TRUE)’ (the default). - * 'ess-rdired' buffers now derive from tabulated-list-mode. They + • ‘ess-rdired’ buffers now derive from tabulated-list-mode. They should look better and be a bit faster overall. The size column now displays object sizes in bytes. - * 'ess-rdired' buffers now auto-update. The frequency is governed by - the new option 'ess-rdired-auto-update-interval'. + • ‘ess-rdired’ buffers now auto-update. The frequency is governed by + the new option ‘ess-rdired-auto-update-interval’. - * ESS[R]: 'electric-layout-mode' is now supported. This + • ESS[R]: ‘electric-layout-mode’ is now supported. This automatically inserts a newline after an opening curly brace in R - buffers. To enable it, customize 'ess-r-mode-hook'. + buffers. To enable it, customize ‘ess-r-mode-hook’. - * ESS[R]: imenu now supports assignment with the equals sign. + • ESS[R]: imenu now supports assignment with the equals sign. - * ESS[Rd]: Rd no longer writes abbrevs to user's abbrev file. + • ESS[Rd]: Rd no longer writes abbrevs to user's abbrev file. - * ESS removed support for many unused languages. This includes old + • ESS removed support for many unused languages. This includes old versions of S+, ARC, OMG, VST, and XLS. - * ess-r-runner-prefixes was modified to find R-4 and later. + • ess-r-runner-prefixes was modified to find R-4 and later. - * ESS no longer activates eldoc if the user has disabled + • ESS no longer activates eldoc if the user has disabled global-eldoc-mode. The following have been made obsolete or removed, see their documentation for more detail: - * Libraries for literate data analysis are obsolete and not loaded by - default. This includes 'ess-noweb', 'ess-swv', and related - functionality like 'Rnw-mode'. Users are encouraged to switch to + • Libraries for literate data analysis are obsolete and not loaded by + default. This includes ‘ess-noweb’, ‘ess-swv’, and related + functionality like ‘Rnw-mode’. Users are encouraged to switch to one of several other packages that deal with these modes. For example, polymode , , or markdown-mode with edit-indirect . - * Support for 'auto-complete' is obsolete. The 'auto-complete' + • Support for ‘auto-complete’ is obsolete. The ‘auto-complete’ package is unmaintained and so ESS support is now obsolete. Users - are encouraged to switch to 'company-mode' instead. + are encouraged to switch to ‘company-mode’ instead. - * User options for controlling display of buffers. This includes - 'ess-show-buffer-action', 'inferior-ess-same-window', - 'inferior-ess-own-frame', and 'inferior-ess-frame-alist'. See - above about ESS respecting 'display-buffer-alist'. + • User options for controlling display of buffers. This includes + ‘ess-show-buffer-action’, ‘inferior-ess-same-window’, + ‘inferior-ess-own-frame’, and ‘inferior-ess-frame-alist’. See + above about ESS respecting ‘display-buffer-alist’. - * Variables 'ess-tab-always-indent' and 'ess-tab-complete-in-script'. - Use the Emacs-wide setting of 'tab-always-indent' instead. + • Variables ‘ess-tab-always-indent’ and ‘ess-tab-complete-in-script’. + Use the Emacs-wide setting of ‘tab-always-indent’ instead. - * 'inferior-ess-*-start-file' variables. All modes except Stata did + • ‘inferior-ess-*-start-file’ variables. All modes except Stata did not respect customization of this variable. In order to load a file on startup, you should put a function on - 'ess-*-post-run-hook'. + ‘ess-*-post-run-hook’. Bug Fixes in 18.10.3: - * More 'Makefile' fixes, notably installing '*.el's. + • More ‘Makefile’ fixes, notably installing ‘*.el’s. Bug Fixes in 18.10.2: - * ESS[R] Fix namespace evaluation in non-installed packages. + • ESS[R] Fix namespace evaluation in non-installed packages. Evaluation is directed into GlobalEnv as originally intended. - * 'Makefile' fixes, notably for 'make install' and including full + • ‘Makefile’ fixes, notably for ‘make install’ and including full docs in the tarballs. Bug Fixes in 18.10.1: - * New functions 'ess-eval-line-visibly-and-step' ('C-c C-n' and - 'ess-eval-region-or-line-visibly-and-step' ('C-RET') which behave - as the old versions of 'ess-eval-line-and-step' and - 'ess-eval-region-or-line-and-step'. + • New functions ‘ess-eval-line-visibly-and-step’ (‘C-c C-n’ and + ‘ess-eval-region-or-line-visibly-and-step’ (‘C-RET’) which behave + as the old versions of ‘ess-eval-line-and-step’ and + ‘ess-eval-region-or-line-and-step’. Changes and New Features in 18.10: - * This is the last release to support Emacs older than 25.1. Going + • This is the last release to support Emacs older than 25.1. Going forward, only GNU Emacs 25.1 and newer will be supported. Soon after this release, support for older Emacs versions will be dropped from the git master branch. Note that MELPA uses the git @@ -562,176 +562,176 @@ documentation for more detail: 25.1 from MELPA and are unable to upgrade, you should switch to MELPA-stable. - * ESS now displays the language dialect in the mode-line. So, for + • ESS now displays the language dialect in the mode-line. So, for example, R buffers will now show ESS[R] rather than ESS[S]. - * The ESS manual has been updated and revised. + • The ESS manual has been updated and revised. - * The ESS initialization process has been further streamlined. If - you update the autoloads (which installation from 'package-install' - does), you should not need to '(require 'ess-site)' at all, as + • The ESS initialization process has been further streamlined. If + you update the autoloads (which installation from ‘package-install’ + does), you should not need to ‘(require 'ess-site)’ at all, as autoloads should automatically load ESS when it is needed (e.g. the first time an R buffer is opened). In order to defer loading your ESS config, you may want to do something like - '(with-require-after-load "ess" )' in your Emacs - init file. Users of the popular 'use-package' Emacs package can - now do '(use-package ess :defer t)' to take advantage of this + ‘(with-require-after-load "ess" )’ in your Emacs + init file. Users of the popular ‘use-package’ Emacs package can + now do ‘(use-package ess :defer t)’ to take advantage of this behavior. For more information on this feature, see *Note (ess)Activating and Loading ESS::. - * ESS now respects Emacs conventions for keybindings. This means - that The 'C-c [letter]' bindings have been removed. This affects - 'C-c h', which was bound to 'ess-eval-line-and-step-invisibly' in - 'sas-mode-local-map'; 'C-c f', which was bound to - 'ess-insert-function-outline' in 'ess-add-MM-keys'; and 'C-c h', - which was bound to 'ess-handy-commands' in 'Rd-mode-map', - 'ess-noweb-minor-mode-map', and 'ess-help-mode-map' + • ESS now respects Emacs conventions for keybindings. This means + that The ‘C-c [letter]’ bindings have been removed. This affects + ‘C-c h’, which was bound to ‘ess-eval-line-and-step-invisibly’ in + ‘sas-mode-local-map’; ‘C-c f’, which was bound to + ‘ess-insert-function-outline’ in ‘ess-add-MM-keys’; and ‘C-c h’, + which was bound to ‘ess-handy-commands’ in ‘Rd-mode-map’, + ‘ess-noweb-minor-mode-map’, and ‘ess-help-mode-map’ - * Functions 'ess-eval-line-and-step' and - 'ess-eval-region-or-line-and-step' now behave consistently with + • Functions ‘ess-eval-line-and-step’ and + ‘ess-eval-region-or-line-and-step’ now behave consistently with other evaluation function inside a package. - * ESS[R]: 'ess-r-package-use-dir' now works with any mode. This sets + • ESS[R]: ‘ess-r-package-use-dir’ now works with any mode. This sets the working directory to the root of the current package including - for example C or C++ files within '/src'). + for example C or C++ files within ‘/src’). - * ESS[R]: Long + + prompts in the inferior no longer offset output. + • ESS[R]: Long + + prompts in the inferior no longer offset output. - * ESS[R]: New option 'strip' for 'inferior-ess-replace-long+'. This + • ESS[R]: New option ‘strip’ for ‘inferior-ess-replace-long+’. This strips the entire + + sequence. - * ESS modes now inherit from 'prog-mode'. In the next release, ESS - modes will use 'define-derived-mode' so that each mode will have + • ESS modes now inherit from ‘prog-mode’. In the next release, ESS + modes will use ‘define-derived-mode’ so that each mode will have (for example) its own hooks and keymaps. - * ESS[R]: Supports flymake in R buffers for Emacs 26 and newer. - Users need to install the 'lintr' package to use it. Customizable - options include 'ess-use-flymake', 'ess-r-flymake-linters', and - 'ess-r-flymake-lintr-cache'. + • ESS[R]: Supports flymake in R buffers for Emacs 26 and newer. + Users need to install the ‘lintr’ package to use it. Customizable + options include ‘ess-use-flymake’, ‘ess-r-flymake-linters’, and + ‘ess-r-flymake-lintr-cache’. - * ESS[R]: Gained support for xref in Emacs 25+ *Note (emacs)Xref::. + • ESS[R]: Gained support for xref in Emacs 25+ *Note (emacs)Xref::. - * ESS[R]: The startup screen is cleaner. It also displays the - startup directory with an explicit 'setwd()'. + • ESS[R]: The startup screen is cleaner. It also displays the + startup directory with an explicit ‘setwd()’. - * ESS[R]: Changing the working directory is now always reflected in + • ESS[R]: Changing the working directory is now always reflected in the process buffer. - * ESS[R]: 'Makevars' files open with 'makefile-mode'. + • ESS[R]: ‘Makevars’ files open with ‘makefile-mode’. - * New variable 'ess-write-to-dribble'. This allows users to disable - the dribble ('*ESS*') buffer if they wish. + • New variable ‘ess-write-to-dribble’. This allows users to disable + the dribble (‘*ESS*’) buffer if they wish. - * All of the '*-program-name' variables have been renamed to - '*-program'. Users who previously customized e.g. - 'inferior-ess-R-program-name' will need to update their - customization to 'inferior-ess-R-program'. These variables are + • All of the ‘*-program-name’ variables have been renamed to + ‘*-program’. Users who previously customized e.g. + ‘inferior-ess-R-program-name’ will need to update their + customization to ‘inferior-ess-R-program’. These variables are treated as risky variables. - * 'ess-smart-S-assign' was renamed to 'ess-insert-assign'. It + • ‘ess-smart-S-assign’ was renamed to ‘ess-insert-assign’. It provides similar functionality but for any keybinding, not just '_'. For instance if you bind it to ';', repeated invocations cycle through between assignment and inserting ';'. - * 'C-c C-=' is now bound to 'ess-cycle-assign' by default. See the + • ‘C-c C-=’ is now bound to ‘ess-cycle-assign’ by default. See the documentation for details. New user customization option - 'ess-assign-list' controls which assignment operators are cycled. + ‘ess-assign-list’ controls which assignment operators are cycled. - * ESS[R] In remote sessions, the ESSR package is now fetched from + • ESS[R] In remote sessions, the ESSR package is now fetched from GitHub. - * Commands that send the region to the inferior process now deal with - rectangular regions. See the documentation of 'ess-eval-region' + • Commands that send the region to the inferior process now deal with + rectangular regions. See the documentation of ‘ess-eval-region’ for details. This only works on Emacs 25.1 and newer. - * ESS[R]: Improvements to interacting with iESS in non-R files. + • ESS[R]: Improvements to interacting with iESS in non-R files. Interaction with inferior process in non-R files within packages (for instance C or C++ files) has been improved. This is a work in progress. - * ESS[R]: Changing the working directory is now always reflected in + • ESS[R]: Changing the working directory is now always reflected in the process buffer. - * ESS[JAGS]: *.jog and *.jmd files no longer automatically open in + • ESS[JAGS]: *.jog and *.jmd files no longer automatically open in JAGS mode. Many improvements to fontification: - * Improved customization for faces. ESS now provides custom faces + • Improved customization for faces. ESS now provides custom faces for (nearly) all faces used and places face customization options - into their own group. Users can customize these options using 'M-x - customize-group RET ess-faces'. + into their own group. Users can customize these options using ‘M-x + customize-group RET ess-faces’. - * Many new keywords were added to 'ess-R-keywords' and - 'ess-R-modifiers'. See the documentation for details. + • Many new keywords were added to ‘ess-R-keywords’ and + ‘ess-R-modifiers’. See the documentation for details. - * ESS[R]: 'in' is now only fontified when inside a 'for' construct. + • ESS[R]: ‘in’ is now only fontified when inside a ‘for’ construct. This avoids spurious fontification, especially in the output buffer where 'in' is a common English word. - * ESS: Font-lock keywords are now generated lazily. That means you - can now add or remove keywords from variables like 'ess-R-keywords' + • ESS: Font-lock keywords are now generated lazily. That means you + can now add or remove keywords from variables like ‘ess-R-keywords’ in your Emacs configuration file after loading ESS (i.e. in the - ':config' section for 'use-package' users). + ‘:config’ section for ‘use-package’ users). - * ESS[R]: Fontification of roxygen '@param' keywords now supports + • ESS[R]: Fontification of roxygen ‘@param’ keywords now supports comma-separated parameters. - * ESS[R]: Certain keywords are only fontified if followed by a - parenthesis. Function-like keywords such as 'if ()' or 'stop()' + • ESS[R]: Certain keywords are only fontified if followed by a + parenthesis. Function-like keywords such as ‘if ()’ or ‘stop()’ are no longer fontified as keyword if not followed by an opening parenthesis. The same holds for search path modifiers like - 'library()' or 'require()'. + ‘library()’ or ‘require()’. - * ESS[R]: Fixed fontification toggling. Especially certain syntactic - elements such as '%op%' operators and backquoted function + • ESS[R]: Fixed fontification toggling. Especially certain syntactic + elements such as ‘%op%’ operators and backquoted function definitions. - * ESS[R]: 'ess-font-lock-toggle-keyword' can be called interactively. + • ESS[R]: ‘ess-font-lock-toggle-keyword’ can be called interactively. This command asks with completion for a font-lock group to toggle. This functionality is equivalent to the font-lock menu. Notable bug fixes: - * 'prettify-symbols-mode' no longer breaks indentation. This is + • ‘prettify-symbols-mode’ no longer breaks indentation. This is accomplished by having the pretty symbols occupy the same number of characters as their non-pretty cousins. You may customize the new - variable 'ess-r-prettify-symbols' to control this behavior. + variable ‘ess-r-prettify-symbols’ to control this behavior. - * ESS: Inferior process buffers are now always displayed on startup. + • ESS: Inferior process buffers are now always displayed on startup. Additionally, they don't hang Emacs on failures. Obsolete libraries, functions, and variables: - * The 'ess-r-args.el' library has been obsoleted and will be removed - in the next release. Use 'eldoc-mode' instead, which is on by + • The ‘ess-r-args.el’ library has been obsoleted and will be removed + in the next release. Use ‘eldoc-mode’ instead, which is on by default. - * Functions and options dealing with the smart assign key are + • Functions and options dealing with the smart assign key are obsolete. The following functions have been made obsolete and will - be removed in the next release of ESS: 'ess-smart-S-assign', - 'ess-toggle-S-assign', 'ess-toggle-S-assign-key', - 'ess-disable-smart-S-assign'. + be removed in the next release of ESS: ‘ess-smart-S-assign’, + ‘ess-toggle-S-assign’, ‘ess-toggle-S-assign-key’, + ‘ess-disable-smart-S-assign’. - The variable 'ess-smart-S-assign-key' is now deprecated and will be + The variable ‘ess-smart-S-assign-key’ is now deprecated and will be removed in the next release. If you would like to continue using '_' for inserting assign in future releases, please bind - 'ess-insert-assign' in 'ess-mode-map' the normal way. + ‘ess-insert-assign’ in ‘ess-mode-map’ the normal way. - * ESS[S]: Variable 'ess-s-versions-list' is obsolete and ignored. - Use 'ess-s-versions' instead. You may pass arguments by starting + • ESS[S]: Variable ‘ess-s-versions-list’ is obsolete and ignored. + Use ‘ess-s-versions’ instead. You may pass arguments by starting the inferior process with the universal argument. Changes and New Features in 17.11: - * The ESS initialization process has been streamlined. You can now + • The ESS initialization process has been streamlined. You can now load the R and Stata modes independently from the rest of ESS. Just - put '(require 'ess-r-mode)' or '(require 'ess-stata-mode)' in your + put ‘(require 'ess-r-mode)’ or ‘(require 'ess-stata-mode)’ in your init file. This is for experienced Emacs users as this requires - setting up autoloads for '.R' files manually. We will keep - maintaining 'ess-site' for easy loading of all ESS features. + setting up autoloads for ‘.R’ files manually. We will keep + maintaining ‘ess-site’ for easy loading of all ESS features. - * Reloading and quitting the process is now more robust. If no + • Reloading and quitting the process is now more robust. If no process is attached, ESS now switches automatically to one (prompting you for selection if there are several running). Reloading and quitting will now work during a debug session or when @@ -739,88 +739,88 @@ documentation for more detail: the window configuration is saved and restored after reloading to prevent the buffer of the new process from capturing the cursor. - * ESS[R]: New command 'ess-r-package-use-dir'. It sets the working + • ESS[R]: New command ‘ess-r-package-use-dir’. It sets the working directory of the current process to the current package directory. - * ESS[R] Lookup for references in inferior buffers has been improved. - New variable 'ess-r-package-source-roots' contains package + • ESS[R] Lookup for references in inferior buffers has been improved. + New variable ‘ess-r-package-source-roots’ contains package sub-directories which are searched recursively during the file - lookup point. Directories in 'ess-tracebug-search-path' are now + lookup point. Directories in ‘ess-tracebug-search-path’ are now also searched recursively. - * ESS[R] Namespaced evaluation is now automatically enabled only in - the 'R/' directory. This way ESS will not attempt to update + • ESS[R] Namespaced evaluation is now automatically enabled only in + the ‘R/’ directory. This way ESS will not attempt to update function definitions from a package if you are working from e.g. a test file. Changes and New Features in 16.10: - * ESS[R]: Syntax highlighting is now more consistent. Backquoted + • ESS[R]: Syntax highlighting is now more consistent. Backquoted names are not fontified as strings (since they really are identifiers). Furthermore they are now correctly recognized when they are function definitions or function calls. - * ESS[R]: Backquoted names and '%op%' operators are recognized as - sexp. This is useful for code navigation, e.g. with 'C-M-f' and - 'C-M-b'. - * ESS[R]: Integration of outline mode with roxygen examples fields. + • ESS[R]: Backquoted names and ‘%op%’ operators are recognized as + sexp. This is useful for code navigation, e.g. with ‘C-M-f’ and + ‘C-M-b’. + • ESS[R]: Integration of outline mode with roxygen examples fields. You can use outline mode's code folding commands to fold the examples field. This is especially nice to use with well documented packages with long examples set. Set - 'ess-roxy-fold-examples' to non-nil to automatically fold the + ‘ess-roxy-fold-examples’ to non-nil to automatically fold the examples field when you open a buffer. - * ESS[R]: New experimental feature: syntax highlighting in roxygen + • ESS[R]: New experimental feature: syntax highlighting in roxygen examples fields. This is turned off by default. Set - 'ess-roxy-fontify-examples' to non-nil to try it out. - * ESS[R]: New package development command 'ess-r-devtools-ask' bound - to 'C-c C-w C-a'. It asks with completion for any devtools command - that takes 'pkg' as argument. - * ESS[R]: New command 'C-c C-e C-r' to reload the inferior process. + ‘ess-roxy-fontify-examples’ to non-nil to try it out. + • ESS[R]: New package development command ‘ess-r-devtools-ask’ bound + to ‘C-c C-w C-a’. It asks with completion for any devtools command + that takes ‘pkg’ as argument. + • ESS[R]: New command ‘C-c C-e C-r’ to reload the inferior process. Currently only implemented for R. The R method runs - 'inferior-ess-r-reload-hook' on reloading. - * ESS[R]: 'ess-r-package-mode' is now activated in non-file buffers + ‘inferior-ess-r-reload-hook’ on reloading. + • ESS[R]: ‘ess-r-package-mode’ is now activated in non-file buffers as well. Bug fixes in 16.10: - * ESS[R]: Fix broken (un)flagging for debugging inside packages - * ESS[R]: Fixes (and improvements) in Package development - * ESS[R]: Completion no longer produces '...=' inside 'list( )'. - * ESS[R]: Better debugging and tracing in packages. - * ESS[R]: Better detection of symbols at point. - * ESS[R]: No more spurious warnings on deletion of temporary files. - * ESS[julia]: help and completion work (better) - * ESS[julia]: available via 'ess-remote' + • ESS[R]: Fix broken (un)flagging for debugging inside packages + • ESS[R]: Fixes (and improvements) in Package development + • ESS[R]: Completion no longer produces ‘...=’ inside ‘list( )’. + • ESS[R]: Better debugging and tracing in packages. + • ESS[R]: Better detection of symbols at point. + • ESS[R]: No more spurious warnings on deletion of temporary files. + • ESS[julia]: help and completion work (better) + • ESS[julia]: available via ‘ess-remote’ Changes and New Features in 16.04: - * ESS[R]: 'developer' functionality has been refactored. The new + • ESS[R]: ‘developer’ functionality has been refactored. The new user interface consists of a single command - 'ess-r-set-evaluation-env' bound by default to 'C-c C-t C-s'. Once + ‘ess-r-set-evaluation-env’ bound by default to ‘C-c C-t C-s’. Once an evaluation environment has been set with, all subsequent ESS evaluation will source the code into that environment. By default, for file within R packages the evaluation environment is set to the - package environment. Set 'ess-r-package-auto-set-evaluation-env' - to 'nil' to disable this. - * ESS[R]: New 'ess-r-package-mode' This development mode provides + package environment. Set ‘ess-r-package-auto-set-evaluation-env’ + to ‘nil’ to disable this. + • ESS[R]: New ‘ess-r-package-mode’ This development mode provides features to make package development easier. Currently, most of - the commands are based on the 'devtools' packages and are - accessible with 'C-c C-w' prefix. See the documentation of - 'ess-r-package-mode' function for all available commands. With - 'C-u' prefix each command asks for extra arguments to the + the commands are based on the ‘devtools’ packages and are + accessible with ‘C-c C-w’ prefix. See the documentation of + ‘ess-r-package-mode’ function for all available commands. With + ‘C-u’ prefix each command asks for extra arguments to the underlying devtools function. This mode is automatically enabled - in all files within R packages and is indicated with '[pkg:NAME]' + in all files within R packages and is indicated with ‘[pkg:NAME]’ in the mode-line. - * ESS[R]: Help lookup has been improved. It is now possible to get + • ESS[R]: Help lookup has been improved. It is now possible to get help for namespaced objects such as pkg::foobar. Furthermore, ESS - recognizes more reliably when you change 'options('html_type')'. - * ESS[R]: New specialized breakpoints for debugging magrittr pipes - * ESS: ESS now implements a simple message passing interface to + recognizes more reliably when you change ‘options('html_type')’. + • ESS[R]: New specialized breakpoints for debugging magrittr pipes + • ESS: ESS now implements a simple message passing interface to communicate between ESS and inferior process. Bug fixes in 16.04: - * ESS[R]: Roxygen blocks with backtics are now correctly filled - * ESS[R]: Don't skip breakpoints in magrittr's 'debug_pipe' - * ESS[R]: Error highlighting now understands 'testthat' type errors - * ESS[Julia]: Added getwd and setwd generic commands + • ESS[R]: Roxygen blocks with backtics are now correctly filled + • ESS[R]: Don't skip breakpoints in magrittr's ‘debug_pipe’ + • ESS[R]: Error highlighting now understands 'testthat' type errors + • ESS[Julia]: Added getwd and setwd generic commands  File: ess.info, Node: Credits, Next: Manual, Prev: New features, Up: Introduction @@ -866,41 +866,41 @@ than standard-input/standard-output, for Unix, Windows and Mac. In 2001, Sparapani added BUGS batch file processing to ESS for Unix and Windows. - * The multiple process code, and the idea for - 'ess-eval-line-and-next-line' are by Rod Ball. + • The multiple process code, and the idea for + ‘ess-eval-line-and-next-line’ are by Rod Ball. - * Thanks to Doug Bates for many useful suggestions. + • Thanks to Doug Bates for many useful suggestions. - * Thanks to Martin Maechler for reporting and fixing bugs, providing + • Thanks to Martin Maechler for reporting and fixing bugs, providing many useful comments and suggestions, and for maintaining the ESS mailing lists. - * Thanks to Frank Ritter for updates, particularly the menu code, and + • Thanks to Frank Ritter for updates, particularly the menu code, and invaluable comments on the manual. - * Thanks to Ken'ichi Shibayama for his excellent indenting code, and + • Thanks to Ken'ichi Shibayama for his excellent indenting code, and many comments and suggestions. - * Thanks to Aki Vehtari for adding interactive BUGS support. + • Thanks to Aki Vehtari for adding interactive BUGS support. - * Thanks to Brendan Halpin for bug-fixes and updates to Stata-mode. + • Thanks to Brendan Halpin for bug-fixes and updates to Stata-mode. - * Last, but definitely not least, thanks to the many ESS users and + • Last, but definitely not least, thanks to the many ESS users and contributors to the ESS mailing lists. _ESS_ is being developed and currently maintained by - * A.J. Rossini (mailto:blindglobe@gmail.com) - * Richard M. Heiberger (mailto:rmh@temple.edu) - * Kurt Hornik (mailto:Kurt.Hornik@R-project.org) - * Martin Maechler (mailto:maechler@stat.math.ethz.ch) - * Rodney A. Sparapani (mailto:rsparapa@mcw.edu) - * Stephen Eglen (mailto:stephen@gnu.org) - * Sebastian P. Luque (mailto:spluque@gmail.com) - * Henning Redestig (mailto:henning.red@googlemail.com) - * Vitalie Spinu (mailto:spinuvit@gmail.com) - * Lionel Henry (mailto:lionel.hry@gmail.com) - * J. Alexander Branham (mailto:alex.branham@gmail.com) + • A.J. Rossini (mailto:blindglobe@gmail.com) + • Richard M. Heiberger (mailto:rmh@temple.edu) + • Kurt Hornik (mailto:Kurt.Hornik@R-project.org) + • Martin Maechler (mailto:maechler@stat.math.ethz.ch) + • Rodney A. Sparapani (mailto:rsparapa@mcw.edu) + • Stephen Eglen (mailto:stephen@gnu.org) + • Sebastian P. Luque (mailto:spluque@gmail.com) + • Henning Redestig (mailto:henning.red@googlemail.com) + • Vitalie Spinu (mailto:spinuvit@gmail.com) + • Lionel Henry (mailto:lionel.hry@gmail.com) + • J. Alexander Branham (mailto:alex.branham@gmail.com)  File: ess.info, Node: Manual, Prev: Credits, Up: Introduction @@ -912,16 +912,16 @@ If you need to install ESS, read *note Installation:: for details on what needs to be done before proceeding to the next chapter. This section describes some of the basics of using Emacs. If you are already familiar with basic Emacs functionality, skip this section. You may -also want to use the Emacs tutorial, accessible via 'C-h t'. +also want to use the Emacs tutorial, accessible via ‘C-h t’. In this manual we use the standard notation used by Emacs for -describing the keystrokes used to invoke certain commands. 'C-' -means hold the CONTROL key while typing the character . 'M-' +describing the keystrokes used to invoke certain commands. ‘C-’ +means hold the CONTROL key while typing the character . ‘M-’ means hold the META key (usually ALT) down while typing . If there is no META, EDIT or ALT key, instead press and release the ESC key and then type . - All ESS commands can be invoked by typing 'M-x command'. Most of the + All ESS commands can be invoked by typing ‘M-x command’. Most of the useful commands are bound to keystrokes for ease of use. Also, the most popular commands are also available through the Emacs menubar, and a small subset are provided on the toolbar. Where possible, keybindings @@ -929,17 +929,17 @@ are similar to other modes in Emacs to strive for a consistent user interface within Emacs, regardless of the details of which programming language is being edited, or process being run. - Some commands, such as 'M-x R' can accept an optional 'prefix' -argument. To specify the prefix argument, you would type 'C-u' before -giving the command. For example, if you type 'C-u M-x R', you will be + Some commands, such as ‘M-x R’ can accept an optional 'prefix' +argument. To specify the prefix argument, you would type ‘C-u’ before +giving the command. For example, if you type ‘C-u M-x R’, you will be asked for command line options that you wish to invoke the R process with. Emacs is a 'self-documenting' text editor. This applies to ESS in two ways. First, some documentation about each ESS command can be -obtained by typing 'C-h f'. For example, if you type 'C-h f -ess-eval-region', documentation for that command will appear in a -separate *Help* buffer. Second, 'C-h m' pops up a complete list of +obtained by typing ‘C-h f’. For example, if you type ‘C-h f +ess-eval-region’, documentation for that command will appear in a +separate *Help* buffer. Second, ‘C-h m’ pops up a complete list of keybindings available in each ESS mode and brief description of that mode. @@ -949,7 +949,7 @@ nature of lisp. In particular, many aspects of ESS behaviour can be changed by suitable customization of Lisp variables. This manual mentions some of the most frequent variables. A full list of them however is available by using the Custom facility within Emacs. Type -'M-x customize-group RET ess RET' to get started. *note Customization:: +‘M-x customize-group RET ess RET’ to get started. *note Customization:: provides details of common user variables you can change to customize ESS to your taste, but it is recommended that you defer this section until you are more familiar with ESS. @@ -1010,17 +1010,17 @@ File: ess.info, Node: Installing from source, Next: Activating and Loading ESS Stable versions of ESS are available at the ESS web page (https://ess.r-project.org) as a .tgz file or .zip file. ESS releases are GPG-signed, you should check the signature by downloading the -accompanying '.sig' file and doing: +accompanying ‘.sig’ file and doing: gpg --verify ess-18.10.tgz.sig Alternatively, you may download the git repository. ESS is currently -hosted on GitHub: . 'git clone -https://github.com/emacs-ess/ESS.git' will download it to a new -directory 'ESS' in the current working directory. +hosted on GitHub: . ‘git clone +https://github.com/emacs-ess/ESS.git’ will download it to a new +directory ‘ESS’ in the current working directory. We will refer to the location of the ESS source files as -'/path/to/ESS/' hereafter. +‘/path/to/ESS/’ hereafter. After installing, users should make sure they activate or load ESS in each Emacs session, see *note Activating and Loading ESS:: @@ -1033,14 +1033,14 @@ autoloads: will not be available. Uncompiled ESS will also run slower. Optionally, you may make ESS available to all users of a machine by -installing it site-wide. To do so, run 'make install'. You might need +installing it site-wide. To do so, run ‘make install’. You might need administrative privileges: make install - The files are installed into '/usr/share/emacs' directory. For this -step to run correctly on macOS, you will need to adjust the 'PREFIX' -path in 'Makeconf'. The necessary code and instructions are commented + The files are installed into ‘/usr/share/emacs’ directory. For this +step to run correctly on macOS, you will need to adjust the ‘PREFIX’ +path in ‘Makeconf’. The necessary code and instructions are commented in that file.  @@ -1054,14 +1054,14 @@ ESS can be autoloaded, and if you used a third-party repository (such as your Linux distribution or MELPA) to install, you can likely skip this section and proceed directly to *note Check Installation:: - Otherwise, you may need to add the path to ESS to 'load-path' with: + Otherwise, you may need to add the path to ESS to ‘load-path’ with: (add-to-list 'load-path "/path/to/ESS/lisp") You then need to decide whether to take advantage of deferred loading (which will result in a faster Emacs startup time) or require ESS when Emacs is loaded. To autoload ESS when needed (note that if installed -from source, you must have run 'make'): +from source, you must have run ‘make’): (load "ess-autoloads") @@ -1083,7 +1083,7 @@ File: ess.info, Node: Check Installation, Prev: Activating and Loading ESS ====================== Restart Emacs and check that ESS was loaded from a correct location with -'M-x ess-version'. +‘M-x ess-version’.  File: ess.info, Node: Interactive ESS, Next: Entering commands, Prev: Installation, Up: Top @@ -1115,17 +1115,17 @@ File: ess.info, Node: Starting up, Next: Multiple ESS processes, Up: Interact =========================== To start an inferior R session on GNU/Linux, macOS, or Windows using the -Cygwin bash shell, simply type 'M-x R RET'. To start an R session on -Windows when you use the MSDOS/powershell shell, simply type 'M-x -S+6-msdos RET'. R will then (by default) ask the question +Cygwin bash shell, simply type ‘M-x R RET’. To start an R session on +Windows when you use the MSDOS/powershell shell, simply type ‘M-x +S+6-msdos RET’. R will then (by default) ask the question R starting data directory? Enter the name of the directory you wish to have as the working -directory (that is, the directory you wish to have 'getwd()' return if +directory (that is, the directory you wish to have ‘getwd()’ return if using R). - You will then be popped into a buffer named '*R*' which will be used + You will then be popped into a buffer named ‘*R*’ which will be used for interacting with the ESS process, and you can start entering commands. @@ -1137,18 +1137,18 @@ File: ess.info, Node: Multiple ESS processes, Next: ESS processes on Remote Co ESS allows you to run more than one iESS process simultaneously in the same session. Each process has a name and a number; the initial process -(process 1) is simply named 'R'. If you call 'M-x R' again without +(process 1) is simply named ‘R’. If you call ‘M-x R’ again without killing the first R process, ESS will start a second R process with the -name 'R:2'. To have the first buffer named 'R:1', customize the option -'ess-plain-first-buffername'. With a prefix argument, 'C-u M-x R' +name ‘R:2’. To have the first buffer named ‘R:1’, customize the option +‘ess-plain-first-buffername’. With a prefix argument, ‘C-u M-x R’ allows for the specification of command line options. -- User Option: ess-plain-first-buffername - If non-'nil', name the first iESS process [R]. Otherwise, name it + If non-‘nil’, name the first iESS process [R]. Otherwise, name it [R:1]. - You can switch to any active ESS process with the command 'M-x -ess-request-a-process'. Just enter the name of the process you require; + You can switch to any active ESS process with the command ‘M-x +ess-request-a-process’. Just enter the name of the process you require; completion is provided over the names of all running processes. This is a good command to consider binding to a global key. @@ -1165,17 +1165,17 @@ ESS works with processes on remote computers as easily as with processes on the local machine. The recommended way to access a statistical program on remote computer is to start it with *Note (tramp)Top::. - Start an ssh session using TRAMP with 'C-x C-f /ssh:user@host: RET'. + Start an ssh session using TRAMP with ‘C-x C-f /ssh:user@host: RET’. Tramp should open a dired buffer in your remote home directory. Now -call your favorite ESS process ('R', 'Julia', 'stata' etc) as you would -usually do on local machine: 'M-x R'. +call your favorite ESS process (‘R’, ‘Julia’, ‘stata’ etc) as you would +usually do on local machine: ‘M-x R’. - Alternatively you can start your process normally ('M-x R'). When -asked for starting directory, simply type '/ssh:user@host: RET'. The R + Alternatively you can start your process normally (‘M-x R’). When +asked for starting directory, simply type ‘/ssh:user@host: RET’. The R process will be started on the remote machine. To simplify the process even further create a "config" file in your -'.ssh/' folder and add an account. For example if you use amazon EC2, +‘.ssh/’ folder and add an account. For example if you use amazon EC2, it might look like following: Host amazon @@ -1184,7 +1184,7 @@ it might look like following: IdentityFile ~/.ssh/my_amazon_key.pem ForwardX11 yes - With this configuration '/ssh:amazon:' is enough to start a + With this configuration ‘/ssh:amazon:’ is enough to start a connection. The ForwardX11 is needed if you want to see the R graphic device showing on the current machine @@ -1192,22 +1192,22 @@ device showing on the current machine ---------------- TRAMP is the recommended way of starting a remote session. The other -way to start a remote ESS connection is through 'ess-remote'. +way to start a remote ESS connection is through ‘ess-remote’. 1. Start a new shell, telnet or ssh buffer and connect to the remote - computer (e.g. use, 'M-x shell', 'M-x telnet' or 'M-x ssh'; ssh.el + computer (e.g. use, ‘M-x shell’, ‘M-x telnet’ or ‘M-x ssh’; ssh.el is available at ). 2. Start the ESS process on the remote machine, for example with one - of the commands 'R', 'Splus', or 'sas -stdio'. + of the commands ‘R’, ‘Splus’, or ‘sas -stdio’. - 3. Start 'M-x ess-remote'. You will be prompted for a program name + 3. Start ‘M-x ess-remote’. You will be prompted for a program name with completion. Choose one. Your process is now known to ESS. - All the usual ESS commands ('C-c C-n' and its relatives) now work + All the usual ESS commands (‘C-c C-n’ and its relatives) now work with the R language processes. For SAS you need to use a different - command 'C-c i' (that is a regular 'i', not a 'C-i') to send lines - from your 'myfile.sas' to the remote SAS process. 'C-c i' sends + command ‘C-c i’ (that is a regular ‘i’, not a ‘C-i’) to send lines + from your ‘myfile.sas’ to the remote SAS process. ‘C-c i’ sends lines over invisibly. With ess-remote you get teletype behavior--the data input, the log, and the listing all appear in the same buffer. To make this work, you need to end every PROC and @@ -1217,8 +1217,8 @@ way to start a remote ESS connection is through 'ess-remote'. 4. Graphics (interactive) on the remote machine. If you run X11 (*Note X11::, X Windows) on both the local and remote machines then you should be able to display the graphs locally by setting the - 'DISPLAY' environment variable appropriately. Windows users can - download 'xfree86' from cygwin. + ‘DISPLAY’ environment variable appropriately. Windows users can + download ‘xfree86’ from cygwin. 5. Graphics (static) on the remote machine. If you don't run the X window system on the local machine, then you can write graphics to @@ -1226,16 +1226,16 @@ way to start a remote ESS connection is through 'ess-remote'. viewer on the local machine. Most statistical software can write one or more of postscript, GIF, or JPEG files. Depending on the versions of Emacs and the operating system that you are running, - Emacs itself may display '.gif' and '.jpg' files. Otherwise, a + Emacs itself may display ‘.gif’ and ‘.jpg’ files. Otherwise, a graphics file viewer will be needed. Ghostscript/ghostview may be - downloaded to display '.ps' and '.eps' files. Viewers for GIF and + downloaded to display ‘.ps’ and ‘.eps’ files. Viewers for GIF and JPEG are usually included with operating systems. *Note ESS(SAS)--Function keys for batch processing::, for more information on using the F12 key for displaying graphics files with SAS. Should you or a colleague inadvertently start a statistical process -in an ordinary '*shell*' buffer, the 'ess-remote' command can be used to +in an ordinary ‘*shell*’ buffer, the ‘ess-remote’ command can be used to convert it to an ESS buffer and allow you to use the ESS commands with it. @@ -1246,42 +1246,42 @@ File: ess.info, Node: Customizing startup, Next: Controlling buffer display, ================================ If you do not wish ESS to prompt for a starting directory when starting -a new process, set the variable 'ess-ask-for-ess-directory' to 'nil'. +a new process, set the variable ‘ess-ask-for-ess-directory’ to ‘nil’. In this case, the starting directory will be set using one of the following methods: - 1. If the variable 'ess-directory-function' stores the name of a + 1. If the variable ‘ess-directory-function’ stores the name of a function, the value returned by this function is used. The default for this variable is nil. - 2. Otherwise, if the variable 'ess-directory' stores the name of a + 2. Otherwise, if the variable ‘ess-directory’ stores the name of a directory (ending in a slash), this value is used. The default for this variable is nil. 3. Otherwise, the working directory of the current buffer is used. - If 'ess-ask-for-ess-directory' has a non-'nil' value (as it does by + If ‘ess-ask-for-ess-directory’ has a non-‘nil’ value (as it does by default) then the value determined by the above rules provides the default when prompting for the starting directory. Incidentally, -'ess-directory' is an ideal variable to set in 'ess-pre-run-hook'. +‘ess-directory’ is an ideal variable to set in ‘ess-pre-run-hook’. - You may also customize 'ess-post-run-hook' and the dialect-specific -'ess-*-post-run-hook' variables. For example, you may want to use -'ess-load-file' to load a file when ESS starts R: + You may also customize ‘ess-post-run-hook’ and the dialect-specific +‘ess-*-post-run-hook’ variables. For example, you may want to use +‘ess-load-file’ to load a file when ESS starts R: (add-hook 'ess-r-post-run-hook (lambda () (ess-load-file "foo.R"))) If you like to keep a record of your R actions, set the variable -'ess-ask-about-transfile' to 't', and you will be asked for a filename +‘ess-ask-about-transfile’ to ‘t’, and you will be asked for a filename for the transcript before the ESS process starts. -- User Option: ess-ask-about-transfile - If non-'nil', ask for a file name in which to save the session + If non-‘nil’, ask for a file name in which to save the session transcript. Enter the name of a file in which to save the transcript at the prompt. If the file doesn't exist it will be created (for R, you likely -want it to end in '.Rout'). If the file already exists the transcript +want it to end in ‘.Rout’). If the file already exists the transcript will be appended to the file. (Note: if you don't set this variable but you still want to save the transcript, you can still do it later -- *note Saving transcripts::.) @@ -1289,16 +1289,16 @@ you still want to save the transcript, you can still do it later -- Once these questions are answered (if they are asked at all) the inferior process itself is started. If you need to pass any arguments to this program, they may be specified in the variable -'inferior-S_PROGRAM_NAME-args'. For example, if 'inferior-ess-program' -is '"R"' then the variable to set is 'inferior-R-args'. It is not +‘inferior-S_PROGRAM_NAME-args’. For example, if ‘inferior-ess-program’ +is ‘"R"’ then the variable to set is ‘inferior-R-args’. It is not normally necessary to pass arguments to the iESS program; in particular -do not pass the '-e' option to 'Splus', since ESS provides its own +do not pass the ‘-e’ option to ‘Splus’, since ESS provides its own command history mechanism. ESS can set the width option of inferior processes automatically when -the window configuration changes. To do so, set 'ess-auto-width' to a +the window configuration changes. To do so, set ‘ess-auto-width’ to a non-nil value. By default, the change will not be shown in the inferior -buffer. If you want it to be shown, set 'ess-auto-width-visible' to a +buffer. If you want it to be shown, set ‘ess-auto-width-visible’ to a non-nil value.  @@ -1308,13 +1308,13 @@ File: ess.info, Node: Controlling buffer display, Prev: Customizing startup, ============================== Users can control how buffers are displayed by customizing -'display-buffer-alist', *Note (emacs)Window Choice::. This section +‘display-buffer-alist’, *Note (emacs)Window Choice::. This section provides examples of how to achieve certain setups. Users coming from RStudio may want the R process to appear at the bottom left of the frame, help buffers to appear at the bottom right, and ess-rdired buffers at the top right. To achieve that, you could -this. Note that the order matters; '*R Dired*' would match '*R' if it +this. Note that the order matters; ‘*R Dired*’ would match ‘*R’ if it came before in the alist. (setq display-buffer-alist @@ -1338,7 +1338,7 @@ came before in the alist. Some users prefer working with multiple frames where one frame has the source code and the other frame has the inferior process. To achieve this, use this example. For a detailed description of -'reusable-frames', see *Note (elisp)Buffer Display Action Alists::. +‘reusable-frames’, see *Note (elisp)Buffer Display Action Alists::. (setq display-buffer-alist '(("^\\*R" @@ -1374,7 +1374,7 @@ File: ess.info, Node: Entering commands, Next: Evaluating code, Prev: Interac The primary function of the ESS package is to provide an easy-to-use front end to the R interpreter. This is achieved by running the R process from within an Emacs buffer, called hereafter _inferior_ buffer, -which has an active 'inferior-ess-mode'. The features of inferior R +which has an active ‘inferior-ess-mode’. The features of inferior R mode are similar to those provided by the standard Emacs shell mode (*note (emacs)Shell Mode::). Command-line completion of R objects and a number of 'hot keys' for commonly-used R commands are also provided for @@ -1401,9 +1401,9 @@ Sending a command to the ESS process is as simple as typing it in and pressing the key: -- Command: inferior-ess-send-input - 'RET' Send the command on the current line to the ESS process. + ‘RET’ Send the command on the current line to the ESS process. - If you make a typing error before pressing 'RET' all the usual Emacs + If you make a typing error before pressing ‘RET’ all the usual Emacs editing commands are available to correct it (*note Basic: (emacs)Basic.). Once the command has been corrected you can press (even if the cursor is not at the end of the line) to send the @@ -1412,17 +1412,17 @@ corrected command to the ESS process. Emacs provides some other commands which are useful for fixing mistakes: -'C-c C-w' - 'backward-kill-word' Deletes the previous word (such as an object +‘C-c C-w’ + ‘backward-kill-word’ Deletes the previous word (such as an object name) on the command line. -'C-c C-u' - 'comint-kill-input' Deletes everything from the prompt to point. +‘C-c C-u’ + ‘comint-kill-input’ Deletes everything from the prompt to point. Use this to abandon a command you have not yet sent to the ESS process. -'C-a' - 'comint-bol' Move to the beginning of the line, and then skip +‘C-a’ + ‘comint-bol’ Move to the beginning of the line, and then skip forwards past the prompt, if any. *Note (emacs)Shell Mode::, for other commands relevant to entering @@ -1442,18 +1442,18 @@ through the buffer, to look at the output from previous commands for example. Within the process buffer, a paragraph is defined as the prompt, the -command after the prompt, and the output from the command. Thus 'M-{' -and 'M-}' move you backwards and forwards, respectively, through -commands in the transcript. A particularly useful command is 'M-h' -('mark-paragraph') which will allow you to mark a command and its entire +command after the prompt, and the output from the command. Thus ‘M-{’ +and ‘M-}’ move you backwards and forwards, respectively, through +commands in the transcript. A particularly useful command is ‘M-h’ +(‘mark-paragraph’) which will allow you to mark a command and its entire output (for deletion, perhaps). For more information about paragraph commands, *note Paragraphs: (emacs)Paragraphs. If an ESS process finishes and you restart it in the same process buffer, the output from the new ESS process appears after the output -from the first ESS process separated by a form-feed ('^L') character. +from the first ESS process separated by a form-feed (‘^L’) character. Thus pages in the ESS process buffer correspond to ESS sessions. Thus, -for example, you may use 'C-x [' and 'C-x ]' to move backward and +for example, you may use ‘C-x [’ and ‘C-x ]’ to move backward and forwards through ESS sessions in a single ESS process buffer. For more information about page commands, *note Pages: (emacs)Pages. @@ -1479,16 +1479,16 @@ window, even though the entire output would fit in the window if the prompt were near the bottom of the window. If this happens, you can use the following comint commands: - 'comint-show-maximum-output' to move to the end of the buffer, and + ‘comint-show-maximum-output’ to move to the end of the buffer, and place cursor on bottom line of window to make more of the last output visible. To make this happen automatically for all inputs, set the -variable 'comint-scroll-to-bottom-on-input' to 't' or ''this'. If the -first part of the output is still not visible, use 'C-c C-r' -('comint-show-output'), which moves cursor to the previous command line +variable ‘comint-scroll-to-bottom-on-input’ to ‘t’ or ‘'this’. If the +first part of the output is still not visible, use ‘C-c C-r’ +(‘comint-show-output’), which moves cursor to the previous command line and places it at the top of the window. Finally, if you want to discard the last command output altogether, -use 'C-c C-o' ('comint-delete-output'), which deletes everything from +use ‘C-c C-o’ (‘comint-delete-output’), which deletes everything from the last command to the current prompt. Use this command judiciously to keep your transcript to a more manageable size. @@ -1502,16 +1502,16 @@ If you want to view the output from more historic commands than the previous command, commands are also provided to move backwards and forwards through previously entered commands in the process buffer: -'C-c C-p' - 'comint-previous-prompt' Moves point to the preceding prompt in the +‘C-c C-p’ + ‘comint-previous-prompt’ Moves point to the preceding prompt in the process buffer. -'C-c C-n' - 'comint-next-prompt' Moves point to the next prompt in the process +‘C-c C-n’ + ‘comint-next-prompt’ Moves point to the next prompt in the process buffer. -Note that these two commands are analogous to 'C-p' and 'C-n' but apply -to command lines rather than text lines. And just like 'C-p' and 'C-n', +Note that these two commands are analogous to ‘C-p’ and ‘C-n’ but apply +to command lines rather than text lines. And just like ‘C-p’ and ‘C-n’, passing a prefix argument to these commands means to move to the ARG'th next (or previous) command. (These commands are also discussed in *note Shell History Copying: (emacs)Shell History Copying.) @@ -1522,8 +1522,8 @@ prompt for a regular expression (*note Syntax of Regular Expression: (emacs)Regexps.), and then moves to the next (previous) command matching the pattern. -'comint-backward-matching-input regexp arg' -'comint-forward-matching-input regexp arg' +‘comint-backward-matching-input regexp arg’ +‘comint-forward-matching-input regexp arg’ Search backward (forward) through the transcript buffer for the ARG'th previous (next) command matching REGEXP. ARG is the prefix argument; REGEXP is prompted for in the minibuffer. @@ -1540,24 +1540,24 @@ commands may be used whenever the cursor is within a command line in the transcript (if the cursor is within some command _output_, an error is signaled). Note all commands involve the key. -'RET' - 'inferior-ess-send-input' *Note Command-line editing::. +‘RET’ + ‘inferior-ess-send-input’ *Note Command-line editing::. -'C-c RET' - 'comint-copy-old-input' Copy the command under the cursor to the +‘C-c RET’ + ‘comint-copy-old-input’ Copy the command under the cursor to the current command line, but don't execute it. Leaves the cursor on the command line so that the copied command may be edited. When the cursor is not after the current prompt, the key has -a slightly different behavior than usual. Pressing 'RET' on any line +a slightly different behavior than usual. Pressing ‘RET’ on any line containing a command that you entered (i.e. a line beginning with a prompt) sends that command to the ESS process once again. If you wish -to edit the command before executing it, use 'C-c RET' instead; it +to edit the command before executing it, use ‘C-c RET’ instead; it copies the command to the current prompt but does not execute it, allowing you to edit it before (re)submitting it. These commands work even if the current line is a continuation line -(i.e. the prompt is '+' instead of '>') -- in this case all the lines +(i.e. the prompt is ‘+’ instead of ‘>’) -- in this case all the lines that form the multi-line command are concatenated together and the resulting command is sent to the ESS process (currently this is the only way to resubmit a multi-line command to the ESS process in one go). If @@ -1574,31 +1574,31 @@ File: ess.info, Node: Saving transcripts, Prev: Transcript resubmit, Up: Tran ---------------------------------------- To keep a record of your R session in a disk file, use the Emacs command -'C-x C-w' ('write-file') to attach a file to the ESS process buffer. +‘C-x C-w’ (‘write-file’) to attach a file to the ESS process buffer. The name of the process buffer will (probably) change to the name of the file, but this is not a problem. You can still use R as usual; just -remember to save the file before you quit Emacs with 'C-x C-s'. You can +remember to save the file before you quit Emacs with ‘C-x C-s’. You can make ESS prompt you for a filename in which to save the transcript every -time you start R by setting the variable 'ess-ask-about-transfile' to -'t'; *Note Customizing startup::. For R files, naming transcript files -'*.Rout' puts them in a special mode (ESS transcript mode -- *note +time you start R by setting the variable ‘ess-ask-about-transfile’ to +‘t’; *Note Customizing startup::. For R files, naming transcript files +‘*.Rout’ puts them in a special mode (ESS transcript mode -- *note Transcript Mode::) for editing transcript files which is automatically selected for files with this suffix. R transcripts can get very large, so some judicious editing is -appropriate if you are saving it in a file. Use 'C-c C-o' whenever a +appropriate if you are saving it in a file. Use ‘C-c C-o’ whenever a command produces excessively long output (printing large arrays, for example). Delete erroneous commands (and the resulting error messages or other output) by moving to the command (or its output) and typing -'M-h C-w'. Also, remember that 'C-c C-x' (and other hot keys) may be +‘M-h C-w’. Also, remember that ‘C-c C-x’ (and other hot keys) may be used for commands whose output you do not wish to appear in the transcript. These suggestions are appropriate even if you are not saving your transcript to disk, since the larger the transcript, the more memory your Emacs process will use on the host machine. - You can use 'ess-transcript-clean-region' to strip output from a + You can use ‘ess-transcript-clean-region’ to strip output from a transcript, leaving only source code suitable for inclusion in files -'source()'-able from R. *note Transcript Mode: Clean. +‘source()’-able from R. *note Transcript Mode: Clean.  File: ess.info, Node: Command History, Next: History expansion, Prev: Transcript, Up: Entering commands @@ -1609,21 +1609,21 @@ File: ess.info, Node: Command History, Next: History expansion, Prev: Transcr ESS provides easy-to-use facilities for re-executing or editing previous commands. An input history of the last few commands is maintained (by default the last 500 commands are stored, although this can be changed -by setting the variable 'comint-input-ring-size' in -'inferior-ess-mode-hook'.) The simplest history commands simply select +by setting the variable ‘comint-input-ring-size’ in +‘inferior-ess-mode-hook’.) The simplest history commands simply select the next and previous commands in the input history: -'M-p' - 'comint-previous-input' Select the previous command in the input +‘M-p’ + ‘comint-previous-input’ Select the previous command in the input history. -'M-n' - 'comint-next-input' Select the next command in the input history. +‘M-n’ + ‘comint-next-input’ Select the next command in the input history. -For example, pressing 'M-p' once will re-enter the last command into the +For example, pressing ‘M-p’ once will re-enter the last command into the process buffer after the prompt but does not send it to the ESS process, thus allowing editing or correction of the command before the ESS -process sees it. Once corrections have been made, press 'RET' to send +process sees it. Once corrections have been made, press ‘RET’ to send the edited command to the ESS process. If you want to select a particular command from the history by @@ -1631,8 +1631,8 @@ matching it against a regular expression (*note Syntax of Regular Expression: (emacs)Regexps.), to search for a particular variable name for example, these commands are also available: -'M-r' - 'comint-history-isearch-backward-regexp' Prompt for a regular +‘M-r’ + ‘comint-history-isearch-backward-regexp’ Prompt for a regular expression, and search backwards through the input history for a command matching the expression. @@ -1640,21 +1640,21 @@ A common type of search is to find the last command that began with a particular sequence of characters; the following two commands provide an easy way to do this: -'C-c M-r' - 'comint-previous-matching-input-from-input' Select the previous +‘C-c M-r’ + ‘comint-previous-matching-input-from-input’ Select the previous command in the history which matches the string typed so far. -'C-c M-s' - 'comint-next-matching-input-from-input' Select the next command in +‘C-c M-s’ + ‘comint-next-matching-input-from-input’ Select the next command in the history which matches the string typed so far. Instead of prompting for a regular expression to match against, as they instead select commands starting with those characters already entered. -For instance, if you wanted to re-execute the last 'attach()' command, -you may only need to type 'att' and then 'C-c M-r' and 'RET'. +For instance, if you wanted to re-execute the last ‘attach()’ command, +you may only need to type ‘att’ and then ‘C-c M-r’ and ‘RET’. *Note Shell History Ring: (emacs)Shell Ring, for a more detailed -discussion of the history mechanism, and do experiment with the 'In/Out' +discussion of the history mechanism, and do experiment with the ‘In/Out’ menu to explore the possibilities. Many ESS users like to have even easier access to these, and @@ -1673,10 +1673,10 @@ recommend adding something like )) to your Emacs configuration file, where the last two settings are typically desirable for the situation where you work with a script (for -example, 'code.R') and send code chunks to the process buffer (e.g. -'*R*'). Note however that these settings influence all 'comint'-using +example, ‘code.R’) and send code chunks to the process buffer (e.g. +‘*R*’). Note however that these settings influence all ‘comint’-using Emacs modes, not just the ESS ones, and for that reason, these -customization cannot be part of 'ESS' itself. +customization cannot be part of ‘ESS’ itself. * Menu: @@ -1688,10 +1688,10 @@ File: ess.info, Node: Saving History, Up: Command History 4.3.1 Saving the command history -------------------------------- -The 'ess-history-file' variable, which is 't' by default, together with -'ess-history-directory', governs if and where the command history is +The ‘ess-history-file’ variable, which is ‘t’ by default, together with +‘ess-history-directory’, governs if and where the command history is saved and restored between sessions. By default, -'ess-history-directory' is 'nil', and the command history will be stored +‘ess-history-directory’ is ‘nil’, and the command history will be stored (as a file) in the same directory as the iESS process. ESS users may work exclusively with script files rather than in a @@ -1714,82 +1714,82 @@ File: ess.info, Node: History expansion, Next: Hot keys, Prev: Command Histor Instead of searching through the command history using the command described in the previous section, you can alternatively refer to a historical command directly using a notation very similar to that used -in 'csh'. History references are introduced by a '!' or '^' character +in ‘csh’. History references are introduced by a ‘!’ or ‘^’ character and have meanings as follows: -'!!' +‘!!’ The immediately previous command -'!-N' +‘!-N’ The Nth previous command -'!text' - The last command beginning with the string 'text' +‘!text’ + The last command beginning with the string ‘text’ -'!?text' - The last command containing the string 'text' +‘!?text’ + The last command containing the string ‘text’ - In addition, you may follow the reference with a "word designator" to -select particular "words" of the input. A word is defined as a sequence + In addition, you may follow the reference with a “word designator” to +select particular “words” of the input. A word is defined as a sequence of characters separated by whitespace. (You can modify this definition -by setting the value of 'comint-delimiter-argument-list' to a list of +by setting the value of ‘comint-delimiter-argument-list’ to a list of characters that are allowed to separate words and themselves form words.) Words are numbered beginning with zero. The word designator -usually begins with a ':' (colon) character; however it may be omitted -if the word reference begins with a '^', '$', '*' or '-'. If the word -is to be selected from the previous command, the second '!' character -can be omitted from the event specification. For instance, '!!:1' and -'!:1' both refer to the first word of the previous command, while '!!$' -and '!$' both refer to the last word in the previous command. The +usually begins with a ‘:’ (colon) character; however it may be omitted +if the word reference begins with a ‘^’, ‘$’, ‘*’ or ‘-’. If the word +is to be selected from the previous command, the second ‘!’ character +can be omitted from the event specification. For instance, ‘!!:1’ and +‘!:1’ both refer to the first word of the previous command, while ‘!!$’ +and ‘!$’ both refer to the last word in the previous command. The format of word designators is as follows: -'0' +‘0’ The zeroth word (i.e. the first one on the command line) -'N' +‘N’ The Nth word, where N is a number -'^' +‘^’ The first word (i.e. the second one on the command line) -'$' +‘$’ The last word -'X-Y' - A range of words; '-Y' abbreviates '0-Y' +‘X-Y’ + A range of words; ‘-Y’ abbreviates ‘0-Y’ -'*' +‘*’ All the words except the zeroth word, or nothing if the command had just one word (the zeroth) -'X*' +‘X*’ Abbreviates X-$ -'X-' - Like 'X*', but omitting the last word +‘X-’ + Like ‘X*’, but omitting the last word In addition, you may surround the entire reference except for the -first '!' by braces to allow it to be followed by other (non-whitespace) +first ‘!’ by braces to allow it to be followed by other (non-whitespace) characters (which will be appended to the expanded reference). Finally, ESS also provides quick substitution; a reference like -'^old^new^' means "the last command, but with the first occurrence of -the string 'old' replaced with the string 'new'" (the last '^' is -optional). Similarly, '^old^' means "the last command, with the first -occurrence of the string 'old' deleted" (again, the last '^' is +‘^old^new^’ means "the last command, but with the first occurrence of +the string ‘old’ replaced with the string ‘new’" (the last ‘^’ is +optional). Similarly, ‘^old^’ means "the last command, with the first +occurrence of the string ‘old’ deleted" (again, the last ‘^’ is optional). To convert a history reference as described above to an input -suitable for R, you need to "expand" the history reference, using the +suitable for R, you need to “expand” the history reference, using the key. For this to work, the cursor must be preceded by a space (otherwise it would try to complete an object name) and not be within a string (otherwise it would try to complete a filename). So to expand -the history reference, type 'SPC TAB'. This will convert the history +the history reference, type ‘SPC TAB’. This will convert the history reference into an R command from the history, which you can then edit or press to execute. For example, to execute the last command that referenced the variable -'data', type '!?data SPC TAB RET'. +‘data’, type ‘!?data SPC TAB RET’.  File: ess.info, Node: Hot keys, Next: Statistical Process running in ESS?, Prev: History expansion, Up: Entering commands @@ -1799,75 +1799,75 @@ File: ess.info, Node: Hot keys, Next: Statistical Process running in ESS?, Pr ESS provides a number of commands for executing the commonly used functions. These commands below are basically information-gaining -commands (such as 'objects()' or 'search()') which tend to clutter up +commands (such as ‘objects()’ or ‘search()’) which tend to clutter up your transcript and for this reason some of the hot keys display their output in a temporary buffer instead of the process buffer by default. This behavior is controlled by the following option: -- User Option: ess-execute-in-process-buffer - If non-'nil', means that these commands will produce their output + If non-‘nil’, means that these commands will produce their output in the process buffer instead. - In any case, passing a prefix argument to the commands (with 'C-u') -will reverse the meaning of 'ess-execute-in-process-buffer' for that + In any case, passing a prefix argument to the commands (with ‘C-u’) +will reverse the meaning of ‘ess-execute-in-process-buffer’ for that command. In other words, the output will be displayed in the process buffer if it usually goes to a temporary buffer, and vice-versa. These are the hot keys that behave in this way: -- Command: ess-execute-objects POSN - 'C-c C-x' Sends the 'objects()' command to the ESS process. A + ‘C-c C-x’ Sends the ‘objects()’ command to the ESS process. A prefix argument specifies the position on the search list (use a - negative argument to toggle 'ess-execute-in-process-buffer' as + negative argument to toggle ‘ess-execute-in-process-buffer’ as well). This is a quick way to see what objects are in your working directory. A prefix argument of 2 or more means get objects for that position. A negative prefix argument POSN gets the objects for that position, as well as toggling - 'ess-execute-in-process-buffer'. + ‘ess-execute-in-process-buffer’. -- Command: ess-execute-search INVERT - 'C-c C-s' Sends the 'inferior-ess-search-list-command' command to - the 'ess-language' process; 'search()' in R. Prefix INVERT toggles - 'ess-execute-in-process-buffer'. + ‘C-c C-s’ Sends the ‘inferior-ess-search-list-command’ command to + the ‘ess-language’ process; ‘search()’ in R. Prefix INVERT toggles + ‘ess-execute-in-process-buffer’. - 'ess-execute' may seem pointless when you could just type the command + ‘ess-execute’ may seem pointless when you could just type the command in anyway, but it proves useful for 'spot' calculations which would otherwise clutter your transcript, or for evaluating an expression while partway through entering a command. You can also use this command to generate new hot keys using the Emacs keyboard macro facilities; *note Keyboard Macros: (emacs)Keyboard Macros. - The following hot keys do not use 'ess-execute-in-process-buffer' to + The following hot keys do not use ‘ess-execute-in-process-buffer’ to decide where to display the output -- they either always display in the process buffer or in a separate buffer, as indicated: -- Command: ess-load-file FILENAME - 'C-c M-l' Prompts for a file (FILENAME) to load into the ESS - process using 'source()'. If there is an error during loading, you + ‘C-c M-l’ Prompts for a file (FILENAME) to load into the ESS + process using ‘source()’. If there is an error during loading, you can jump to the error in the file with the following function. -- Command: ess-parse-errors ARG RESET - Visits next 'next-error' message and corresponding source code. If + Visits next ‘next-error’ message and corresponding source code. If all the error messages parsed so far have been processed already, the message buffer is checked for new ones. A prefix ARG specifies how many error messages to move; negative means move back to - previous error messages. Just 'C-u' as a prefix means reparse the + previous error messages. Just ‘C-u’ as a prefix means reparse the error message buffer and start at the first error. The RESET argument specifies restarting from the beginning. *Note Error Checking::, for more details. -- Command: ess-display-help-on-object OBJECT COMMAND - 'C-c C-v' Pops up a help buffer for an R object or function. If + ‘C-c C-v’ Pops up a help buffer for an R object or function. If COMMAND is supplied, it is used instead of - 'inferior-ess-help-command'. See *note Help:: for more details. + ‘inferior-ess-help-command’. See *note Help:: for more details. -- Command: ess-quit - 'C-c C-q' Issue an exiting command to the inferior process, - additionally also running 'ess-cleanup' for disposing of any + ‘C-c C-q’ Issue an exiting command to the inferior process, + additionally also running ‘ess-cleanup’ for disposing of any temporary buffers (such as help buffers and edit buffers) that may have been created. Use this command when you have finished your R session instead of simply quitting at the inferior process prompt, - otherwise you will need to issue the command 'ess-cleanup' + otherwise you will need to issue the command ‘ess-cleanup’ explicitly to make sure that all the files that need to be saved have been saved, and that all the temporary buffers have been killed. @@ -1882,24 +1882,24 @@ For the R languages (R, S, S-Plus) ESS sets an option in the current process that programs in the language can check to determine the environment in which they are currently running. - ESS sets 'options(STERM="iESS")' for R language processes running in -an inferior 'iESS[S]' or 'iESS[R]' buffer. + ESS sets ‘options(STERM="iESS")’ for R language processes running in +an inferior ‘iESS[S]’ or ‘iESS[R]’ buffer. - ESS sets 'options(STERM="ddeESS")' for independent S-Plus for Windows + ESS sets ‘options(STERM="ddeESS")’ for independent S-Plus for Windows processes running in the GUI and communicating with ESS via the DDE -(Microsoft Dynamic Data Exchange) protocol through a 'ddeESS[S]' buffer. +(Microsoft Dynamic Data Exchange) protocol through a ‘ddeESS[S]’ buffer. - Other values of 'options()$STERM' that we recommend are: + Other values of ‘options()$STERM’ that we recommend are: - * 'length': Fixed length xterm or telnet window. - * 'scrollable': Unlimited length xterm or telnet window. - * 'server': S-Plus Stat Server. - * 'BATCH': BATCH. - * 'Rgui': R GUI. - * 'Commands': S-Plus GUI without DDE interface to ESS. + • ‘length’: Fixed length xterm or telnet window. + • ‘scrollable’: Unlimited length xterm or telnet window. + • ‘server’: S-Plus Stat Server. + • ‘BATCH’: BATCH. + • ‘Rgui’: R GUI. + • ‘Commands’: S-Plus GUI without DDE interface to ESS. Additional values may be recommended in the future as new interaction -protocols are created. Unlike the values 'iESS' and 'ddeESS', ESS can't +protocols are created. Unlike the values ‘iESS’ and ‘ddeESS’, ESS can't set these other values since the R language program is not under the control of ESS. @@ -1910,14 +1910,14 @@ File: ess.info, Node: Emacsclient, Next: Other, Prev: Statistical Process run ===================== When starting R or S under Unix, ESS sets -'options(editor="emacsclient")'. Under Microsoft Windows, it will use +‘options(editor="emacsclient")’. Under Microsoft Windows, it will use gnuclient.exe rather than emacsclient, but the same principal applies. -Within your R session, if you have a function called 'iterator', typing -'fix(iterator)', will show that function in a temporary Emacs buffer. +Within your R session, if you have a function called ‘iterator’, typing +‘fix(iterator)’, will show that function in a temporary Emacs buffer. You can then correct the function. When you kill the buffer, the -definition of the function is updated. Using 'edit()' rather than -'fix()' means that the function is not updated. Finally, the R function -'page(x)' will also show a text representation of the object 'x' in a +definition of the function is updated. Using ‘edit()’ rather than +‘fix()’ means that the function is not updated. Finally, the R function +‘page(x)’ will also show a text representation of the object ‘x’ in a temporary Emacs buffer.  @@ -1929,20 +1929,20 @@ File: ess.info, Node: Other, Prev: Emacsclient, Up: Entering commands The following commands are also available in the process buffer: -- Command: comint-interrupt-subjob - 'C-c C-c' Sends a Control-C signal to the iESS process. This has + ‘C-c C-c’ Sends a Control-C signal to the iESS process. This has the effect of aborting the current command. -- Command: ess-switch-to-inferior-or-script-buffer TOGGLE-EOB - 'C-c C-z' When in process buffer, return to the most recent script + ‘C-c C-z’ When in process buffer, return to the most recent script buffer. When in a script buffer pop to the associated process - buffer. Consecutive presses of 'C-z' switch between the script and + buffer. Consecutive presses of ‘C-z’ switch between the script and process buffers. If TOGGLE-EOB is given, the value of - 'ess-switch-to-end-of-proc-buffer' is toggled. + ‘ess-switch-to-end-of-proc-buffer’ is toggled. -- User Option: ess-switch-to-end-of-proc-buffer - If non-'nil', 'ess-switch-to-inferior-or-script-buffer' goes to end + If non-‘nil’, ‘ess-switch-to-inferior-or-script-buffer’ goes to end of process buffer. Other commands available in iESS modes are discussed in *note @@ -1957,83 +1957,83 @@ File: ess.info, Node: Evaluating code, Next: Transcript Mode, Prev: Entering Other commands are also available for evaluating portions of code in the R process. These commands cause the selected code to be evaluated directly by the ESS process as if you had typed them in at the command -line; the 'source()' function is not used. You may choose whether both +line; the ‘source()’ function is not used. You may choose whether both the commands and their output appear in the process buffer (as if you had typed in the commands yourself) or if the output alone is echoed. The behavior is controlled by the variable: -- User Option: ess-eval-visibly - Non-'nil' means 'ess-eval-*' commands display commands and output - in the process buffer. A value of 't' blocks Emacs while R is - busy. A value of 'nowait' does not block Emacs but printing may be + Non-‘nil’ means ‘ess-eval-*’ commands display commands and output + in the process buffer. A value of ‘t’ blocks Emacs while R is + busy. A value of ‘nowait’ does not block Emacs but printing may be slightly off. - Passing a prefix ('C-u') (in Elisp terms, the argument VIS) to any of + Passing a prefix (‘C-u’) (in Elisp terms, the argument VIS) to any of the following commands, however, reverses the meaning of -'ess-eval-visibly' for that command only -- for example 'C-u C-c C-j' +‘ess-eval-visibly’ for that command only -- for example ‘C-u C-c C-j’ evaluates the current line without showing the input in the iESS buffer. -The default value of 'ess-eval-visibly' ('t') means that ESS calls block +The default value of ‘ess-eval-visibly’ (‘t’) means that ESS calls block Emacs until they finish. This may be undesirable, especially if commands take long to finish. Users who want input to be displayed and -Emacs not to be blocked can set 'ess-eval-visibly' to ''nowait'. This +Emacs not to be blocked can set ‘ess-eval-visibly’ to ‘'nowait’. This sends the input to the iESS buffer but does not wait for the process to finish, ensuring Emacs is not blocked. Primary commands for evaluating code are: -- Command: ess-eval-region-or-line-and-step VIS - 'C-' Sends the highlighted region or current line and step to + ‘C-’ Sends the highlighted region or current line and step to next line of code. -- Command: ess-eval-region-or-function-or-paragraph VIS - 'C-M-x' Sends the current selected region or function or paragraph. + ‘C-M-x’ Sends the current selected region or function or paragraph. -- Command: ess-eval-region-or-function-or-paragraph-and-step VIS - 'C-c C-c' Like 'ess-eval-region-or-function-or-paragraph' but steps + ‘C-c C-c’ Like ‘ess-eval-region-or-function-or-paragraph’ but steps to next line of code. Other, not so often used, evaluation commands are: -- Command: ess-eval-line VIS - 'C-c C-j' Sends the current line to the ESS process. + ‘C-c C-j’ Sends the current line to the ESS process. -- Command: ess-eval-line-and-go VIS - 'C-c M-j' Like 'ess-eval-line' but additionally switches point to + ‘C-c M-j’ Like ‘ess-eval-line’ but additionally switches point to the ESS process. -- Command: ess-eval-function VIS NO-ERROR - 'C-c C-f' Sends the function containing point to the ESS process. + ‘C-c C-f’ Sends the function containing point to the ESS process. -- Command: ess-eval-function-and-go VIS - 'C-c M-f' Like 'ess-eval-function' but additionally switches point + ‘C-c M-f’ Like ‘ess-eval-function’ but additionally switches point to the ESS process. -- Command: ess-eval-region START END TOGGLE MESSAGE - 'C-c C-r' Sends the current region to the ESS process. + ‘C-c C-r’ Sends the current region to the ESS process. -- Command: ess-eval-region-and-go START END VIS - 'C-c M-r' Like 'ess-eval-region' but additionally switches point to + ‘C-c M-r’ Like ‘ess-eval-region’ but additionally switches point to the ESS process. -- Command: ess-eval-buffer VIS - 'C-c C-b' Sends the current buffer to the ESS process. + ‘C-c C-b’ Sends the current buffer to the ESS process. -- Command: ess-eval-buffer-and-go VIS - 'C-c M-b' Like 'ess-eval-buffer' but additionally switches point to + ‘C-c M-b’ Like ‘ess-eval-buffer’ but additionally switches point to the ESS process. - All the above 'ess-eval-*' commands are useful for evaluating small + All the above ‘ess-eval-*’ commands are useful for evaluating small amounts of code and observing the results in the process buffer for debugging purposes, or for generating transcripts from source files. -When editing R functions, it is generally preferable to use 'C-c C-l' to -update the function's value. In particular, 'ess-eval-buffer' is now +When editing R functions, it is generally preferable to use ‘C-c C-l’ to +update the function's value. In particular, ‘ess-eval-buffer’ is now largely obsolete. A useful way to work is to divide the frame into two windows; one containing the source code and the other containing the process buffer. If you wish to make the process buffer scroll automatically when the output reaches the bottom of the window, you will need to set the -variable 'comint-move-point-for-output' to ''others' or 't'. +variable ‘comint-move-point-for-output’ to ‘'others’ or ‘t’.  File: ess.info, Node: Transcript Mode, Next: Editing objects, Prev: Evaluating code, Up: Top @@ -2043,18 +2043,18 @@ File: ess.info, Node: Transcript Mode, Next: Editing objects, Prev: Evaluatin Inferior R mode records the transcript (the list of all commands executed, and their output) in the process buffer, which can be saved as -a "transcript file", which should normally have the suffix '.Rout'. The +a “transcript file”, which should normally have the suffix ‘.Rout’. The most obvious use for a transcript file is as a static record of the actions you have performed in a particular R session. Sometimes, however, you may wish to re-execute commands recorded in the transcript file by submitting them to a running ESS process. This is what Transcript Mode is for. - If you load file a with the suffix '.Rout' into Emacs, it is placed + If you load file a with the suffix ‘.Rout’ into Emacs, it is placed in R Transcript Mode. Transcript Mode is similar to inferior R mode (*note Entering commands::): paragraphs are defined as a command and its output, and you can move though commands either with the paragraph -commands or with 'C-c C-p' and 'C-c C-n'. +commands or with ‘C-c C-p’ and ‘C-c C-n’. * Menu: @@ -2071,15 +2071,15 @@ Three commands are provided to re-submit command lines from the transcript file to a running ESS process. They are: -- Command: ess-transcript-send-command - 'M-RET' Sends the current command line to the ESS process, and + ‘M-RET’ Sends the current command line to the ESS process, and execute it. -- Command: ess-transcript-copy-command - 'C-c RET' Copy the current command to the ESS process, and switch + ‘C-c RET’ Copy the current command to the ESS process, and switch to it (ready to edit the copied command). -- Command: ess-transcript-send-command-and-move - 'RET' Sends the current command to the ESS process, and move to the + ‘RET’ Sends the current command to the ESS process, and move to the next command line. This command is useful for submitting a series of commands. @@ -2099,7 +2099,7 @@ inclusion in an R source file or function. Transcript mode provides one command which does just this: -- Command: ess-transcript-clean-region BEG END EVEN-IF-READ-ONLY - 'C-c C-w' Strip the transcript in the region (given by BEG and + ‘C-c C-w’ Strip the transcript in the region (given by BEG and END), leaving only commands. Deletes any lines not beginning with a prompt, and then removes the prompt from those lines that remain. Prefix argument EVEN-IF-READ-ONLY means to clean even if the buffer @@ -2143,25 +2143,25 @@ File: ess.info, Node: Edit buffer, Next: Loading, Up: Editing objects To edit an object, type -- Command: ess-dump-object-into-edit-buffer OBJECT - 'C-c C-e C-d' Edit an object in its own edit buffer. + ‘C-c C-e C-d’ Edit an object in its own edit buffer. - from within the iESS process buffer ('*R*'). You will then be + from within the iESS process buffer (‘*R*’). You will then be prompted for an object to edit: you may either type in the name of an -existing object (for which completion is available using the 'TAB' key), +existing object (for which completion is available using the ‘TAB’ key), or you may enter the name of a new object. A buffer will be created containing the text representation of the requested object or, if you entered the name of a non-existent object at the prompt and the variable -'ess-function-template' is non-'nil', you will be presented with a +‘ess-function-template’ is non-‘nil’, you will be presented with a template defined by that variable, which defaults to a skeleton function construct. You may then edit the function as required. The edit buffer -generated by 'ess-dump-object-into-edit-buffer' is placed in the 'ESS' +generated by ‘ess-dump-object-into-edit-buffer’ is placed in the ‘ESS’ major mode which provides a number of commands to facilitate editing R source code. Commands are provided to intelligently indent R code, evaluate portions of R code and to move around R code constructs. - Note: when you dump a file with 'C-c C-e C-d', ESS first checks to + Note: when you dump a file with ‘C-c C-e C-d’, ESS first checks to see whether there already exists an edit buffer containing that object and, if so, pops you directly to that buffer. If not, ESS next checks whether there is a file in the appropriate place with the appropriate @@ -2169,11 +2169,11 @@ name (*note Source Files::) and if so, reads in that file. You can use this facility to return to an object you were editing in a previous session (and which possibly was never loaded to the R session). Finally, if both these tests fail, the ESS process is consulted and a -'dump()' command issued. If you want to force ESS to ask the ESS +‘dump()’ command issued. If you want to force ESS to ask the ESS process for the object's definition (say, to reformat an unmodified buffer or to revert back to R's idea of the object's definition) pass a -prefix argument to 'ess-dump-object-into-edit-buffer' by typing 'C-u C-c -C-e C-d'. +prefix argument to ‘ess-dump-object-into-edit-buffer’ by typing ‘C-u C-c +C-e C-d’.  File: ess.info, Node: Loading, Next: Error Checking, Prev: Edit buffer, Up: Editing objects @@ -2182,17 +2182,17 @@ File: ess.info, Node: Loading, Next: Error Checking, Prev: Edit buffer, Up: ============================================= The best way to get information -- particularly function definitions -- -into R is to load them in as source file, using R's 'source' function. -You have already seen how to create source files using 'C-c C-e C-d'; +into R is to load them in as source file, using R's ‘source’ function. +You have already seen how to create source files using ‘C-c C-e C-d’; ESS provides a complementary command for loading source files (even files not created with ESS!) into the ESS process, namely -'ess-load-file' ('C-c M-l'). *note Hot keys::. +‘ess-load-file’ (‘C-c M-l’). *note Hot keys::. -After typing 'C-c M-l' you will prompt for the name of the file to load +After typing ‘C-c M-l’ you will prompt for the name of the file to load into R; usually this is the current buffer's file which is the default -value (selected by simply pressing 'RET' at the prompt). You will be +value (selected by simply pressing ‘RET’ at the prompt). You will be asked to save the buffer first if it has been modified (this happens -automatically if the buffer was generated with 'C-c C-e C-d'). The file +automatically if the buffer was generated with ‘C-c C-e C-d’). The file will then be loaded, and if it loads successfully you will be returned to the ESS process. @@ -2202,20 +2202,20 @@ File: ess.info, Node: Error Checking, Next: Indenting, Prev: Loading, Up: Ed 7.3 Detecting errors in source files ==================================== -If any errors occur when loading a file with 'C-c C-l', ESS will inform +If any errors occur when loading a file with ‘C-c C-l’, ESS will inform you of this fact. In this case, you can jump directly to the line in -the source file which caused the error by typing 'C-c `' -('ess-parse-errors'). You will be returned to the offending file +the source file which caused the error by typing ‘C-c `’ +(‘ess-parse-errors’). You will be returned to the offending file (loading it into a buffer if necessary) with point at the line S reported as containing the error. You may then correct the error, and reload the file. Note that none of the commands in an R source file will take effect if any part of the file contains errors. Sometimes the error is not caused by a syntax error (loading a -non-existent file for example). In this case typing 'C-c `' will simply +non-existent file for example). In this case typing ‘C-c `’ will simply display a buffer containing S's error message. You can force this behavior (and avoid jumping to the file when there _is_ a syntax error) -by passing a prefix argument to 'ess-parse-errors' with 'C-u C-c `'. +by passing a prefix argument to ‘ess-parse-errors’ with ‘C-u C-c `’.  File: ess.info, Node: Indenting, Next: Other edit buffer commands, Prev: Error Checking, Up: Editing objects @@ -2224,27 +2224,27 @@ File: ess.info, Node: Indenting, Next: Other edit buffer commands, Prev: Erro =================================== ESS provides a sophisticated mechanism for indenting R source code. -Compound statements (delimited by '{' and '}') are indented relative to +Compound statements (delimited by ‘{’ and ‘}’) are indented relative to their enclosing block. In addition, the braces have been electrified to automatically indent to the correct position when inserted, and optionally insert a newline at the appropriate place as well. Lines which continue an incomplete expression are indented relative to the -first line of the expression. Function definitions, 'if' statements, -calls to 'expression()' and loop constructs are all recognized and +first line of the expression. Function definitions, ‘if’ statements, +calls to ‘expression()’ and loop constructs are all recognized and indented appropriately. User variables are provided to control the amount of indentation in each case, and there are also a number of predefined indentation styles to choose from. Comments are also handled specially by ESS, using an idea borrowed from the Emacs-Lisp indentation style. By default, comments beginning -with '###' are aligned to the beginning of the line. Comments beginning -with '##' are aligned to the current level of indentation for the block -containing the comment. Finally, comments beginning with '#' are +with ‘###’ are aligned to the beginning of the line. Comments beginning +with ‘##’ are aligned to the current level of indentation for the block +containing the comment. Finally, comments beginning with ‘#’ are aligned to a column on the right (the 40th column by default, but this -value is controlled by the variable 'comment-column',) or just after the +value is controlled by the variable ‘comment-column’,) or just after the expression on the line containing the comment if it extends beyond the indentation column. You turn off the default behavior by adding the -line '(setq ess-indent-with-fancy-comments nil)' to your '.emacs' file. +line ‘(setq ess-indent-with-fancy-comments nil)’ to your ‘.emacs’ file. ESS also supports roxygen2 entries which is R documentation maintained in the source code as comments *Note roxygen2::. @@ -2252,37 +2252,37 @@ maintained in the source code as comments *Note roxygen2::. The indentation commands provided by ESS are: -- Command: ess-indent-or-complete - 'TAB' Indents the current line as R code. + ‘TAB’ Indents the current line as R code. Try to indent first, and if code is already properly indented, complete instead. In ess-mode, only tries completion if - 'tab-always-indent' is ''complete'. See also - 'ess-first-tab-never-complete'. + ‘tab-always-indent’ is ‘'complete’. See also + ‘ess-first-tab-never-complete’. -- User Option: ess-first-tab-never-complete - If non-'nil', 'TAB' never tries to complete in ess-mode. The - default ''symbol' does not try to complete if the next char is a + If non-‘nil’, ‘TAB’ never tries to complete in ess-mode. The + default ‘'symbol’ does not try to complete if the next char is a valid symbol constituent. There are more options, see the help - ('C-h v'). + (‘C-h v’). -- Command: ess-indent-exp - 'TAB' Indents each line in the R (compound) expression which + ‘TAB’ Indents each line in the R (compound) expression which follows point. Very useful for beautifying your R code. -- Command: ess-electric-brace - '{' '}' The braces automatically indent to the correct position + ‘{’ ‘}’ The braces automatically indent to the correct position when typed. The following Emacs command are also helpful: -'RET' -'LFD' - 'newline-and-indent' Insert a newline, and indent the next line. +‘RET’ +‘LFD’ + ‘newline-and-indent’ Insert a newline, and indent the next line. (Note that most keyboards nowadays do not have a key, - but and 'C-j' are equivalent.) + but and ‘C-j’ are equivalent.) -'M-;' - 'indent-dwim' Call the comment command you want (Do What I Mean). +‘M-;’ + ‘indent-dwim’ Call the comment command you want (Do What I Mean). * Menu: @@ -2295,22 +2295,22 @@ File: ess.info, Node: Styles, Up: Indenting -------------------------------------------------------- The combined value of twelve variables (4 of three groups -'ess-indent-*', 'ess-offset-*' and 'ess-align-*') that control +‘ess-indent-*’, ‘ess-offset-*’ and ‘ess-align-*’) that control indentation are collectively termed a style. ESS provides several -styles covering the common styles of indentation: 'DEFAULT', 'OWN', -'GNU', 'BSD', 'K&R', 'C++', 'RRR', 'RRR+', 'Rstudio', 'Rstudio-', and -'CLB'. The variable 'ess-style-alist' lists the value of each +styles covering the common styles of indentation: ‘DEFAULT’, ‘OWN’, +‘GNU’, ‘BSD’, ‘K&R’, ‘C++’, ‘RRR’, ‘RRR+’, ‘Rstudio’, ‘Rstudio-’, and +‘CLB’. The variable ‘ess-style-alist’ lists the value of each indentation variable per style (and its documentation contains more). -- Command: ess-set-style - 'C-c C-e C-s' (or 'C-c C-e s') sets the formatting style in this + ‘C-c C-e C-s’ (or ‘C-c C-e s’) sets the formatting style in this buffer to be one of the predefined styles, see above. The - 'DEFAULT' style uses the default values for the indenting - variables; The 'OWN' style allows you to use your own private + ‘DEFAULT’ style uses the default values for the indenting + variables; The ‘OWN’ style allows you to use your own private values of the indentation variable, see below. -- User Option: ess-style - The style to use. See the variable 'ess-style-alist' for how these + The style to use. See the variable ‘ess-style-alist’ for how these groups (DEFAULT, OWN, GNU, RRR, ...) map onto different settings for variables. You can set this in your Emacs configuration file: @@ -2319,12 +2319,12 @@ indentation variable per style (and its documentation contains more). -- User Option: ess-style-alist Predefined formatting styles for ESS code. Values for all groups, except OWN, are fixed. To change the value of variables in the OWN - group, customize the variable 'ess-own-style-list'. The default - style in use is controlled by 'ess-style'. + group, customize the variable ‘ess-own-style-list’. The default + style in use is controlled by ‘ess-style’. - The styles 'DEFAULT' and 'OWN' are initially identical. If you wish -to edit some of the default values, set 'ess-style' to ''OWN' and change -'ess-own-style-list'. *Note Customization::, for convenient ways to set + The styles ‘DEFAULT’ and ‘OWN’ are initially identical. If you wish +to edit some of the default values, set ‘ess-style’ to ‘'OWN’ and change +‘ess-own-style-list’. *Note Customization::, for convenient ways to set both these variables. If you prefer not to use the customization facility, you can change @@ -2335,10 +2335,10 @@ individual indentation variables within a hook, for example: (add-hook 'ess-mode-hook 'myindent-ess-hook) In the rare case that you'd like to add an entire new indentation -style of your own, copy the definition of 'ess-own-style-list' to a new -variable and ensure that the last line of the ':set' declaration calls -'ess-add-style' with a unique name for your style (e.g. ''MINE'). -Finally, add '(setq ess-style 'MINE)' to use your new style. +style of your own, copy the definition of ‘ess-own-style-list’ to a new +variable and ensure that the last line of the ‘:set’ declaration calls +‘ess-add-style’ with a unique name for your style (e.g. ‘'MINE’). +Finally, add ‘(setq ess-style 'MINE)’ to use your new style.  File: ess.info, Node: Other edit buffer commands, Next: Source Files, Prev: Indenting, Up: Editing objects @@ -2350,15 +2350,15 @@ A number of commands are provided to move across function definitions in the edit buffer: -- Command: ess-goto-beginning-of-function-or-para - 'ESC C-a' aka 'C-M-a' If inside a function go to the beginning of + ‘ESC C-a’ aka ‘C-M-a’ If inside a function go to the beginning of it, otherwise go to the beginning of paragraph. -- Command: ess-goto-end-of-function-or-para - 'ESC C-e' aka 'C-M-e' Move point to the end of the function + ‘ESC C-e’ aka ‘C-M-e’ Move point to the end of the function containing point. -- Command: ess-mark-function - 'ESC C-h' aka 'C-M-h' Place point at the beginning of the R + ‘ESC C-h’ aka ‘C-M-h’ Place point at the beginning of the R function containing point, and mark at the end. Don't forget the usual Emacs commands for moving over balanced @@ -2366,17 +2366,17 @@ expressions and parentheses: *Note Lists and Sexps: (Emacs)Lists. Completion is provided in the edit buffer in a similar fashion to the process buffer: first indents, and if there is nothing to indent, -completes the object or file name; 'M-?' lists file completions. See +completes the object or file name; ‘M-?’ lists file completions. See *Note Completion::, for more. - Finally, 'C-c C-z' ('ess-switch-to-inferior-or-script-buffer') -returns you to the 'iESS' process buffer, if done from a script buffer, -placing point at the end of the buffer. If this is done from the 'iESS' + Finally, ‘C-c C-z’ (‘ess-switch-to-inferior-or-script-buffer’) +returns you to the ‘iESS’ process buffer, if done from a script buffer, +placing point at the end of the buffer. If this is done from the ‘iESS’ process buffer, point is taken to the script buffer. In addition many commands available in the process buffer are also -available in the script buffer. You can still read help files with 'C-c -C-v', edit another function with 'C-c C-e C-d' and of course 'C-c C-l' +available in the script buffer. You can still read help files with ‘C-c +C-v’, edit another function with ‘C-c C-e C-d’ and of course ‘C-c C-l’ can be used to load a source file into R.  @@ -2385,14 +2385,14 @@ File: ess.info, Node: Source Files, Next: Source Directories, Prev: Other edi 7.6 Maintaining R source files ============================== -Every edit buffer in ESS is associated with a "dump file" on disk. Dump -files are created whenever you type 'C-c C-e C-d' -('ess-dump-object-into-edit-buffer'), and may either be deleted after +Every edit buffer in ESS is associated with a “dump file” on disk. Dump +files are created whenever you type ‘C-c C-e C-d’ +(‘ess-dump-object-into-edit-buffer’), and may either be deleted after use, or kept as a backup file or as a means of keeping several versions of an R function. -- User Option: ess-delete-dump-files - If non-'nil', dump files created with C-c C-e C-d are deleted + If non-‘nil’, dump files created with C-c C-e C-d are deleted immediately after they are created by the ess-process. Since immediately after R dumps an object's definition to a disk file @@ -2401,26 +2401,26 @@ definition, the disk file isn't needed; deleting it now has the advantage that if you _don't_ modify the file (say, because you just wanted to look at the definition of one of the standard R functions) the source dump file won't be left around when you kill the buffer. Note -that this variable only applies to files generated with R's 'dump' +that this variable only applies to files generated with R's ‘dump’ function; it doesn't apply to source files which already exist. The -default value is 't'. +default value is ‘t’. -- User Option: ess-keep-dump-files Variable controlling whether to delete dump files after a - successful load. If 'nil': always delete. If 'ask', confirm to - delete. If 'check', confirm to delete, except for files created - with 'ess-dump-object-into-edit-buffer'. Anything else, never + successful load. If ‘nil’: always delete. If ‘ask’, confirm to + delete. If ‘check’, confirm to delete, except for files created + with ‘ess-dump-object-into-edit-buffer’. Anything else, never delete. This variable only affects the behaviour of - 'ess-load-file'. Dump files are never deleted if an error occurs + ‘ess-load-file’. Dump files are never deleted if an error occurs during the load. After an object has been successfully (without error) loaded back -into R with 'C-c C-l', the disk file again corresponds exactly (well, +into R with ‘C-c C-l’, the disk file again corresponds exactly (well, almost -- see below) to R's record of the object's definition, and so some people prefer to delete the disk file rather than unnecessarily use up space. This option allows you to do just that. - If the value of 'ess-keep-dump-files' is 't', dump files are never + If the value of ‘ess-keep-dump-files’ is ‘t’, dump files are never deleted after they are loaded. Thus you can maintain a complete text record of the functions you have edited within ESS. Backup files are kept as usual, and so by using the Emacs numbered backup facility -- @@ -2429,7 +2429,7 @@ historic record of function definitions. Another possibility is to maintain the files with a version-control system such as git *Note Version Control: (emacs)Version Control. As long as a dump file exists in the appropriate place for a particular object, editing that object -with 'C-c C-e C-d' finds that file for editing (unless a prefix argument +with ‘C-c C-e C-d’ finds that file for editing (unless a prefix argument is given) -- the ESS process is not consulted. Thus you can keep comments _outside_ the function definition as a means of documentation that does not clutter the R object itself. Another useful feature is @@ -2437,33 +2437,33 @@ that you may format the code in any fashion you please without R re-indenting the code every time you edit it. These features are particularly useful for project-based work. - If the value of 'ess-keep-dump-files' is nil, the dump file is always -silently deleted after a successful load with 'C-c C-l'. While this is -useful for files that were created with 'C-c C-e C-d' it also applies to + If the value of ‘ess-keep-dump-files’ is nil, the dump file is always +silently deleted after a successful load with ‘C-c C-l’. While this is +useful for files that were created with ‘C-c C-e C-d’ it also applies to any other file you load (say, a source file of function definitions), and so can be dangerous to use unless you are careful. Note that since -'ess-keep-dump-files' is buffer-local, you can make sure particular -files are not deleted by setting it to 't' in the Local Variables +‘ess-keep-dump-files’ is buffer-local, you can make sure particular +files are not deleted by setting it to ‘t’ in the Local Variables section of the file *Note Local Variables in Files: (emacs)File Variables. - A safer option is to set 'ess-keep-dump-files' to 'ask'; this means + A safer option is to set ‘ess-keep-dump-files’ to ‘ask’; this means that ESS will always ask for confirmation before deleting the file. Since this can get annoying if you always want to delete dump files -created with 'C-c C-e C-d', but not any other files, setting -'ess-keep-dump-files' to 'check' (the default value) will silently -delete dump files created with 'C-c C-e C-d' in the current Emacs +created with ‘C-c C-e C-d’, but not any other files, setting +‘ess-keep-dump-files’ to ‘check’ (the default value) will silently +delete dump files created with ‘C-c C-e C-d’ in the current Emacs session, but query for any other file. Note that in any case you will only be asked for confirmation once per file, and your answer is remembered for the rest of the Emacs session. Note that in all cases, if an error (such as a syntax error) is -detected while loading the file with 'C-c C-l', the dump file is _never_ +detected while loading the file with ‘C-c C-l’, the dump file is _never_ deleted. This is so that you can edit the file in a new Emacs session if you happen to quit Emacs before correcting the error. Dump buffers are always autosaved, regardless of the value of -'ess-keep-dump-files'. +‘ess-keep-dump-files’.  File: ess.info, Node: Source Directories, Prev: Source Files, Up: Editing objects @@ -2475,14 +2475,14 @@ Every dump file should be given a unique file name, usually the dumped object name with some additions. -- User Option: ess-dump-filename-template - Template for filenames of dumped objects. '%s' is replaced by the + Template for filenames of dumped objects. ‘%s’ is replaced by the object name. -By default, dump file names are the user name, followed by '.' and the -object and ending with '.R'. Thus if user 'joe' dumps the object -'myfun' the dump file will have name 'joe.myfun.R'. The username part +By default, dump file names are the user name, followed by ‘.’ and the +object and ending with ‘.R’. Thus if user ‘joe’ dumps the object +‘myfun’ the dump file will have name ‘joe.myfun.R’. The username part is included to avoid clashes when dumping into a publicly-writable -directory, such as '/tmp'; you may wish to remove this part if you are +directory, such as ‘/tmp’; you may wish to remove this part if you are dumping into a directory owned by you. You may also specify the directory in which dump files are written: @@ -2491,29 +2491,29 @@ dumping into a directory owned by you. Directory name (ending in a slash) where R dump files are to be written. - By default, dump files are always written to '/tmp', which is fine -when 'ess-keep-dump-files' is 'nil'. If you are keeping dump files, + By default, dump files are always written to ‘/tmp’, which is fine +when ‘ess-keep-dump-files’ is ‘nil’. If you are keeping dump files, then you will probably want to keep them somewhere in your home -directory, say '~/R-source'. This could be achieved by including the +directory, say ‘~/R-source’. This could be achieved by including the following line in your Emacs configuration file: (setq ess-source-directory (expand-file-name "~/R-source/")) If you would prefer to keep your dump files in separate directories depending on the value of some variable, ESS provides a facility for -this also. By setting 'ess-source-directory' to a lambda expression +this also. By setting ‘ess-source-directory’ to a lambda expression which evaluates to a directory name, you have a great deal of flexibility in selecting the directory for a particular source file to appear in. The lambda expression is evaluated with the process buffer as the current buffer and so you can use the variables local to that buffer to make your choice. For example, the following expression -causes source files to be saved in the subdirectory 'Src' of the +causes source files to be saved in the subdirectory ‘Src’ of the directory the ESS process was run in. (setq ess-source-directory (lambda () (concat ess-directory "Src/"))) -('ess-directory' is a buffer-local variable in process buffers which +(‘ess-directory’ is a buffer-local variable in process buffers which records the directory the ESS process was run from.) This is useful if you keep your dump files and you often edit objects with the same name in different ESS processes. Alternatively, if you often change your R @@ -2541,141 +2541,141 @@ File: ess.info, Node: Help, Next: Completion, Prev: Editing objects, Up: Top ESS provides an easy-to-use facility for reading R help files from within Emacs. From within the ESS process buffer or any ESS edit -buffer, typing 'C-c C-v' ('ess-display-help-on-object') will prompt you +buffer, typing ‘C-c C-v’ (‘ess-display-help-on-object’) will prompt you for the name of an object for which you would like documentation. Completion is provided over all objects which have help files. If the requested object has documentation, you will be popped into a -buffer (named '*help(OBJ-NAME)*') containing the help file. This buffer +buffer (named ‘*help(OBJ-NAME)*’) containing the help file. This buffer is placed in a special ESS help mode which disables the usual editing commands but which provides a number of keys for paging through the help file. Help commands: -'?' - 'ess-describe-help-mode' Pops up a help buffer with a list of the +‘?’ + ‘ess-describe-help-mode’ Pops up a help buffer with a list of the commands available in R help mode. -'h' - 'ess-display-help-on-object' Pop up a help buffer for a different +‘h’ + ‘ess-display-help-on-object’ Pop up a help buffer for a different object. Paging commands: -'DEL' - 'scroll-down-command' Move one screen backwards through the help +‘DEL’ + ‘scroll-down-command’ Move one screen backwards through the help file. -'SPC' - 'scroll-up-command' Move one screen forwards through the help file. +‘SPC’ + ‘scroll-up-command’ Move one screen forwards through the help file. -'>' -'<' - 'end/beginning-of-buffer' Move to the end or beginning of the help +‘>’ +‘<’ + ‘end/beginning-of-buffer’ Move to the end or beginning of the help file, respectively. Section-based motion commands: -'n' -'p' - 'ess-skip-to-previous-section' and 'ess-skip-to-next-section' Move +‘n’ +‘p’ + ‘ess-skip-to-previous-section’ and ‘ess-skip-to-next-section’ Move to the next and previous section header in the help file, respectively. A section header consists of a number of capitalized words, followed by a colon. - In addition, the 's' key followed by one of the following letters + In addition, the ‘s’ key followed by one of the following letters will jump to a particular section in the help file. Note that the exact headings available and capitalization scheme may vary across languages. - You may use 's ?' to get the current list of active key bindings. + You may use ‘s ?’ to get the current list of active key bindings. -'a' +‘a’ Arguments: -'b' +‘b’ Background: -'B' +‘B’ Bugs: -'d' +‘d’ Description: -'D' +‘D’ Details: -'e' +‘e’ Examples: -'n' +‘n’ Note: -'O' +‘O’ Optional Arguments: -'R' +‘R’ Required Arguments: -'r' +‘r’ References: -'s' +‘s’ See Also: -'S' +‘S’ Side Effects: -'u' +‘u’ Usage: -'v' +‘v’ Value: -'?' +‘?’ Pops up a help buffer with a list of the defined section motion keys. Evaluation: -'l' - 'ess-eval-line-and-step' Evaluates the current line in the ESS +‘l’ + ‘ess-eval-line-and-step’ Evaluates the current line in the ESS process, and moves to the next line. Useful for running examples in help files. -'r' - 'ess-eval-region' Send the contents of the current region to the +‘r’ + ‘ess-eval-region’ Send the contents of the current region to the ESS process. Useful for running examples in help files. Quit commands: -'q' - 'ess-help-quit' Return to previously selected buffer, and bury the +‘q’ + ‘ess-help-quit’ Return to previously selected buffer, and bury the help buffer. -'k' - 'kill-buffer' Return to previously selected buffer, and kills the +‘k’ + ‘kill-buffer’ Return to previously selected buffer, and kills the help buffer. -'x' - 'ess-kill-buffer-and-go' Return to the ESS process, killing this +‘x’ + ‘ess-kill-buffer-and-go’ Return to the ESS process, killing this help buffer. Miscellaneous: -'i' - 'ess-display-index' Prompt for a package and display it's help +‘i’ + ‘ess-display-index’ Prompt for a package and display it's help index. -'v' - 'ess-display-vignettes' Display all available vignettes. +‘v’ + ‘ess-display-vignettes’ Display all available vignettes. -'w' - 'ess-display-help-in-browser' Display current help page with the +‘w’ + ‘ess-display-help-in-browser’ Display current help page with the web browser. -'/' - 'isearch-forward' Same as 'C-s'. +‘/’ + ‘isearch-forward’ Same as ‘C-s’. In addition, all of the ESS commands available in the edit buffers are also available in R help mode (*note Edit buffer::). Of course, the @@ -2686,22 +2686,22 @@ the digits and <-> act as prefix arguments. requested, that buffer is popped to immediately; the ESS process is not consulted at all. If the contents of the help file have changed, you either need to kill the help buffer first, or pass a prefix argument -(with 'C-u') to 'ess-display-help-on-object'. +(with ‘C-u’) to ‘ess-display-help-on-object’. Help buffers are marked as temporary buffers in ESS, and are deleted -when 'ess-quit' or 'ess-cleanup' are called. +when ‘ess-quit’ or ‘ess-cleanup’ are called. Help buffers normally appear in another window within the current frame. If you wish help buffers to appear in their own frame (either one per help buffer, or one for all help buffers), you can customize the -variable 'ess-help-own-frame'. +variable ‘ess-help-own-frame’. Help buffers are displayed by calling the function -'ess-display-help'. You can customize where these buffers are displayed -by adding an entry in 'display-buffer-alist'; for examples, see *Note +‘ess-display-help’. You can customize where these buffers are displayed +by adding an entry in ‘display-buffer-alist’; for examples, see *Note (ess)Controlling buffer display::. Or by customizing the options -'ess-help-own-frame', 'ess-help-frame-alist', and -'ess-display-buffer-reuse-frame'. +‘ess-help-own-frame’, ‘ess-help-frame-alist’, and +‘ess-display-buffer-reuse-frame’.  File: ess.info, Node: Completion, Next: Developing with ESS, Prev: Help, Up: Top @@ -2724,40 +2724,40 @@ File: ess.info, Node: Object names, Next: Function arguments, Up: Completion ============================== The key is for completion. The value of the variable -'ess-first-tab-never-complete' controls when completion is allowed to -occur. In 'ess-mode' first tries to indent, and if there is +‘ess-first-tab-never-complete’ controls when completion is allowed to +occur. In ‘ess-mode’ first tries to indent, and if there is nothing to indent, complete the object name instead. -'TAB' - 'comint-dynamic-complete' Complete the R object name or filename +‘TAB’ + ‘comint-dynamic-complete’ Complete the R object name or filename before point. When the cursor is just after a partially-completed object name, pressing provides completion in a similar fashion to the rest of Emacs. ESS maintains a list of all objects known to R at any given time, which basically consists of all objects (functions and datasets) -in every attached directory listed by the 'search()' command along with +in every attached directory listed by the ‘search()’ command along with the component objects of attached data frames - For example, consider three functions 'binomplot()', 'binom.test()' -and 'binomial()'. Typing 'bin TAB' will insert the characters 'om', -completing the longest prefix ('binom') which distinguishes these three -commands. Pressing 'TAB' once more provides a list of the three + For example, consider three functions ‘binomplot()’, ‘binom.test()’ +and ‘binomial()’. Typing ‘bin TAB’ will insert the characters ‘om’, +completing the longest prefix (‘binom’) which distinguishes these three +commands. Pressing ‘TAB’ once more provides a list of the three commands which have this prefix, allowing you to add more characters -(say, '.') which specify the function you desire. After entering more -characters pressing 'TAB' yet again will complete the object name up to +(say, ‘.’) which specify the function you desire. After entering more +characters pressing ‘TAB’ yet again will complete the object name up to uniqueness, etc. If you just wish to see what completions exist without -adding any extra characters, type 'M-?'. +adding any extra characters, type ‘M-?’. -- Command: ess-complete-object-name - 'M-?' List all possible completions of the object name at point. + ‘M-?’ List all possible completions of the object name at point. ESS also provides completion over the components of named lists and -environments (after '$'), S4 classes slots (after @), package and +environments (after ‘$’), S4 classes slots (after @), package and namespace objects (after :: and :::). Completion is also provided over file names, which is particularly -useful when using R functions such as 'get()' or 'scan()' which require +useful when using R functions such as ‘get()’ or ‘scan()’ which require fully expanded file names. In the iESS buffer, if the cursor is not in a string and does not @@ -2769,7 +2769,7 @@ currently known to R; when a new object becomes available or is deleted, only one component of the cache corresponding to the associated directory needs to be refreshed. If ESS ever becomes confused about what objects are available for completion (such as when if refuses to -complete an object you *know* is there), the command 'M-x ess-resynch' +complete an object you *know* is there), the command ‘M-x ess-resynch’ forces the _entire_ cache to be refreshed, which should fix the problem.  @@ -2778,16 +2778,16 @@ File: ess.info, Node: Function arguments, Next: Minibuffer completion, Prev: 9.2 Completion of function arguments ==================================== -When inside a function call (i.e. following ''(''), 'TAB' completion +When inside a function call (i.e. following '‘(’'), ‘TAB’ completion also provides function arguments. If function is a generic, completion -will provide all the arguments of 'S3' methods known to 'R'. +will provide all the arguments of ‘S3’ methods known to ‘R’. In R versions newer than 2.14.1, ESS uses R's built-in completion engine and will honor its settings. You may read about them by issuing -'?rc.options' at the prompt. For example, to have the equals sign for -function arguments contain spaces on both sides (e.g. 'lm(for)' -suggests 'formula = ' rather than 'formula='), you can adjust -'funarg.suffix': +‘?rc.options’ at the prompt. For example, to have the equals sign for +function arguments contain spaces on both sides (e.g. ‘lm(for)’ +suggests ‘formula = ’ rather than ‘formula=’), you can adjust +‘funarg.suffix’: utils::rc.options(funarg.suffix = " = ") @@ -2800,10 +2800,10 @@ File: ess.info, Node: Minibuffer completion, Next: Company, Prev: Function ar 9.3 Minibuffer completion ========================= -ESS uses 'IDO' mechanism (part of default Emacs) for minibuffer -completion if the 'ido' package is available and the value of -'ess-use-ido' it 't' (the default). The completion command -'ess-completing-read' falls back on classic 'completion-read' interface +ESS uses ‘IDO’ mechanism (part of default Emacs) for minibuffer +completion if the ‘ido’ package is available and the value of +‘ess-use-ido’ it ‘t’ (the default). The completion command +‘ess-completing-read’ falls back on classic ‘completion-read’ interface if this feature is not available for whatever reason.  @@ -2814,8 +2814,8 @@ File: ess.info, Node: Company, Next: Icicles, Prev: Minibuffer completion, U Another popular package for completion is company, short for complete anything. ESS provides support for company out-of-the-box. To disable -company support, set 'ess-use-company' to 'nil'. You can set it to -''script-only' to only activate company in R scripts. +company support, set ‘ess-use-company’ to ‘nil’. You can set it to +‘'script-only’ to only activate company in R scripts.  File: ess.info, Node: Icicles, Prev: Company, Up: Completion @@ -2825,11 +2825,11 @@ File: ess.info, Node: Icicles, Prev: Company, Up: Completion Another option for comprehensively handling completion in Emacs is via Icicles (). It allows users to -have completions shown temporarily in the standard '*Completions*' +have completions shown temporarily in the standard ‘*Completions*’ buffer, and interactively select completion candidates using several methods. As of version 2013.04.04, Icicles provides support for completion in ESS. Please consult Icicles documentation, which is easily -accessible via 'customize-group Icicles', for more details on +accessible via ‘customize-group Icicles’, for more details on installation and customization options. Once installed, Icicles can be activated by evaluating): @@ -2837,16 +2837,16 @@ installation and customization options. (require 'icicles) (icy-mode 1) - Icicles can be toggled by typing 'M-x icy'. + Icicles can be toggled by typing ‘M-x icy’. - When Icicles is on, 'TAB' offers completion, provided the conditions -determined by 'ess-first-tab-never-complete' allow it. Typing 'M-TAB' -will attempt completion regardless. Typing 'M-?' in 'ESS' or 'iESS' + When Icicles is on, ‘TAB’ offers completion, provided the conditions +determined by ‘ess-first-tab-never-complete’ allow it. Typing ‘M-TAB’ +will attempt completion regardless. Typing ‘M-?’ in ‘ESS’ or ‘iESS’ modes brings up the relevant completion candidates from which to choose. -Minibuffer input filters the available candidates. Use 'TAB' for prefix -completion or 'S-TAB' for substring or regexp completion. Use 'S-SPC' +Minibuffer input filters the available candidates. Use ‘TAB’ for prefix +completion or ‘S-TAB’ for substring or regexp completion. Use ‘S-SPC’ to match an additional pattern (repeatable). You can cycle among the -matching candidates, choosing with 'RET' or 'mouse-2'. +matching candidates, choosing with ‘RET’ or ‘mouse-2’.  File: ess.info, Node: Developing with ESS, Next: Extras, Prev: Completion, Up: Top @@ -2873,18 +2873,18 @@ File: ess.info, Node: ESS tracebug, Next: Editing documentation, Up: Developi * Getting started with tracebug:: Quick tutorial -ESS 'tracebug' offers visual debugging, interactive error navigation, +ESS ‘tracebug’ offers visual debugging, interactive error navigation, interactive backtrace, breakpoint manipulation, control over R error actions, watch window and interactive flagging/unflagging of functions for debugging. - 'ess-tracebug' is on by default. You can toggle it on and off with -'M-x' 'ess-tracebug'. To disable startup activation of 'ess-tracebug' -set 'ess-use-tracebug' to nil. + ‘ess-tracebug’ is on by default. You can toggle it on and off with +‘M-x’ ‘ess-tracebug’. To disable startup activation of ‘ess-tracebug’ +set ‘ess-use-tracebug’ to nil. - Tracebug functionality can be found on 'ess-dev-map', bound to 'C-c -C-t'. Additionally, when subprocess is in a debugging state -'ess-debug-minor-mode' is active and the following additional shortcuts + Tracebug functionality can be found on ‘ess-dev-map’, bound to ‘C-c +C-t’. Additionally, when subprocess is in a debugging state +‘ess-debug-minor-mode’ is active and the following additional shortcuts are available: * Interactive Debugging (`ess-debug-minor-mode-map'): @@ -2897,8 +2897,8 @@ are available: M-Q . Quit debugging . `ess-debug-command-quit' - These are all the tracebug commands defined in 'ess-dev-map' ('C-c -C-t ?' to show this table): + These are all the tracebug commands defined in ‘ess-dev-map’ (‘C-c +C-t ?’ to show this table): * Breakpoints (`ess-dev-map'): @@ -2935,7 +2935,7 @@ C-t ?' to show this table): To configure how electric watch window splits the display see -'ess-watch-width-threshold' and 'ess-watch-height-threshold' variables. +‘ess-watch-width-threshold’ and ‘ess-watch-height-threshold’ variables. _Note:_ Currently, ess-tracebug does not detect some of R's debug related messages in non-English locales. To set your R messages to @@ -2955,18 +2955,18 @@ test <- function(x){ mean(x), } - Evaluating the function (e.g. 'C-c C-c') results in an error about -an unexpected comma. You can use 'next-error' (bound by default to 'C-x -`', 'M-g n', and 'M-g M-n') to jump to the place where the error + Evaluating the function (e.g. ‘C-c C-c’) results in an error about +an unexpected comma. You can use ‘next-error’ (bound by default to ‘C-x +`’, ‘M-g n’, and ‘M-g M-n’) to jump to the place where the error occurred. Alternatively, use the mouse to click on the error to jump to where it occurred. - Correct the error by deleting the comma. Now put point on 'mean' and -set the breakpoint using 'C-c C-t b' ('ess-bp-set') and reevaluate the -function. Jump to the inferior buffer (possibly using 'C-c C-z') and -evaluate 'test(1:10)'. An interactive debug process starts, stopping at + Correct the error by deleting the comma. Now put point on ‘mean’ and +set the breakpoint using ‘C-c C-t b’ (‘ess-bp-set’) and reevaluate the +function. Jump to the inferior buffer (possibly using ‘C-c C-z’) and +evaluate ‘test(1:10)’. An interactive debug process starts, stopping at the breakpoint we just specified. Here you can debug your function -(what is 'x' at this point?). Use 'M-N' to continue. +(what is ‘x’ at this point?). Use ‘M-N’ to continue. Let's replace our test function with one slightly more complicated: @@ -2978,26 +2978,26 @@ test <- function(x){ } Try setting multiple breakpoints. You can unset a breakpoint by -killing it with 'C-c C-t k'. You can set conditional breakpoints too. -Try setting one by placing point on the line 'x <- x + 1' and doing 'C-c -C-t B'. ESS will ask for the condition. Let's set it to -'!is.numeric(x)'. After re-evaluating 'test', try calling 'test(1:100)' -and 'test('foo')'. +killing it with ‘C-c C-t k’. You can set conditional breakpoints too. +Try setting one by placing point on the line ‘x <- x + 1’ and doing ‘C-c +C-t B’. ESS will ask for the condition. Let's set it to +‘!is.numeric(x)’. After re-evaluating ‘test’, try calling ‘test(1:100)’ +and ‘test('foo')’. - You can remove all breakpoints with 'C-c C-t K'. + You can remove all breakpoints with ‘C-c C-t K’. You can flag a function for debugging (similar to calling -'debug(test)' at R's prompt) by doing 'C-c C-t d'. Try this yourself by -putting point over 'test' and doing 'C-c C-t d'. +‘debug(test)’ at R's prompt) by doing ‘C-c C-t d’. Try this yourself by +putting point over ‘test’ and doing ‘C-c C-t d’. - If an error occurs, you can get the complete call stack by doing 'C-c -`' or 'C-c C-t `' ('ess-show-traceback'). + If an error occurs, you can get the complete call stack by doing ‘C-c +`’ or ‘C-c C-t `’ (‘ess-show-traceback’). Tracebug also offers a watch window where you can watch values of -objects. Open it with 'C-c C-t w' ('ess-watch'). Initially you aren't -watching anything. Add something with 'a' (e.g. 'a test'). The watch +objects. Open it with ‘C-c C-t w’ (‘ess-watch’). Initially you aren't +watching anything. Add something with ‘a’ (e.g. ‘a test’). The watch window displays what the object is at any given time and automatically -updates. Quit the watch window with 'q'. +updates. Quit the watch window with ‘q’.  File: ess.info, Node: Editing documentation, Next: Namespaced Evaluation, Prev: ESS tracebug, Up: Developing with ESS @@ -3021,14 +3021,14 @@ File: ess.info, Node: R documentation files, Next: roxygen2, Up: Editing docu 10.2.1 Editing R documentation (Rd) files ----------------------------------------- -R objects are documented in files written in the "R documentation" +R objects are documented in files written in the “R documentation” ("Rd"), a simple markup language closely resembling (La)TeX, which can be processed into a variety of formats, including LaTeX, HTML, and plain text. Rd format is described in section "Rd format" of the "Writing R Extensions" manual in the R distribution. ESS has several features that facilitate editing Rd files. - Visiting an Rd file as characterized by its extension 'Rd' will + Visiting an Rd file as characterized by its extension ‘Rd’ will activate Rd Mode, which provides several facilities for making editing R documentation files more convenient, by helping with indentation, insertions, even doing some of the typing for you (with Abbrev Mode), @@ -3038,53 +3038,53 @@ Lock Mode). In Rd mode, the following special Emacs commands can be used in addition to the standard Emacs commands. -'C-h m' +‘C-h m’ Describe the features of Rd mode. -'LFD' -'RET' +‘LFD’ +‘RET’ Reindent the current line, insert a newline and indent the new line - ('reindent-then-newline-and-indent'). An abbrev before point is - expanded if 'abbrev-mode' is non-'nil'. + (‘reindent-then-newline-and-indent’). An abbrev before point is + expanded if ‘abbrev-mode’ is non-‘nil’. -'TAB' +‘TAB’ Indent current line based on its contents and on previous lines. - ('indent-according-to-mode'). + (‘indent-according-to-mode’). -'C-c C-e' +‘C-c C-e’ Insert a "skeleton" with Rd markup for at least all mandatory - entries in Rd files ('Rd-mode-insert-skeleton'). Note that many - users might prefer to use the R function 'prompt' on an existing R + entries in Rd files (‘Rd-mode-insert-skeleton’). Note that many + users might prefer to use the R function ‘prompt’ on an existing R object to generate a non-empty Rd "shell" documenting the object (which already has all information filled in which can be obtained from the object). -'C-c C-f' +‘C-c C-f’ Insert "font" specifiers for some of the Rd markup commands markup available for emphasizing or quoting text, including markup for - URLs and email addresses ('Rd-font'). 'C-c C-f' is only a prefix; - see e.g. 'C-c C-f TAB' for the available bindings. Note that + URLs and email addresses (‘Rd-font’). ‘C-c C-f’ is only a prefix; + see e.g. ‘C-c C-f TAB’ for the available bindings. Note that currently, not all of the Rd text markup as described in section - "Marking text" of "Writing R Extensions" can be accessed via 'C-c - C-f'. + "Marking text" of "Writing R Extensions" can be accessed via ‘C-c + C-f’. -'C-c C-j' - Insert a suitably indented '\item{' on the next line - ('Rd-mode-insert-item'). +‘C-c C-j’ + Insert a suitably indented ‘\item{’ on the next line + (‘Rd-mode-insert-item’). -'C-c C-p' +‘C-c C-p’ Preview a plain text version ("help file", *note Help::) generated - from the Rd file ('Rd-preview-help'). + from the Rd file (‘Rd-preview-help’). In addition, when editing Rd files one can interact with a running R process in a similar way as when editing R language files. For example, -'C-c C-v' provides access to on-line help, and 'C-c C-n' sends the +‘C-c C-v’ provides access to on-line help, and ‘C-c C-n’ sends the current line to the R process for evaluation. This interaction is -particularly useful when editing the examples in the Rd file. See 'C-h -m' for all available commands. +particularly useful when editing the examples in the Rd file. See ‘C-h +m’ for all available commands. Rd mode also provides access to abbreviations for most of the Rd -markup commands. Type 'M-x list-abbrevs' with Abbrev mode turned on to +markup commands. Type ‘M-x list-abbrevs’ with Abbrev mode turned on to list all available abbrevs. Note that all Rd abbrevs start with a grave accent. @@ -3099,7 +3099,7 @@ accent. -- User Option: Rd-to-help-command The shell command used for converting Rd source to help text. - Default is 'R CMD Rd2txt'. + Default is ‘R CMD Rd2txt’. To automatically turn on the abbrev and font-lock features of Rd mode, add the following lines to one of your Emacs startup files: @@ -3118,7 +3118,7 @@ File: ess.info, Node: roxygen2, Prev: R documentation files, Up: Editing docu The roxygen2 R package makes it possible to keep the intended contents for Rd files as structured comments in the R source files. roxygen2 can then parse R files and generate appropriate Rd files from these -comments, fill the usage fields as well as updating 'NAMESPACE' files. +comments, fill the usage fields as well as updating ‘NAMESPACE’ files. See the roxygen2 documentation found via for more information on its usage. An example of an roxygen2 entry for a simple R function can look like this: @@ -3133,7 +3133,7 @@ a simple R function can look like this: myfun <- function(me) cat("Hello", me, "\n") The entry is immediately preceding the object to document and all -lines start with the roxygen2 prefix string, in this case '##''. ESS +lines start with the roxygen2 prefix string, in this case ‘##'’. ESS provides support to edit these documentation entries by providing line filling, navigation, template generation etc. Syntax highlighting is provided. @@ -3142,76 +3142,76 @@ provided. "Ess Roxy". Customizations include the roxygen2 prefix, use of folding to toggle visibility of roxygen2 entries and the roxygen2 template. - All ESS roxygen2 support is defined in 'ess-roxy.el' which is loaded + All ESS roxygen2 support is defined in ‘ess-roxy.el’ which is loaded by default in ESS. The following special Emacs commands are provided. -- Command: ess-roxy-update-entry - 'C-c C-o C-o' Generate a roxygen2 template or update the parameter + ‘C-c C-o C-o’ Generate a roxygen2 template or update the parameter list in roxygen2 entry at point (or above the function at the point). Documented parameters that are not in the function are placed last in the list, parameters that are not documented and not in the definition are dropped. Parameter descriptions are filled - if 'ess-roxy-fill-param-p' is non-nil. + if ‘ess-roxy-fill-param-p’ is non-nil. -- Command: ess-roxy-toggle-roxy-region BEG END - 'C-c C-o C-c' Toggle the presence of the leading roxygen2 string on + ‘C-c C-o C-c’ Toggle the presence of the leading roxygen2 string on all lines in the marked region (between BEG and END. Convenient for transferring text to roxygen2 entries and to evaluate example fields. -- Command: ess-roxy-preview-Rd NAME-FILE - 'C-c C-o C-r' Use the attached R process to parse the entry at + ‘C-c C-o C-r’ Use the attached R process to parse the entry at point to obtain the Rd code. Convenient for previewing and checking syntax. When used with the prefix argument NAME-FILE, - i.e. 'C-u C-c C-e C-r', place the content in a buffer associated + i.e. ‘C-u C-c C-e C-r’, place the content in a buffer associated with a Rd file with the same name as the documentation. Requires the roxygen2 package to be installed. -- Command: ess-roxy-preview-HTML VISIT-INSTEAD-OF-OPEN - 'C-c C-o C-t' Use the attached R process to parse the entry at to + ‘C-c C-o C-t’ Use the attached R process to parse the entry at to generate HTML for the entry and open it in a browser. When used - with the prefix argument VISIT-INSTEAD-OF-OPEN, i.e. 'C-u C-c C-e - C-t', visit the generated HTML file instead. Requires the roxygen2 + with the prefix argument VISIT-INSTEAD-OF-OPEN, i.e. ‘C-u C-c C-e + C-t’, visit the generated HTML file instead. Requires the roxygen2 and tools packages to be installed. -- Command: ess-roxy-previous-entry - 'C-c C-o p' Go to start of the roxygen2 entry above point. + ‘C-c C-o p’ Go to start of the roxygen2 entry above point. -- Command: ess-roxy-next-entry - 'C-c C-o n' Go to end of the roxygen2 entry above point. + ‘C-c C-o n’ Go to end of the roxygen2 entry above point. -- Command: ess-roxy-hide-all - 'C-c C-o C-h' Use the hideshow mode to fold away the visibility of + ‘C-c C-o C-h’ Use the hideshow mode to fold away the visibility of all roxygen2 entries. Hide-show support must be enabled for this binding to get defined. ESS also advises the following standard editing functions in order to make roxygen2 editing more intuitive: -'TAB' - 'ess-R-complete-object-name' Complete roxygen2 tag at point. E.g. - doing 'TAB' when the point is at the end of '@par' completes to - '@param'. +‘TAB’ + ‘ess-R-complete-object-name’ Complete roxygen2 tag at point. E.g. + doing ‘TAB’ when the point is at the end of ‘@par’ completes to + ‘@param’. -'M-h' - 'mark-paragraph' If the transient mark mode is active, place mark +‘M-h’ + ‘mark-paragraph’ If the transient mark mode is active, place mark and point at start end end of the field at point and activate the mark. -'TAB' - 'ess-indent-command' If hide-show support is enabled, fold away the +‘TAB’ + ‘ess-indent-command’ If hide-show support is enabled, fold away the visibility of the roxygen2 entry at point. -'M-q' - 'fill-paragraph' Fill the roxygen2 field at point. +‘M-q’ + ‘fill-paragraph’ Fill the roxygen2 field at point. -'C-a' - 'ess-roxy-move-beginning-of-line' Move to the point directly to the +‘C-a’ + ‘ess-roxy-move-beginning-of-line’ Move to the point directly to the right of the roxygen2 start string. If already there, move to the beginning of the line. -'RET' - 'newline-and-indent' Insert a new line and the roxygen2 prefix +‘RET’ + ‘newline-and-indent’ Insert a new line and the roxygen2 prefix string.  @@ -3221,7 +3221,7 @@ File: ess.info, Node: Namespaced Evaluation, Prev: Editing documentation, Up: ========================== In non package files evaluation commands, *Note Evaluating code::, send -portions of the current buffer environment ('R_GlobalEnv'. When +portions of the current buffer environment (‘R_GlobalEnv’. When developing packages, ESS sends code to the corresponding package namespace and (for visible objects) into package environment (visible on search path). All objects that are assigned are displayed in the @@ -3246,11 +3246,11 @@ environment. See also . Occasionally you want to evaluate into a package from a non-package -file, or the other way around, evaluate into 'GlobalEnv' from inside a -package. In such cases 'C-c C-t C-s' is your friend. +file, or the other way around, evaluate into ‘GlobalEnv’ from inside a +package. In such cases ‘C-c C-t C-s’ is your friend. -- Command: ess-r-set-evaluation-env ARG - 'C-c C-t C-s' Set or unset the current evaluation environment (a + ‘C-c C-t C-s’ Set or unset the current evaluation environment (a package).  @@ -3282,33 +3282,33 @@ File: ess.info, Node: ESS ElDoc, Next: ESS Flymake, Up: Extras 11.1 ElDoc ========== -In 'ElDoc' mode, the echo area displays function's arguments at point. -ElDoc is active by default in 'ess-mode' and 'inferior-ess-mode' -buffers. To activate it only in 'ess-mode' buffers, place the following +In ‘ElDoc’ mode, the echo area displays function's arguments at point. +ElDoc is active by default in ‘ess-mode’ and ‘inferior-ess-mode’ +buffers. To activate it only in ‘ess-mode’ buffers, place the following into your init file: (setq ess-use-eldoc 'script-only) -- User Option: ess-use-eldoc - If 't', activate eldoc in ess-mode and inferior-ess-mode buffers. - If ''script-only' activate in ess-mode buffers only. Set - 'ess-use-eldoc' to 'nil' to stop using 'ElDoc' altogether. + If ‘t’, activate eldoc in ess-mode and inferior-ess-mode buffers. + If ‘'script-only’ activate in ess-mode buffers only. Set + ‘ess-use-eldoc’ to ‘nil’ to stop using ‘ElDoc’ altogether. -- User Option: ess-eldoc-show-on-symbol This variable controls whether the help is shown only inside - function calls. If set to 't', 'ElDoc' shows help string whenever + function calls. If set to ‘t’, ‘ElDoc’ shows help string whenever the point is on a symbol, otherwise (the default), shows only when - the point is in a function call, i.e. after ''(''. + the point is in a function call, i.e. after ‘'('’. -- User Option: ess-eldoc-abbreviation-style The variable determines how the doc string should be abbreviated to - fit into minibuffer. Posible values are 'nil', 'mild', 'normal', - 'strong' and 'aggressive'. Please see the documentation of the - variable for more details. The default filter is 'normal'. + fit into minibuffer. Posible values are ‘nil’, ‘mild’, ‘normal’, + ‘strong’ and ‘aggressive’. Please see the documentation of the + variable for more details. The default filter is ‘normal’. - Ess-eldoc also honors the value of 'eldoc-echo-area-use-multiline-p', -which if set to 'nil', will cause the truncation of doc string -indifferent of the value of 'ess-eldoc-abbreviation-style'. This way + Ess-eldoc also honors the value of ‘eldoc-echo-area-use-multiline-p’, +which if set to ‘nil’, will cause the truncation of doc string +indifferent of the value of ‘ess-eldoc-abbreviation-style’. This way you can combine different filter levels with the truncation.  @@ -3317,25 +3317,25 @@ File: ess.info, Node: ESS Flymake, Next: Handy commands, Prev: ESS ElDoc, Up 11.2 Flymake ============ -The minor mode 'flymake-mode' provides on-the-fly syntax checking. ESS +The minor mode ‘flymake-mode’ provides on-the-fly syntax checking. ESS provides support for flymake in R-mode in Emacs versions 26 and newer. -It is enabled by default, to disable it you may set 'ess-use-flymake' to -'nil'. In order to use it, you may need to install the 'lintr' R +It is enabled by default, to disable it you may set ‘ess-use-flymake’ to +‘nil’. In order to use it, you may need to install the ‘lintr’ R package, available from CRAN. -- User Option: ess-use-flymake - When non-nil, use flymake. If ''process', only use flymake when + When non-nil, use flymake. If ‘'process’, only use flymake when the buffer has an inferior process running. -- User Option: ess-r-flymake-linters This variable describes the linters to use. It can either be a string with an R expression to be used as-is or a list of strings - where each element is passed to 'lintr::with_defaults'. See the - help page for 'lintr::default_linters' for information on available + where each element is passed to ‘lintr::with_defaults’. See the + help page for ‘lintr::default_linters’ for information on available linters and their defaults. -- User Option: ess-r-flymake-lintr-cache - When 't' (the default), lintr uses a cache. Change to 'nil' to + When ‘t’ (the default), lintr uses a cache. Change to ‘nil’ to disable lintr's caching mechanism.  @@ -3345,40 +3345,40 @@ File: ess.info, Node: Handy commands, Next: Highlighting, Prev: ESS Flymake, =================== -- Command: ess-handy-commands - Request and execute a command from 'ess-handy-commands' list. + Request and execute a command from ‘ess-handy-commands’ list. -- User Option: ess-handy-commands An alist of custom ESS commands available for call by - 'ess-handy-commands' and 'ess-smart-comma' function. + ‘ess-handy-commands’ and ‘ess-smart-comma’ function. Currently contains: change-directory - 'ess-change-directory' + ‘ess-change-directory’ help-index - 'ess-display-index' + ‘ess-display-index’ help-object - 'ess-display-help-on-object' + ‘ess-display-help-on-object’ vignettes - 'ess-display-vignettes' + ‘ess-display-vignettes’ objects[ls] - 'ess-execute-objects' + ‘ess-execute-objects’ search - 'ess-execute-search' + ‘ess-execute-search’ set-width - 'ess-execute-screen-options' + ‘ess-execute-screen-options’ install.packages - 'ess-install.packages' + ‘ess-install.packages’ library - 'ess-library' + ‘ess-library’ setRepos - 'ess-setRepositories' + ‘ess-setRepositories’ sos - 'ess-sos' + ‘ess-sos’ - Handy commands: 'ess-library', 'ess-install.packages', etc - ask for -item with completion and execute the correspond command. 'ess-sos' is a -interface to 'findFn' function in package 'sos'. If package 'sos' is + Handy commands: ‘ess-library’, ‘ess-install.packages’, etc - ask for +item with completion and execute the correspond command. ‘ess-sos’ is a +interface to ‘findFn’ function in package ‘sos’. If package ‘sos’ is not found, ask user for interactive install.  @@ -3395,14 +3395,14 @@ you may modify if desired: -- User Option: inferior-R-font-lock-keywords Font-lock patterns for inferior *R* processes. (There is a - corresponding 'inferior-S-font-lock-keywords' for *S* processes.) + corresponding ‘inferior-S-font-lock-keywords’ for *S* processes.) The default value highlights prompts, inputs, assignments, output - messages, vector and matrix labels, and literals such as 'NA' and - 'TRUE'. + messages, vector and matrix labels, and literals such as ‘NA’ and + ‘TRUE’. -- User Option: ess-R-font-lock-keywords Font-lock patterns for ESS R programming mode. (There is a - corresponding 'ess-S-font-lock-keywords' for S buffers.) The + corresponding ‘ess-S-font-lock-keywords’ for S buffers.) The default value highlights function names, literals, assignments, source functions and reserved words. @@ -3443,18 +3443,18 @@ features for dealing with such plots.  File: ess.info, Node: printer, Next: X11, Up: Graphics -11.6.1 Using ESS with the 'printer()' driver +11.6.1 Using ESS with the ‘printer()’ driver -------------------------------------------- This is the simplest (and least desirable) method of using graphics -within ESS. S's 'printer()' device driver produces crude character based +within ESS. S's ‘printer()’ device driver produces crude character based plots which can be contained within the ESS process buffer itself. To start using character graphics, issue the S command printer(width=79) - (the 'width=79' argument prevents Emacs line-wrapping at column 80 on + (the ‘width=79’ argument prevents Emacs line-wrapping at column 80 on an 80-column terminal. Use a different value for a terminal with a different number of columns.) Plotting commands do not generate -graphics immediately, but are stored until the 'show()' command is +graphics immediately, but are stored until the ‘show()’ command is issued, which displays the current figure.  @@ -3499,8 +3499,8 @@ point of each function definition). Imenu works by searching your buffer for lines that match what ESS thinks is the beginning of a suitable entry, for example the beginning of a function definition. To examine the regular expression that ESS -uses, check the value of 'imenu-generic-expression'. This value is set -by various ESS variables such as 'ess-imenu-S-generic-expression'. +uses, check the value of ‘imenu-generic-expression’. This value is set +by various ESS variables such as ‘ess-imenu-S-generic-expression’.  File: ess.info, Node: Toolbar, Next: Xref, Prev: Imenu, Up: Extras @@ -3536,7 +3536,7 @@ plotting objects in your current R session. If you are used to using the dired (directory editor) facility in Emacs, this mode gives you similar functionality for R objects. - Start an R session with 'M-x R' and then store a few variables, such + Start an R session with ‘M-x R’ and then store a few variables, such as: s <- sin(seq(from=0, to=8*pi, length=100)) @@ -3544,7 +3544,7 @@ as: y <- rnorm(20) z <- TRUE - Then use 'M-x ess-rdired' to create a buffer listing the objects in + Then use ‘M-x ess-rdired’ to create a buffer listing the objects in your current environment and display it in a new window: mode length s numeric 100 @@ -3552,7 +3552,7 @@ your current environment and display it in a new window: y numeric 20 z logical 1 - Type 'C-h m' or '?' to get a list of the keybindings for this mode. + Type ‘C-h m’ or ‘?’ to get a list of the keybindings for this mode. For example, with your point on the line of a variable, 'p' will plot the object, 'v' will view it, and 'd' will mark the object for deletion ('x' will actually perform the deletion). @@ -3564,38 +3564,38 @@ File: ess.info, Node: Package listing, Next: Org, Prev: Rdired, Up: Extras ===================== ESS[R] provides several commands to list and manage packages and objects -under the 'C-c C-.' keymap: +under the ‘C-c C-.’ keymap: -- Command: ess-r-package-list-local-packages - 'C-c C-. l' List all packages in all available libraries. + ‘C-c C-. l’ List all packages in all available libraries. -- Command: ess-r-package-list-available-packages - 'C-c C-. r' List available packages from repositories listed by - 'getOptions(``repos'')' in the current R session. + ‘C-c C-. r’ List available packages from repositories listed by + ‘getOptions(``repos'')’ in the current R session. -- Command: ess-r-package-update-packages LIB REPOS - 'C-c C-. u' Update packages in a particular library LIB and + ‘C-c C-. u’ Update packages in a particular library LIB and repository REPOS. -- Command: ess-rutils-rm-all - 'C-c C-. m' Remove all R objects. + ‘C-c C-. m’ Remove all R objects. -- Command: ess-rutils-load-workspace - 'C-c C-. w' Load a workspace file into R. + ‘C-c C-. w’ Load a workspace file into R. -- Command: ess-rutils-save-workspace - 'C-c C-. s' Save a workspace file. + ‘C-c C-. s’ Save a workspace file. -- Command: ess-change-directory - 'C-c C-. d' Change the working directory for the current R session. + ‘C-c C-. d’ Change the working directory for the current R session. -- Command: ess-rutils-html-docs - 'C-c C-. H' Use 'browse-url' to navigate R html documentation. + ‘C-c C-. H’ Use ‘browse-url’ to navigate R html documentation. - Functions for listing objects and packages ('ess-rutils-local-pkgs', -'ess-rutils-repos-pkgs', and 'ess-rutils-objs') show results in a -separate buffer and window, in 'ess-rutils-mode', providing useful key -bindings in this mode (type '?' in this buffer for a description). + Functions for listing objects and packages (‘ess-rutils-local-pkgs’, +‘ess-rutils-repos-pkgs’, and ‘ess-rutils-objs’) show results in a +separate buffer and window, in ‘ess-rutils-mode’, providing useful key +bindings in this mode (type ‘?’ in this buffer for a description).  File: ess.info, Node: Org, Next: Sweave and AUCTeX, Prev: Package listing, Up: Extras @@ -3623,8 +3623,8 @@ File: ess.info, Node: Sweave and AUCTeX, Prev: Org, Up: Extras ========================================== Libraries for literate data analysis are obsolete and not loaded by -default. This includes 'ess-noweb', 'ess-swv', and related -functionality like 'Rnw-mode'. Users are encouraged to switch to one of +default. This includes ‘ess-noweb’, ‘ess-swv’, and related +functionality like ‘Rnw-mode’. Users are encouraged to switch to one of several other packages that deal with these modes. For example, polymode , , or markdown-mode with edit-indirect @@ -3636,41 +3636,41 @@ ess-noweb-mode for literate programming. When working on an Sweave document, the following key bindings are available: -- Command: ess-swv-weave CHOOSE - 'M-n s' Run Sweave on the current .Rnw file. If CHOOSE is - non-'nil', offer a menu of available weavers. + ‘M-n s’ Run Sweave on the current .Rnw file. If CHOOSE is + non-‘nil’, offer a menu of available weavers. -- Command: ess-swv-latex - 'M-n l' Run LaTeX after Sweave'ing. + ‘M-n l’ Run LaTeX after Sweave'ing. -- Command: ess-swv-PS - 'M-n p' Generate and display a postscript file after LaTeX'ing. + ‘M-n p’ Generate and display a postscript file after LaTeX'ing. -- Command: ess-swv-PDF PDFLATEX-CMD - 'M-n P' Generate and display a PDF file after LaTeX'ing. Optional + ‘M-n P’ Generate and display a PDF file after LaTeX'ing. Optional argument PDFLATEX-CMD is the command to use, which by default, is the command used to generate the PDF file is the first element of - 'ess-swv-pdflatex-commands'. + ‘ess-swv-pdflatex-commands’. -- User Option: ess-swv-pdflatex-commands - Commands used by 'ess-swv-PDF' to run a version of pdflatex; the + Commands used by ‘ess-swv-PDF’ to run a version of pdflatex; the first entry is the default command. - Sweave'ing with 'ess-swv-weave' starts an inferior-ESS process, if -one is not available. Other commands are available from the 'Sweaving, -Tangling, ...' submenu of the Noweb menu. + Sweave'ing with ‘ess-swv-weave’ starts an inferior-ESS process, if +one is not available. Other commands are available from the ‘Sweaving, +Tangling, ...’ submenu of the Noweb menu. AUCTeX () users may prefer to -set the variable 'ess-swv-plug-into-AUCTeX-p' (available from the "ESS +set the variable ‘ess-swv-plug-into-AUCTeX-p’ (available from the "ESS Sweave" customization group) to t. Alternatively, the same can be -achieved by activating the entry "AUCTeX Interface" from the 'Sweaving, -Tangling, ...' submenu, which toggles this variable on or off. When the +achieved by activating the entry "AUCTeX Interface" from the ‘Sweaving, +Tangling, ...’ submenu, which toggles this variable on or off. When the interface is activated, new entries for Sweave'ing and LaTeX'ing thereafter are available from AUCTeX's "Command" menu. Sweave'ing can, -thus, be done by 'C-c C-c Sweave RET' without an inferior-ESS process. -Similarly, LaTeX'ing can be done by 'C-c C-c LaTeXSweave RET'. In both -cases, the process can be monitored with 'C-c C-l' -('TeX-recenter-output-buffer'). Open the viewer with 'C-c C-v' -('TeX-view'), as usual in AUCTeX. +thus, be done by ‘C-c C-c Sweave RET’ without an inferior-ESS process. +Similarly, LaTeX'ing can be done by ‘C-c C-c LaTeXSweave RET’. In both +cases, the process can be monitored with ‘C-c C-l’ +(‘TeX-recenter-output-buffer’). Open the viewer with ‘C-c C-v’ +(‘TeX-view’), as usual in AUCTeX.  File: ess.info, Node: ESS for R, Next: ESS for SAS, Prev: Extras, Up: Top @@ -3693,7 +3693,7 @@ File: ess.info, Node: ESS(R)--Editing files, Next: iESS(R)--Inferior ESS proce ESS[R] mode should be automatically turned on when visiting a file ending with an R or S suffix (*.R, *.S, *.s, etc), which enables the -features discussed previously. Alternatively, type 'M-x R-mode' to put +features discussed previously. Alternatively, type ‘M-x R-mode’ to put the current buffer into R mode. However, one will have to start up an inferior process to take advantage of the interactive features. @@ -3716,43 +3716,43 @@ that you have access to each). In the case that you wish to pass command line arguments to the starting R process, call it with the universal prefix. To set command line arguments that apply to all future iESS sessions, set the variable -'inferior-R-args'. +‘inferior-R-args’. Note that R has some extremely useful command line arguments. For -example, '--vanilla' will ensure R starts up without loading in any init +example, ‘--vanilla’ will ensure R starts up without loading in any init files. If you have other versions of R or S available on the system, ESS is also able to start those versions. How this exactly works depend on which OS you are using (details below). The general principle, regardless of OS, is that ESS searches the paths listed in the variable -'exec-path' for R binaries. If ESS cannot find your R binaries, on Unix -you can change the Unix environment variable 'PATH', as this variable is -used to set 'exec-path'. +‘exec-path’ for R binaries. If ESS cannot find your R binaries, on Unix +you can change the Unix environment variable ‘PATH’, as this variable is +used to set ‘exec-path’. R on GNU/Linux systems and other Unix-like systems (macOS): If you -have "R-3.6.3" on your 'exec-path', it can be started using 'M-x -R-3.6.3'. By default, ESS will find versions of R beginning "R-1", +have "R-3.6.3" on your ‘exec-path’, it can be started using ‘M-x +R-3.6.3’. By default, ESS will find versions of R beginning "R-1", "R-2", ..., "R-7", "R-devel", or "R-patched". If your versions of R are called other names, consider renaming them with a symbolic link or -change the variable 'ess-r-runners-prefixes'. To see which functions -have been created for starting different versions of R, type 'M-x R-' +change the variable ‘ess-r-runners-prefixes’. To see which functions +have been created for starting different versions of R, type ‘M-x R-’ and then hit [Tab]. These other versions of R can also be started from the "ESS->Start Process->Other" menu. - R on Windows systems: If you have "rw1081" on your 'exec-path', it -can be started using 'M-x rw1081'. By default, ESS will find versions -of R located in directories parallel to the version of R in your 'PATH'. + R on Windows systems: If you have "rw1081" on your ‘exec-path’, it +can be started using ‘M-x rw1081’. By default, ESS will find versions +of R located in directories parallel to the version of R in your ‘PATH’. If your versions of R are called other names, you will need to change -the variable 'ess-rterm-versions'. To see which functions have been -created for starting different versions of R, type 'M-x rw' and then hit +the variable ‘ess-rterm-versions’. To see which functions have been +created for starting different versions of R, type ‘M-x rw’ and then hit [Tab]. These other versions of R can also be started from the "ESS->Start Process->Other" menu. Once ESS has found these extra versions of R, it will then create a -new function, called 'M-x run-ess-r-newest', which will call the newest +new function, called ‘M-x run-ess-r-newest’, which will call the newest version of R that it found. (ESS examines the date in the first line of -information from 'R --version' to determine which is newest.) +information from ‘R --version’ to determine which is newest.)  File: ess.info, Node: Philosophies for using ESS(R), Next: Example ESS usage, Prev: iESS(R)--Inferior ESS processes, Up: ESS for R @@ -3847,7 +3847,7 @@ File: ess.info, Node: ESS for SAS, Next: ESS for BUGS, Prev: ESS for R, Up: * ESS(SAS)--Graphics:: * ESS(SAS)--Windows:: ESS[SAS] was designed for use with SAS. It is descended from emacs -macros developed by John Sall for editing SAS programs and 'SAS-mode' by +macros developed by John Sall for editing SAS programs and ‘SAS-mode’ by Tom Cook. Those editing features and new advanced features are part of ESS[SAS]. The user interface of ESS[SAS] has similarities with ESS[S] and the SAS Display Manager. @@ -3859,7 +3859,7 @@ File: ess.info, Node: ESS(SAS)--Design philosophy, Next: ESS(SAS)--Editing fil =============================== ESS[SAS] was designed to aid the user in writing and maintaining SAS -programs, such as 'FOO.sas'. Both interactive and batch submission of +programs, such as ‘FOO.sas’. Both interactive and batch submission of SAS programs is supported. ESS[SAS] was written with two primary goals. @@ -3881,34 +3881,34 @@ File: ess.info, Node: ESS(SAS)--Editing files, Next: ESS(SAS)--TAB key, Prev: ESS[SAS] is the mode for editing SAS language files. This mode handles: - * proper indenting, generated by both and . - * color and font choices based on syntax. - * ability to save and submit the file you are working on as a batch + • proper indenting, generated by both and . + • color and font choices based on syntax. + • ability to save and submit the file you are working on as a batch SAS process with a single keypress and to continue editing while it is runs in the background. - * capability of killing the batch SAS process through the '*shell*' + • capability of killing the batch SAS process through the ‘*shell*’ buffer or allow the SAS process to keep on running after you exit emacs. - * single keypress navigation of '.sas', '.log' and '.lst' files - ('.log' and '.lst' files are refreshed with each keypress). - * ability to send the contents of an entire buffer, a highlighted + • single keypress navigation of ‘.sas’, ‘.log’ and ‘.lst’ files + (‘.log’ and ‘.lst’ files are refreshed with each keypress). + • ability to send the contents of an entire buffer, a highlighted region, or a single line to an interactive SAS process. - * ability to switch between processes which would be the target of + • ability to switch between processes which would be the target of the buffer (for the above). - ESS[SAS] is automatically turned on when editing a file with a '.sas' -suffix (or other extension, if specified via 'auto-mode-alist'). The + ESS[SAS] is automatically turned on when editing a file with a ‘.sas’ +suffix (or other extension, if specified via ‘auto-mode-alist’). The function keys can be enabled to use the same function keys that the SAS Display Manager does. The interactive capabilities of ESS require you -to start an inferior SAS process with 'M-x SAS' (*Note +to start an inferior SAS process with ‘M-x SAS’ (*Note iESS(SAS)--Interactive SAS processes::.) At this writing, the indenting and syntax highlighting are generally -correct. Known issues: for multiple line '*' or '%*' comments, only the -first line is highlighted; for '.log' files, only the first line of a -'NOTE:', 'WARNING:' or 'ERROR:' message is highlighted; unmatched -single/double quotes in 'CARDS' data lines are *NOT* ignored; in an -iterative 'DO' statement, 'TO' and 'BY' are not highlighted. +correct. Known issues: for multiple line ‘*’ or ‘%*’ comments, only the +first line is highlighted; for ‘.log’ files, only the first line of a +‘NOTE:’, ‘WARNING:’ or ‘ERROR:’ message is highlighted; unmatched +single/double quotes in ‘CARDS’ data lines are *NOT* ignored; in an +iterative ‘DO’ statement, ‘TO’ and ‘BY’ are not highlighted.  File: ess.info, Node: ESS(SAS)--TAB key, Next: ESS(SAS)--Batch SAS processes, Prev: ESS(SAS)--Editing files, Up: ESS for SAS @@ -3916,26 +3916,26 @@ File: ess.info, Node: ESS(SAS)--TAB key, Next: ESS(SAS)--Batch SAS processes, 13.3 ESS[SAS]- key ======================= -Two options. The key is bound by default to 'sas-indent-line'. -This function is used to syntactically indent SAS code so 'PROC' and -'RUN' are in the left margin, other statements are indented -'sas-indent-width' spaces from the margin, continuation lines are -indented 'sas-indent-width' spaces in from the beginning column of that +Two options. The key is bound by default to ‘sas-indent-line’. +This function is used to syntactically indent SAS code so ‘PROC’ and +‘RUN’ are in the left margin, other statements are indented +‘sas-indent-width’ spaces from the margin, continuation lines are +indented ‘sas-indent-width’ spaces in from the beginning column of that statement. This is the type of functionality that emacs provides in most programming language modes. This functionality is activated by placing the following line in your initialization file prior to a -'require'/'load': +‘require’/‘load’: (setq ess-sas-edit-keys-toggle nil) ESS provides an alternate behavior for that makes it behave as it does in SAS Display Manager, i.e. move the cursor to the next stop. -The alternate behavior also provides a "TAB" backwards, 'C-', that +The alternate behavior also provides a "TAB" backwards, ‘C-’, that moves the cursor to the stop to the left and deletes any characters between them. This functionality is obtained by placing the following -line in your initialization file prior to a 'require'/'load': +line in your initialization file prior to a ‘require’/‘load’: (setq ess-sas-edit-keys-toggle t) - Under the alternate behavior, is bound to 'M-x tab-to-tab-stop' -and the stops are defined by 'ess-sas-tab-stop-list'. + Under the alternate behavior, is bound to ‘M-x tab-to-tab-stop’ +and the stops are defined by ‘ess-sas-tab-stop-list’.  File: ess.info, Node: ESS(SAS)--Batch SAS processes, Next: ESS(SAS)--Function keys for batch processing, Prev: ESS(SAS)--TAB key, Up: ESS for SAS @@ -3944,38 +3944,38 @@ File: ess.info, Node: ESS(SAS)--Batch SAS processes, Next: ESS(SAS)--Function ================================= Submission of a SAS batch job is dependent on your environment. -'ess-sas-submit-method' is determined by your operating system and your -shell. It defaults to ''sh' unless you are running Windows or Mac -Classic. Under Windows, it will default to ''sh' if you are using a -UNIX-imitating shell; otherwise ''ms-dos' for an MS-DOS shell. On -macOS, it will default to ''sh', but under Mac Classic, it defaults to -''apple-script'. You will also set this to ''sh' if the SAS batch job +‘ess-sas-submit-method’ is determined by your operating system and your +shell. It defaults to ‘'sh’ unless you are running Windows or Mac +Classic. Under Windows, it will default to ‘'sh’ if you are using a +UNIX-imitating shell; otherwise ‘'ms-dos’ for an MS-DOS shell. On +macOS, it will default to ‘'sh’, but under Mac Classic, it defaults to +‘'apple-script’. You will also set this to ‘'sh’ if the SAS batch job needs to run on a remote machine rather than your local machine. This works transparently if you are editing the remote file via ange-ftp/EFS -or tramp. Note that 'ess-sas-shell-buffer-remote-init' is a Local -Variable that defaults to '"ssh"' which will be used to open the buffer +or tramp. Note that ‘ess-sas-shell-buffer-remote-init’ is a Local +Variable that defaults to ‘"ssh"’ which will be used to open the buffer on the remote host and it is assumed that no password is necessary, i.e. -you are using 'ssh-agent'/'ssh-add' or the equivalent (see the +you are using ‘ssh-agent’/‘ssh-add’ or the equivalent (see the discussion about Local Variables below if you need to change the default). However, if you are editing the file locally and transferring it back and forth with Kermit, you need some additional steps. First, start Kermit locally before remotely logging in. Open a local copy of the -file with the 'ess-kermit-prefix' character prepended (the default is -'"#"'). Execute the command 'M-x ess-kermit-get' which automatically +file with the ‘ess-kermit-prefix’ character prepended (the default is +‘"#"’). Execute the command ‘M-x ess-kermit-get’ which automatically brings the contents of the remote file into your local copy. If you -transfer files with Kermit manually in a '*shell*' buffer, then note -that the Kermit escape sequence is 'C-q C-\ c' rather than 'C-\ c' which +transfer files with Kermit manually in a ‘*shell*’ buffer, then note +that the Kermit escape sequence is ‘C-q C-\ c’ rather than ‘C-\ c’ which it would be in an ordinary terminal application, i.e. not in an emacs buffer. Lastly, note that the remote Kermit command is specified by -'ess-kermit-command'. +‘ess-kermit-command’. - The command used by the 'SUBMIT' function key ( or ) to + The command used by the ‘SUBMIT’ function key ( or ) to submit a batch SAS job, whether local or remote, is -'ess-sas-submit-command' which defaults to 'sas-program'. 'sas-program' -is '"invoke SAS using program file"' for Mac Classic and '"sas"' -otherwise. However, you may have to alter 'ess-sas-submit-command' for +‘ess-sas-submit-command’ which defaults to ‘sas-program’. ‘sas-program’ +is ‘"invoke SAS using program file"’ for Mac Classic and ‘"sas"’ +otherwise. However, you may have to alter ‘ess-sas-submit-command’ for a particular program, so it is defined as buffer-local. Conveniently, it can be set at the end of the program: endsas; @@ -3983,11 +3983,11 @@ it can be set at the end of the program: ess-sas-submit-command: "sas8" End: - The command line is also made of 'ess-sas-submit-pre-command', -'ess-sas-submit-post-command' and 'ess-sas-submit-command-options' (the + The command line is also made of ‘ess-sas-submit-pre-command’, +‘ess-sas-submit-post-command’ and ‘ess-sas-submit-command-options’ (the last of which is also buffer-local). Here are some examples for your -'~/.emacs' or '~/.emacs.d/init.el' file (you may also use -'M-x customize-variable'): +‘~/.emacs’ or ‘~/.emacs.d/init.el’ file (you may also use +‘M-x customize-variable’): ;'sh default (setq ess-sas-submit-pre-command "nohup") ;'sh default @@ -4009,33 +4009,33 @@ cases since the shell might not be ready to receive a command. This delay is currently set high enough so as not to be a problem. But, there may be cases when it needs to be set higher, or could be set much lower to speed things up. You can over-ride the default in your -'~/.emacs' or '~/.emacs.d/init.el' file by: +‘~/.emacs’ or ‘~/.emacs.d/init.el’ file by: (setq ess-sleep-for 0.2) - For example, '(setq ess-sas-global-unix-keys t)' keys shown, '(setq -ess-sas-global-pc-keys t)' in parentheses; ESS[SAS] function keys are + For example, ‘(setq ess-sas-global-unix-keys t)’ keys shown, ‘(setq +ess-sas-global-pc-keys t)’ in parentheses; ESS[SAS] function keys are presented in the next section. Open the file you want to work with -'C-x C-f foo.sas'. 'FOO.sas' will be in ESS[SAS] mode. Edit as +‘C-x C-f foo.sas’. ‘FOO.sas’ will be in ESS[SAS] mode. Edit as appropriate, then save and submit the batch SAS job. () - The job runs in the '*shell*' buffer while you continue to edit -'FOO.sas'. If 'ess-sas-submit-method' is ''sh', then the message buffer -will display the shell notification when the job is complete. The ''sh' + The job runs in the ‘*shell*’ buffer while you continue to edit +‘FOO.sas’. If ‘ess-sas-submit-method’ is ‘'sh’, then the message buffer +will display the shell notification when the job is complete. The ‘'sh’ setting also allows you to terminate the SAS batch job before it is finished. () - Terminating a SAS batch in the '*shell*' buffer. + Terminating a SAS batch in the ‘*shell*’ buffer. kill PID - You may want to visit the '.log' (whether the job is still running or -it is finished) and check for error messages. The '.log' will be + You may want to visit the ‘.log’ (whether the job is still running or +it is finished) and check for error messages. The ‘.log’ will be refreshed and you will be placed in it's buffer. You will be taken to the first error message, if any. () Goto the next error message, if any. () - Now, 'refresh' the '.lst' and go to it's buffer. + Now, ‘refresh’ the ‘.lst’ and go to it's buffer. () - If you wish to make changes, go to the '.sas' file with. + If you wish to make changes, go to the ‘.sas’ file with. () Make your editing changes and submit again. () @@ -4067,10 +4067,10 @@ in parentheses). b. The ESS[SAS] function key definitions can be active in all buffers (global: 4, 5) or limited (local: 2, 3) only to buffers with files that are associated with ESS[SAS] as specified in your - 'auto-mode-alist'. + ‘auto-mode-alist’. The distinction between local and global is subtle. If you want the -ESS[SAS] definitions to work when you are in the '*shell*' buffer or +ESS[SAS] definitions to work when you are in the ‘*shell*’ buffer or when editing files other than the file extensions that ESS[SAS] recognizes, you will most likely want to use the global definitions. If you want your function keys to understand SAS batch commands when you @@ -4080,14 +4080,14 @@ the person installing ESS for a site or by an individual. a. For a site installation or an individual, place *ONLY ONE* of the following lines in your initialization file prior to a - 'require'/'load'. ESS[SAS] function keys are available in ESS[SAS] + ‘require’/‘load’. ESS[SAS] function keys are available in ESS[SAS] if you choose either 2 or 3 and in all modes if you choose 4 or 5: ;;2; (setq ess-sas-local-unix-keys t) ;;3; (setq ess-sas-local-pc-keys t) ;;4; (setq ess-sas-global-unix-keys t) ;;5; (setq ess-sas-global-pc-keys t) - The names '-unix-' and '-pc-' have nothing to do with the operating + The names ‘-unix-’ and ‘-pc-’ have nothing to do with the operating system that you are running. Rather, they mimic the definitions that the SAS Display Manager uses by default on those platforms. @@ -4101,109 +4101,109 @@ recognize some of the nicknames as SAS Display Manager commands (they are in all capitals). UNIX PC Nickname - 'refresh' + ‘refresh’ revert the current buffer with the file of the same name if the file is newer than the buffer - 'SUBMIT' - save the current '.sas' file (which is either the '.sas' file in the - current buffer or the '.sas' file associated with the '.lst' or '.log' + ‘SUBMIT’ + save the current ‘.sas’ file (which is either the ‘.sas’ file in the + current buffer or the ‘.sas’ file associated with the ‘.lst’ or ‘.log’ file in the current buffer) and submit the file as a batch SAS job - 'PROGRAM' - switch buffer to '.sas' file - 'LOG' - switch buffer to '.log' file, 'refresh' and goto next error message, if + ‘PROGRAM’ + switch buffer to ‘.sas’ file + ‘LOG’ + switch buffer to ‘.log’ file, ‘refresh’ and goto next error message, if any - 'OUTPUT' - switch buffer to '.lst' file and 'refresh' - 'filetype-1' - switch buffer to 'filetype-1' (defaults to '.txt') file and 'refresh' - 'shell' - switch buffer to '*shell*' - 'VIEWTABLE' - open an interactive 'PROC FSEDIT' session on the SAS dataset near point + ‘OUTPUT’ + switch buffer to ‘.lst’ file and ‘refresh’ + ‘filetype-1’ + switch buffer to ‘filetype-1’ (defaults to ‘.txt’) file and ‘refresh’ + ‘shell’ + switch buffer to ‘*shell*’ + ‘VIEWTABLE’ + open an interactive ‘PROC FSEDIT’ session on the SAS dataset near point toggle-log - toggle ESS[SAS] for '.log' files; useful for certain debugging situations - 'filetype-2' - switch buffer to 'filetype-2' (defaults to '.dat') file and 'refresh' + toggle ESS[SAS] for ‘.log’ files; useful for certain debugging situations + ‘filetype-2’ + switch buffer to ‘filetype-2’ (defaults to ‘.dat’) file and ‘refresh’ viewgraph - open a 'GSASFILE' near point for viewing either in emacs or with an + open a ‘GSASFILE’ near point for viewing either in emacs or with an external viewer -'C-' 'C-' rtf-portrait +‘C-’ ‘C-’ rtf-portrait create an MS RTF portrait file from the current buffer with a file - extension of '.rtf' -'C-' 'C-' rtf-landscape + extension of ‘.rtf’ +‘C-’ ‘C-’ rtf-landscape create an MS RTF landscape file from the current buffer with a file - extension of '.rtf' -'C-' 'C-' submit-region - write region to 'ess-temp.sas' and submit -'C-' 'C-' append-to-log - append 'ess-temp.log' to the current '.log' file -'C-' 'C-' append-to-output - append 'ess-temp.lst' to the current '.lst' file -'C-' 'C-' 'INSIGHT' - open an interactive 'PROC INSIGHT' session on the SAS dataset near point -'C-''C-'toggle-listing - toggle ESS[SAS] for '.lst' files; useful for toggling read-only + extension of ‘.rtf’ +‘C-’ ‘C-’ submit-region + write region to ‘ess-temp.sas’ and submit +‘C-’ ‘C-’ append-to-log + append ‘ess-temp.log’ to the current ‘.log’ file +‘C-’ ‘C-’ append-to-output + append ‘ess-temp.lst’ to the current ‘.lst’ file +‘C-’ ‘C-’ ‘INSIGHT’ + open an interactive ‘PROC INSIGHT’ session on the SAS dataset near point +‘C-’‘C-’toggle-listing + toggle ESS[SAS] for ‘.lst’ files; useful for toggling read-only - 'SUBMIT', 'PROGRAM', 'LOG' and 'OUTPUT' need no further explanation + ‘SUBMIT’, ‘PROGRAM’, ‘LOG’ and ‘OUTPUT’ need no further explanation since they mimic the SAS Display Manager commands and related function key definitions. However, six other keys have been provided for convenience and are described below. - 'shell' switches you to the '*shell*' buffer where you can interact + ‘shell’ switches you to the ‘*shell*’ buffer where you can interact with your operating system. This is especially helpful if you would like to kill a SAS batch job. You can specify a different buffer name -to associate with a SAS batch job (besides '*shell*') with the -buffer-local variable 'ess-sas-shell-buffer'. This allows you to have +to associate with a SAS batch job (besides ‘*shell*’) with the +buffer-local variable ‘ess-sas-shell-buffer’. This allows you to have multiple buffers running SAS batch jobs on multiple local/remote computers that may rely on different methods specified by the -buffer-local variable 'ess-sas-submit-method'. +buffer-local variable ‘ess-sas-submit-method’. - performs the 'refresh' operation on the current buffer. -'refresh' compares the buffer's last modified date/time with the file's + performs the ‘refresh’ operation on the current buffer. +‘refresh’ compares the buffer's last modified date/time with the file's last modified date/time and replaces the buffer with the file if the file is newer. This is the same operation that is automatically -performed when 'LOG', 'OUTPUT', 'filetype-1' or are pressed. +performed when ‘LOG’, ‘OUTPUT’, ‘filetype-1’ or are pressed. - 'filetype-1' switches you to a file with the same file name as your -'.sas' file, but with a different extension ('.txt' by default) and -performs 'refresh'. You can over-ride the default extension; for -example in your '~/.emacs' or '~/.emacs.d/init.el' file: + ‘filetype-1’ switches you to a file with the same file name as your +‘.sas’ file, but with a different extension (‘.txt’ by default) and +performs ‘refresh’. You can over-ride the default extension; for +example in your ‘~/.emacs’ or ‘~/.emacs.d/init.el’ file: (setq ess-sas-suffix-1 "csv") ; for example will prompt you for the name of a permanent SAS dataset near -point to be opened for viewing by 'PROC FSEDIT'. You can control the -SAS batch command-line with 'ess-sas-data-view-submit-options'. For +point to be opened for viewing by ‘PROC FSEDIT’. You can control the +SAS batch command-line with ‘ess-sas-data-view-submit-options’. For controlling the SAS batch commands, you have the global variables -'ess-sas-data-view-libname' and 'ess-sas-data-view-fsview-command' as -well as the buffer-local variable 'ess-sas-data-view-fsview-statement'. -If you have your SAS 'LIBNAME' defined in '~/autoexec.sas', then the +‘ess-sas-data-view-libname’ and ‘ess-sas-data-view-fsview-command’ as +well as the buffer-local variable ‘ess-sas-data-view-fsview-statement’. +If you have your SAS ‘LIBNAME’ defined in ‘~/autoexec.sas’, then the defaults for these variables should be sufficient. - Similarly, 'C-' will prompt you for the name of a permanent SAS -dataset near point to be opened for viewing by 'PROC INSIGHT'. You can + Similarly, ‘C-’ will prompt you for the name of a permanent SAS +dataset near point to be opened for viewing by ‘PROC INSIGHT’. You can control the SAS batch command-line with -'ess-sas-data-view-submit-options'. For controlling the SAS batch -commands, you have the global variables 'ess-sas-data-view-libname' and -'ess-sas-data-view-insight-command' as well as the buffer-local variable -'ess-sas-data-view-insight-statement'. +‘ess-sas-data-view-submit-options’. For controlling the SAS batch +commands, you have the global variables ‘ess-sas-data-view-libname’ and +‘ess-sas-data-view-insight-command’ as well as the buffer-local variable +‘ess-sas-data-view-insight-statement’. - toggles ESS[SAS] mode for '.log' files which is off by default -(technically, it is 'SAS-log-mode', but it looks the same). The syntax + toggles ESS[SAS] mode for ‘.log’ files which is off by default +(technically, it is ‘SAS-log-mode’, but it looks the same). The syntax highlighting can be helpful in certain debugging situations, but large -'.log' files may take a long time to highlight. +‘.log’ files may take a long time to highlight. - is the same as 'filetype-1' except it is '.dat' by default. + is the same as ‘filetype-1’ except it is ‘.dat’ by default. - will prompt you for the name of a 'GSASFILE' near the point in -'.log' to be opened for viewing either with emacs or with an external + will prompt you for the name of a ‘GSASFILE’ near the point in +‘.log’ to be opened for viewing either with emacs or with an external viewer. Depending on your version of emacs and the operating system you -are using, emacs may support '.gif' and '.jpg' files internally. You +are using, emacs may support ‘.gif’ and ‘.jpg’ files internally. You may need to change the following variables for your own situation. -'ess-sas-graph-view-suffix-regexp' is a regular expression of supported +‘ess-sas-graph-view-suffix-regexp’ is a regular expression of supported file types defined via file name extensions. -'ess-sas-graph-view-viewer-default' is the default external viewer for -your platform. 'ess-sas-graph-view-viewer-alist' is an alist of +‘ess-sas-graph-view-viewer-default’ is the default external viewer for +your platform. ‘ess-sas-graph-view-viewer-alist’ is an alist of exceptions to the default; i.e. file types and their associated viewers which will be used rather than the default viewer. (setq ess-sas-graph-view-suffix-regexp (concat "[.]\\([eE]?[pP][sS]\\|" @@ -4214,7 +4214,7 @@ which will be used rather than the default viewer. (setq ess-sas-graph-view-viewer-alist '(("[eE]?[pP][sS]" . "gv") ("[pP][dD][fF]" . "gv")) ;; default w/ gv - 'C-' produces US landscape by default, however, it can produce A4 + ‘C-’ produces US landscape by default, however, it can produce A4 landscape (first line for "global" key mapping, second for "local"): (global-set-key [(control f2)] 'ess-sas-rtf-a4-landscape) (define-key sas-mode-local-map [(control f2)] 'ess-sas-rtf-a4-landscape) @@ -4228,77 +4228,77 @@ File: ess.info, Node: iESS(SAS)--Interactive SAS processes, Next: iESS(SAS)--C Inferior ESS (iESS) is the method for interfacing with interactive statistical processes (programs). iESS[SAS] is what is needed for interactive SAS programming. iESS[SAS] works best with the SAS -command-line option settings '"-stdio -linesize 80 -noovp --nosyntaxcheck"' (the default of 'inferior-SAS-args'). +command-line option settings ‘"-stdio -linesize 80 -noovp +-nosyntaxcheck"’ (the default of ‘inferior-SAS-args’). - '-stdio' + ‘-stdio’ required to make the redirection of stdio work - '-linesize 80' + ‘-linesize 80’ keeps output lines from folding on standard terminals - '-noovp' + ‘-noovp’ prevents error messages from printing 3 times - '-nosyntaxcheck' + ‘-nosyntaxcheck’ permits recovery after syntax errors To start up iESS[SAS] mode, use: M-x SAS - The '*SAS:1.log*' buffer in 'ESStr' mode corresponds to the file -'FOO.log' in SAS batch usage and to the 'SAS: LOG' window in the SAS + The ‘*SAS:1.log*’ buffer in ‘ESStr’ mode corresponds to the file +‘FOO.log’ in SAS batch usage and to the ‘SAS: LOG’ window in the SAS Display Manager. All commands submitted to SAS, informative messages, warnings, and errors appear here. - The '*SAS:1.lst*' buffer in 'ESSlst' mode corresponds to the file -'FOO.lst' in SAS batch usage and to the 'SAS: OUTPUT' window in the SAS + The ‘*SAS:1.lst*’ buffer in ‘ESSlst’ mode corresponds to the file +‘FOO.lst’ in SAS batch usage and to the ‘SAS: OUTPUT’ window in the SAS Display Manager. All printed output appears in this window. - The '*SAS:1*' buffer exists solely as a communications buffer. The + The ‘*SAS:1*’ buffer exists solely as a communications buffer. The user should never use this buffer directly. Files are edited in the -'FOO.sas' buffer. The 'C-c C-r' key in ESS[SAS] is the functional -equivalent of bringing a file into the 'SAS: PROGRAM EDITOR' window -followed by 'SUBMIT'. +‘FOO.sas’ buffer. The ‘C-c C-r’ key in ESS[SAS] is the functional +equivalent of bringing a file into the ‘SAS: PROGRAM EDITOR’ window +followed by ‘SUBMIT’. For example, open the file you want to work with. C-x C-f foo.sas - 'FOO.sas' will be in ESS[SAS] mode. Edit as appropriate, and then -start up SAS with the cursor in the 'FOO.sas' buffer. + ‘FOO.sas’ will be in ESS[SAS] mode. Edit as appropriate, and then +start up SAS with the cursor in the ‘FOO.sas’ buffer. M-x SAS Four buffers will appear on screen: Buffer Mode Description -'FOO.sas' 'ESS[SAS]' your source file -'*SAS:1*' 'iESS[SAS:1]' iESS communication buffer -'*SAS:1.log*' 'Shell ESStr SAS log information - []' -'*SAS:1.lst*' 'Shell ESSlst SAS listing information - []' +‘FOO.sas’ ‘ESS[SAS]’ your source file +‘*SAS:1*’ ‘iESS[SAS:1]’ iESS communication buffer +‘*SAS:1.log*’ ‘Shell ESStr SAS log information + []’ +‘*SAS:1.lst*’ ‘Shell ESSlst SAS listing information + []’ If you would prefer each of the four buffers to appear in its own individual frame, you can arrange for that. Place the cursor in the -buffer displaying 'FOO.sas'. Enter the sequence 'C-c C-w'. The cursor -will normally be in buffer 'FOO.sas'. If not, put it there and -'C-x b FOO.sas'. +buffer displaying ‘FOO.sas’. Enter the sequence ‘C-c C-w’. The cursor +will normally be in buffer ‘FOO.sas’. If not, put it there and +‘C-x b FOO.sas’. Send regions, lines, or the entire file contents to SAS (regions are most useful: a highlighted region will normally begin with the keywords -'DATA' or 'PROC' and end with 'RUN;'), 'C-c C-r'. +‘DATA’ or ‘PROC’ and end with ‘RUN;’), ‘C-c C-r’. Information appears in the log buffer, analysis results in the listing buffer. In case of errors, make the corrections in the -'FOO.sas' buffer and resubmit with another 'C-c C-r'. +‘FOO.sas’ buffer and resubmit with another ‘C-c C-r’. At the end of the session you may save the log and listing buffers -with the usual 'C-x C-s' commands. You will be prompted for a file -name. Typically, the names 'FOO.log' and 'FOO.lst' will be used. You +with the usual ‘C-x C-s’ commands. You will be prompted for a file +name. Typically, the names ‘FOO.log’ and ‘FOO.lst’ will be used. You will almost certainly want to edit the saved files before including them in a report. The files are read-only by default. You can make them -writable by the emacs command 'C-x C-q'. +writable by the emacs command ‘C-x C-q’. - At the end of the session, the input file 'FOO.sas' will typically + At the end of the session, the input file ‘FOO.sas’ will typically have been revised. You can save it. It can be used later as the beginning of another iESS[SAS] session. It can also be used as a batch input file to SAS. - The '*SAS:1*' buffer is strictly for ESS use. The user should never -need to read it or write to it. Refer to the '.lst' and '.log' buffers + The ‘*SAS:1*’ buffer is strictly for ESS use. The user should never +need to read it or write to it. Refer to the ‘.lst’ and ‘.log’ buffers for monitoring output! Troubleshooting: *Note iESS(SAS)--Common problems::. @@ -4310,28 +4310,28 @@ File: ess.info, Node: iESS(SAS)--Common problems, Next: ESS(SAS)--Graphics, P ============================== 1. iESS[SAS] does not work on Windows. In order to run SAS inside an - emacs buffer, it is necessary to start SAS with the '-stdio' - option. SAS does not support the '-stdio' option on Windows. - 2. If 'M-x SAS' gives errors upon startup, check the following: - * you are running Windows: see 1. - * 'ess-sas-sh-command' (from the ESS 'etc' directory) needs to - be executable; too check, type 'M-x dired'; if not, fix it as - follows, type 'M-:', then at the minibuffer prompt 'Eval:', - type '(set-file-modes "ess-sas-sh-command" 493)'. - * 'sas' isn't in your executable path; to verify, type 'M-:' and - at the minibuffer prompt 'Eval:', type '(executable-find - "sas")' - 3. 'M-x SAS' starts SAS Display Manager. Probably, the command 'sas' + emacs buffer, it is necessary to start SAS with the ‘-stdio’ + option. SAS does not support the ‘-stdio’ option on Windows. + 2. If ‘M-x SAS’ gives errors upon startup, check the following: + • you are running Windows: see 1. + • ‘ess-sas-sh-command’ (from the ESS ‘etc’ directory) needs to + be executable; too check, type ‘M-x dired’; if not, fix it as + follows, type ‘M-:’, then at the minibuffer prompt ‘Eval:’, + type ‘(set-file-modes "ess-sas-sh-command" 493)’. + • ‘sas’ isn't in your executable path; to verify, type ‘M-:’ and + at the minibuffer prompt ‘Eval:’, type ‘(executable-find + "sas")’ + 3. ‘M-x SAS’ starts SAS Display Manager. Probably, the command ‘sas’ on your system calls a shell script. In that case you will need to - locate the real 'sas' executable and link to it. You can execute + locate the real ‘sas’ executable and link to it. You can execute the UNIX command: find / -name sas -print - Now place a soft link to the real 'sas' executable in your '~/bin' + Now place a soft link to the real ‘sas’ executable in your ‘~/bin’ directory, with for example cd ~/bin ln -s /usr/local/sas9/sas sas - Check your 'PATH' environment variable to confirm that '~/bin' -appears before the directory in which the 'sas' shell script appears. + Check your ‘PATH’ environment variable to confirm that ‘~/bin’ +appears before the directory in which the ‘sas’ shell script appears.  File: ess.info, Node: ESS(SAS)--Graphics, Next: ESS(SAS)--Windows, Prev: iESS(SAS)--Common problems, Up: ESS for SAS @@ -4339,14 +4339,14 @@ File: ess.info, Node: ESS(SAS)--Graphics, Next: ESS(SAS)--Windows, Prev: iESS 13.8 ESS[SAS]-Graphics ====================== -Output from a SAS/GRAPH 'PROC' can be displayed in a SAS/GRAPH window +Output from a SAS/GRAPH ‘PROC’ can be displayed in a SAS/GRAPH window for SAS batch on Windows or for both SAS batch and interactive with XWindows on UNIX. If you need to create graphics files and view them -with , then include the following (either in 'FOO.sas' or in -'~/autoexec.sas'): +with , then include the following (either in ‘FOO.sas’ or in +‘~/autoexec.sas’): filename gsasfile 'graphics.ps'; goptions device=ps gsfname=gsasfile gsfmode=append; - 'PROC PLOT' graphs can be viewed in the listing buffer. You may wish + ‘PROC PLOT’ graphs can be viewed in the listing buffer. You may wish to control the vertical spacing to allow the entire plot to be visible on screen, for example: proc plot; @@ -4359,13 +4359,13 @@ File: ess.info, Node: ESS(SAS)--Windows, Prev: ESS(SAS)--Graphics, Up: ESS fo 13.9 ESS[SAS]-Windows ===================== - * iESS[SAS] does not work on Windows. *Note iESS(SAS)--Common + • iESS[SAS] does not work on Windows. *Note iESS(SAS)--Common problems::. - * ESS[SAS] mode for editing SAS language files works very well. + • ESS[SAS] mode for editing SAS language files works very well. *Note ESS(SAS)--Editing files::. - * There are two execution options for SAS on Windows. You can use + • There are two execution options for SAS on Windows. You can use batch. *Note ESS(SAS)--Batch SAS processes::. Or you can mark regions with the mouse and submit the code with @@ -4390,28 +4390,28 @@ commands is also supported. 14.1 ESS[BUGS]-Model files ========================== -Model files with the '.bug' extension are edited in ESS[BUGS] mode. -Three keys are bound for your use in ESS[BUGS], 'F2', 'C-c C-c' and '='. -'F2' performs the same action as it does in ESS[SAS], *Note -ESS(SAS)--Function keys for batch processing::. 'C-c C-c' performs the -function 'ess-bugs-next-action' which you will use a lot. Pressing it +Model files with the ‘.bug’ extension are edited in ESS[BUGS] mode. +Three keys are bound for your use in ESS[BUGS], ‘F2’, ‘C-c C-c’ and ‘=’. +‘F2’ performs the same action as it does in ESS[SAS], *Note +ESS(SAS)--Function keys for batch processing::. ‘C-c C-c’ performs the +function ‘ess-bugs-next-action’ which you will use a lot. Pressing it in an empty buffer for a model file will produce a template for you. -'=' inserts the set operator, '<-'. +‘=’ inserts the set operator, ‘<-’. 14.2 ESS[BUGS]-Command files ============================ -Files ending in '.bmd' are used for BUGS command files. When you have -finished editing your model file and press 'C-c C-c', a command file is +Files ending in ‘.bmd’ are used for BUGS command files. When you have +finished editing your model file and press ‘C-c C-c’, a command file is created if one does not already exist. When you are finished editing -your command file, pressing 'C-c C-c' again will submit your command +your command file, pressing ‘C-c C-c’ again will submit your command file as a batch job. 14.3 ESS[BUGS]-Log files ======================== -The '.bog' extension is used for BUGS log files. The command line -generated by ESS creates the '.bog' transcript file. +The ‘.bog’ extension is used for BUGS log files. The command line +generated by ESS creates the ‘.bog’ transcript file.  File: ess.info, Node: ESS for JAGS, Next: Mailing lists/bug reports, Prev: ESS for BUGS, Up: Top @@ -4431,55 +4431,55 @@ and submit a JAGS batch process. 15.1 ESS[JAGS]-Model files ========================== -Files with the '.jag' extension are edited in ESS[JAGS] mode. Three -keys are bound for your use in ESS[JAGS], 'F2', 'C-c C-c' and '='. 'F2' +Files with the ‘.jag’ extension are edited in ESS[JAGS] mode. Three +keys are bound for your use in ESS[JAGS], ‘F2’, ‘C-c C-c’ and ‘=’. ‘F2’ performs the same action as it does in ESS[SAS], *Note -ESS(SAS)--Function keys for batch processing::. 'C-c C-c' performs the -function 'ess-bugs-next-action' which you will use a lot. Pressing it +ESS(SAS)--Function keys for batch processing::. ‘C-c C-c’ performs the +function ‘ess-bugs-next-action’ which you will use a lot. Pressing it in an empty buffer for a model file will produce a template for you. -'=' inserts the set operator, '<-'. +‘=’ inserts the set operator, ‘<-’. - The first press of 'C-c C-c' will set up a template, including some + The first press of ‘C-c C-c’ will set up a template, including some necessary file-local variables in an empty buffer. These variables are -'ess-jags-chains', 'ess-jags-monitor', 'ess-jags-thin', -'ess-jags-burnin' and 'ess-jags-update'; they appear in the 'Local -Variables' section. When you are finished editing your model file, -pressing 'C-c C-c' will perform the necessary actions to build your +‘ess-jags-chains’, ‘ess-jags-monitor’, ‘ess-jags-thin’, +‘ess-jags-burnin’ and ‘ess-jags-update’; they appear in the ‘Local +Variables’ section. When you are finished editing your model file, +pressing ‘C-c C-c’ will perform the necessary actions to build your command file for you. - The 'ess-jags-chains' variable is the number of chains that you want -to initialize and sample from; defaults to 1. The 'ess-jags-monitor' + The ‘ess-jags-chains’ variable is the number of chains that you want +to initialize and sample from; defaults to 1. The ‘ess-jags-monitor’ variable is a list of variables that you want monitored: encase each -variable in double quotes. When you press 'C-c C-c', the appropriate +variable in double quotes. When you press ‘C-c C-c’, the appropriate statements are created in the command file to monitor the list of variables. By default, no variables are explicitly monitored which means JAGS will implicitly monitor all "default" variables. The -'ess-jags-thin' variable is the thinning parameter. By default, the +‘ess-jags-thin’ variable is the thinning parameter. By default, the thinning parameter is set to 1, i.e. no thinning. The -'ess-jags-burnin' variable is the number of initial samples to discard. -By default, the burnin parameter is set to 10000. The 'ess-jags-update' +‘ess-jags-burnin’ variable is the number of initial samples to discard. +By default, the burnin parameter is set to 10000. The ‘ess-jags-update’ variable is the number of post-burnin samples to keep. By default, the -update parameter is set to 10000. Both 'ess-jags-burnin' and -'ess-jags-update' are multiplied by 'ess-jags-thin' since JAGS does not +update parameter is set to 10000. Both ‘ess-jags-burnin’ and +‘ess-jags-update’ are multiplied by ‘ess-jags-thin’ since JAGS does not do it automatically. 15.2 ESS[JAGS]-Command files ============================ -Files ending in '.jmd' are for JAGS command files. For your '.jmd' -file, there is only one variable, 'ess-jags-command', in the 'Local -Variables' section. When you have finished editing your model file and -press 'C-c C-c', a command file is created if one does not already -exist. When you are finished editing your command file, pressing 'C-c -C-c' again will submit your command file as a batch job. The -'ess-jags-command' variable allows you to specify a different JAGS +Files ending in ‘.jmd’ are for JAGS command files. For your ‘.jmd’ +file, there is only one variable, ‘ess-jags-command’, in the ‘Local +Variables’ section. When you have finished editing your model file and +press ‘C-c C-c’, a command file is created if one does not already +exist. When you are finished editing your command file, pressing ‘C-c +C-c’ again will submit your command file as a batch job. The +‘ess-jags-command’ variable allows you to specify a different JAGS program to use to run your model; defaults to "jags". 15.3 ESS[JAGS]-Log files ======================== -The '.jog' extension is used for JAGS log files. You may find 'F2' -useful to refresh the '.jog' if the batch process over-writes or appends +The ‘.jog’ extension is used for JAGS log files. You may find ‘F2’ +useful to refresh the ‘.jog’ if the batch process over-writes or appends it.  @@ -4501,39 +4501,39 @@ File: ess.info, Node: Bugs, Next: Reporting Bugs, Up: Mailing lists/bug repor 16.1 Bugs ========= - * Commands like 'ess-display-help-on-object' and list completion + • Commands like ‘ess-display-help-on-object’ and list completion cannot be used while the user is entering a multi-line command. The only real fix in this situation is to use another ESS process. - * The 'ess-eval-' commands can leave point in the ESS process buffer + • The ‘ess-eval-’ commands can leave point in the ESS process buffer in the wrong place when point is at the same position as the last process output. This proves difficult to fix, in general, as we - need to consider all _windows_ with 'window-point' at the right + need to consider all _windows_ with ‘window-point’ at the right place. - * It's possible to clear the modification flag (say, by saving the + • It's possible to clear the modification flag (say, by saving the buffer) with the edit buffer not having been loaded into S. - * Backup files can sometimes be left behind, even when - 'ess-keep-dump-files' is 'nil'. + • Backup files can sometimes be left behind, even when + ‘ess-keep-dump-files’ is ‘nil’. - * Passing an incomplete S expression to 'ess-execute' causes ESS to + • Passing an incomplete S expression to ‘ess-execute’ causes ESS to hang. - * The function-based commands don't always work as expected on + • The function-based commands don't always work as expected on functions whose body is not a parenthesized or compound expression, and don't even recognize anonymous functions (i.e. functions not assigned to any variable). - * Multi-line commands could be handled better by the command history + • Multi-line commands could be handled better by the command history mechanism. - * Changes to the continuation prompt in R (e.g. 'options(continue = - " ")') are not automatically detected by ESS. Hence, for now, the + • Changes to the continuation prompt in R (e.g. ‘options(continue = + " ")’) are not automatically detected by ESS. Hence, for now, the best thing is not to change the continuation prompt. If you do change the continuation prompt, you will need to change accordingly - the value of 'inferior-ess-secondary-prompt' in - 'R-customize-alist'. + the value of ‘inferior-ess-secondary-prompt’ in + ‘R-customize-alist’.  File: ess.info, Node: Reporting Bugs, Next: Mailing Lists, Prev: Bugs, Up: Mailing lists/bug reports @@ -4547,7 +4547,7 @@ or post them on our github issue tracker The easiest way to do this is within Emacs by typing - 'M-x ess-submit-bug-report' + ‘M-x ess-submit-bug-report’ This also gives the maintainers valuable information about your installation which may help us to identify or even fix the bug. @@ -4574,11 +4574,11 @@ this is a fairly low-volume mailing list. The purposes of the mailing list include - * helping users of ESS to get along with it. - * discussing aspects of using ESS. - * suggestions for improvements. - * announcements of new releases of ESS. - * posting small patches to ESS. + • helping users of ESS to get along with it. + • discussing aspects of using ESS. + • suggestions for improvements. + • announcements of new releases of ESS. + • posting small patches to ESS.  File: ess.info, Node: Help with Emacs, Prev: Mailing Lists, Up: Mailing lists/bug reports @@ -4589,7 +4589,7 @@ File: ess.info, Node: Help with Emacs, Prev: Mailing Lists, Up: Mailing lists Emacs is a complex editor with many abilities that we do not have space to describe here. If you have problems with other features of Emacs (e.g. printing), there are several sources to consult, including the -Emacs FAQs (try 'M-x view-emacs-faq') and EmacsWiki +Emacs FAQs (try ‘M-x view-emacs-faq’) and EmacsWiki (). Please consult them before asking on the mailing list about issues that are not specific to ESS. @@ -4607,7 +4607,7 @@ your preferences, and for per-buffer customizations hooks are also available. Most of these variables can be viewed and set using the Custom -facility within Emacs. Type 'M-x customize-group RET ess RET' to see +facility within Emacs. Type ‘M-x customize-group RET ess RET’ to see all the ESS variables that can be customized. Variables are grouped by subject to make it easy to find related variables. @@ -4636,6 +4636,7 @@ Key index * ,: Handy commands. (line 6) * {: Indenting. (line 53) * }: Indenting. (line 53) +* C-c `: Error Checking. (line 9) * C-c C-. d: Package listing. (line 30) * C-c C-. H: Package listing. (line 33) * C-c C-. l: Package listing. (line 10) @@ -4674,7 +4675,6 @@ Key index * C-c M-l: Hot keys. (line 50) * C-c M-r: Evaluating code. (line 64) * C-c RET: Resubmit. (line 14) -* C-c `: Error Checking. (line 9) * C-j: Indenting. (line 60) * C-M-a: Other edit buffer commands. (line 10) @@ -5055,110 +5055,110 @@ Concept Index  Tag Table: -Node: Top268 -Node: Introduction2906 -Node: Features5660 -Node: Current Features6486 -Node: New features9937 -Node: Credits36694 -Node: Manual40311 -Node: Installation42977 -Node: Installing from a third-party repository43914 -Node: Installing from source44861 -Node: Activating and Loading ESS46453 -Node: Check Installation47527 -Node: Interactive ESS47747 -Node: Starting up48592 -Node: Multiple ESS processes49336 -Node: ESS processes on Remote Computers50417 -Node: Customizing startup54520 -Node: Controlling buffer display57410 -Node: Entering commands60031 -Node: Command-line editing61189 -Node: Transcript62422 -Node: Last command64191 -Node: Process buffer motion65617 -Node: Transcript resubmit67120 -Node: Saving transcripts69085 -Node: Command History70875 -Node: Saving History74284 -Node: History expansion75045 -Node: Hot keys78256 -Node: Statistical Process running in ESS?82326 -Node: Emacsclient83605 -Node: Other84397 -Node: Evaluating code85416 -Node: Transcript Mode89212 -Node: Resubmit90365 -Node: Clean91428 -Node: Editing objects92424 -Node: Edit buffer93542 -Node: Loading95588 -Node: Error Checking96615 -Node: Indenting97664 -Node: Styles100708 -Node: Other edit buffer commands103082 -Node: Source Files104738 -Node: Source Directories109342 -Node: Help112495 -Node: Completion116941 -Node: Object names117156 -Node: Function arguments119790 -Node: Minibuffer completion120733 -Node: Company121207 -Node: Icicles121594 -Node: Developing with ESS122914 -Node: ESS tracebug123360 -Node: Getting started with tracebug126367 -Node: Editing documentation128525 -Node: R documentation files129077 -Node: roxygen2132780 -Node: Namespaced Evaluation137191 -Node: Extras139189 -Node: ESS ElDoc140213 -Node: ESS Flymake141709 -Node: Handy commands142803 -Node: Highlighting144000 -Node: Parens145035 -Node: Graphics145511 -Node: printer146182 -Node: X11146938 -Node: winjava147277 -Node: Imenu147689 -Node: Toolbar148536 -Node: Xref148944 -Node: Rdired149272 -Node: Package listing150335 -Node: Org151719 -Node: Sweave and AUCTeX152673 -Node: ESS for R155225 -Node: ESS(R)--Editing files155525 -Node: iESS(R)--Inferior ESS processes156026 -Node: Philosophies for using ESS(R)158681 -Node: Example ESS usage159608 -Node: ESS for SAS161013 -Node: ESS(SAS)--Design philosophy161736 -Node: ESS(SAS)--Editing files162669 -Node: ESS(SAS)--TAB key164523 -Node: ESS(SAS)--Batch SAS processes165889 -Node: ESS(SAS)--Function keys for batch processing170917 -Node: iESS(SAS)--Interactive SAS processes180404 -Node: iESS(SAS)--Common problems184158 -Node: ESS(SAS)--Graphics185682 -Node: ESS(SAS)--Windows186465 -Node: ESS for BUGS187043 -Node: ESS for JAGS188799 -Node: Mailing lists/bug reports192151 -Node: Bugs192415 -Node: Reporting Bugs194039 -Node: Mailing Lists194932 -Node: Help with Emacs195659 -Node: Customization196191 -Node: Indices196965 -Node: Key index197140 -Node: Function and program index202272 -Node: Variable index211692 -Node: Concept index215253 +Node: Top270 +Node: Introduction2908 +Node: Features5694 +Node: Current Features6520 +Node: New features10067 +Node: Credits37886 +Node: Manual41545 +Node: Installation44255 +Node: Installing from a third-party repository45192 +Node: Installing from source46139 +Node: Activating and Loading ESS47763 +Node: Check Installation48845 +Node: Interactive ESS49069 +Node: Starting up49914 +Node: Multiple ESS processes50674 +Node: ESS processes on Remote Computers51787 +Node: Customizing startup56014 +Node: Controlling buffer display58996 +Node: Entering commands61633 +Node: Command-line editing62795 +Node: Transcript64060 +Node: Last command65857 +Node: Process buffer motion67315 +Node: Transcript resubmit68858 +Node: Saving transcripts70855 +Node: Command History72689 +Node: Saving History76190 +Node: History expansion76971 +Node: Hot keys80362 +Node: Statistical Process running in ESS?84532 +Node: Emacsclient85879 +Node: Other86699 +Node: Evaluating code87742 +Node: Transcript Mode91674 +Node: Resubmit92847 +Node: Clean93922 +Node: Editing objects94922 +Node: Edit buffer96040 +Node: Loading98130 +Node: Error Checking99185 +Node: Indenting100258 +Node: Styles103410 +Node: Other edit buffer commands105912 +Node: Source Files107624 +Node: Source Directories112340 +Node: Help115549 +Node: Completion120251 +Node: Object names120466 +Node: Function arguments123180 +Node: Minibuffer completion124159 +Node: Company124657 +Node: Icicles125056 +Node: Developing with ESS126432 +Node: ESS tracebug126878 +Node: Getting started with tracebug129937 +Node: Editing documentation132223 +Node: R documentation files132775 +Node: roxygen2136590 +Node: Namespaced Evaluation141113 +Node: Extras143127 +Node: ESS ElDoc144151 +Node: ESS Flymake145731 +Node: Handy commands146861 +Node: Highlighting148138 +Node: Parens149189 +Node: Graphics149665 +Node: printer150336 +Node: X11151108 +Node: winjava151447 +Node: Imenu151859 +Node: Toolbar152714 +Node: Xref153122 +Node: Rdired153450 +Node: Package listing154529 +Node: Org155977 +Node: Sweave and AUCTeX156931 +Node: ESS for R159563 +Node: ESS(R)--Editing files159863 +Node: iESS(R)--Inferior ESS processes160368 +Node: Philosophies for using ESS(R)163087 +Node: Example ESS usage164014 +Node: ESS for SAS165419 +Node: ESS(SAS)--Design philosophy166146 +Node: ESS(SAS)--Editing files167083 +Node: ESS(SAS)--TAB key169027 +Node: ESS(SAS)--Batch SAS processes170441 +Node: ESS(SAS)--Function keys for batch processing175661 +Node: iESS(SAS)--Interactive SAS processes185568 +Node: iESS(SAS)--Common problems189510 +Node: ESS(SAS)--Graphics191124 +Node: ESS(SAS)--Windows191923 +Node: ESS for BUGS192507 +Node: ESS for JAGS194319 +Node: Mailing lists/bug reports197815 +Node: Bugs198079 +Node: Reporting Bugs199755 +Node: Mailing Lists200652 +Node: Help with Emacs201389 +Node: Customization201925 +Node: Indices202703 +Node: Key index202878 +Node: Function and program index208010 +Node: Variable index217430 +Node: Concept index220991  End Tag Table diff --git a/lisp/git-commit/git-commit-pkg.el b/lisp/git-commit/git-commit-pkg.el index f2036490..f0fd8805 100644 --- a/lisp/git-commit/git-commit-pkg.el +++ b/lisp/git-commit/git-commit-pkg.el @@ -1,4 +1,4 @@ -(define-package "git-commit" "20250221.105" "Edit Git commit messages" 'nil :commit "d4fdadc127d3d8b98e71d38675bb0438c6ae93f1" :authors +(define-package "git-commit" "20250307.1746" "Edit Git commit messages" 'nil :commit "80cae1a26f13a4d48a19cfe8612a561348423f35" :authors '(("Jonas Bernoulli" . "emacs.magit@jonas.bernoulli.dev") ("Sebastian Wiesner" . "lunaryorn@gmail.com") ("Florian Ragwitz" . "rafl@debian.org") diff --git a/lisp/git-commit/git-commit.el b/lisp/git-commit/git-commit.el index b0f3e6ae..5818bfda 100644 --- a/lisp/git-commit/git-commit.el +++ b/lisp/git-commit/git-commit.el @@ -178,6 +178,7 @@ The major mode configured here is turned on by the minor mode (function-item markdown-mode) (function-item org-mode) (function-item fundamental-mode) + (function-item log-edit-mode) (function-item git-commit-elisp-text-mode) (function :tag "Another mode") (const :tag "No major mode"))) @@ -187,6 +188,7 @@ The major mode configured here is turned on by the minor mode ;;;###autoload markdown-mode ;;;###autoload org-mode ;;;###autoload fundamental-mode +;;;###autoload log-edit-mode ;;;###autoload git-commit-elisp-text-mode)))) (defvaralias 'git-commit-mode-hook 'git-commit-setup-hook diff --git a/lisp/helpful/helpful-pkg.el b/lisp/helpful/helpful-pkg.el index 57f29361..2b835a9f 100644 --- a/lisp/helpful/helpful-pkg.el +++ b/lisp/helpful/helpful-pkg.el @@ -1,10 +1,10 @@ -(define-package "helpful" "20250220.545" "A better *help* buffer" +(define-package "helpful" "20250227.1527" "A better *help* buffer" '((emacs "25") (dash "2.18.0") (s "1.11.0") (f "0.20.0") (elisp-refs "1.2")) - :commit "5ad8a9ce57b6c076428286c3d25968b449ab6fd3" :authors + :commit "3794389ef685b6a59b3a487d0492c3add3c42c2f" :authors '(("Wilfred Hughes" . "me@wilfred.me.uk")) :maintainers '(("Wilfred Hughes" . "me@wilfred.me.uk")) diff --git a/lisp/helpful/helpful.el b/lisp/helpful/helpful.el index b100816b..331ece89 100644 --- a/lisp/helpful/helpful.el +++ b/lisp/helpful/helpful.el @@ -2570,7 +2570,9 @@ For example, \"(some-func FOO &optional BAR)\"." (cond ((symbolp sym) (help-function-arglist sym)) - ((byte-code-function-p sym) + ((or (byte-code-function-p sym) + (if (fboundp 'interpreted-function-p) + (interpreted-function-p sym))) ;; argdesc can be a list of arguments or an integer ;; encoding the min/max number of arguments. See ;; Byte-Code Function Objects in the elisp manual. diff --git a/lisp/ivy/ivy.info b/lisp/ivy/ivy.info index 4a5cb0a3..3441f027 100644 --- a/lisp/ivy/ivy.info +++ b/lisp/ivy/ivy.info @@ -1,4 +1,4 @@ -This is ivy.info, produced by makeinfo version 6.8 from ivy.texi. +This is ivy.info, produced by makeinfo version 7.1.1 from ivy.texi. Ivy manual, version 0.15.0 @@ -11,7 +11,7 @@ available choices while previewing in the minibuffer. Selecting the final candidate is either through simple keyboard character inputs or through powerful regular expressions. - Copyright (C) 2015–2025 Free Software Foundation, Inc. + Copyright (C) 2015-2025 Free Software Foundation, Inc. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, @@ -44,7 +44,7 @@ Ivy User Manual * Variable Index:: * Keystroke Index:: -— The Detailed Node Listing — +-- The Detailed Node Listing -- Installation @@ -144,11 +144,11 @@ Minimalism Simplicity .......... - Simplicity is about Ivy’s behavior in the minibuffer. It is also - about the code interface to extend Ivy’s functionality. The + Simplicity is about Ivy's behavior in the minibuffer. It is also + about the code interface to extend Ivy's functionality. The minibuffer area behaves as close to ‘fundamental-mode’ as possible. ‘SPC’ inserts a space, for example, instead of being bound to the - more complex ‘minibuffer-complete-word’. Ivy’s code uses + more complex ‘minibuffer-complete-word’. Ivy's code uses easy-to-examine global variables; avoids needless complications with branch-introducing custom macros. @@ -163,7 +163,7 @@ Customizability ‘ivy-format-functions-alist’). Or take the customization of actions, say after the candidate function is selected. ‘RET’ uses ‘counsel-describe-function’ to describe the function, whereas ‘M-o - d’ jumps to that function’s definition in the code. The ‘M-o’ + d’ jumps to that function's definition in the code. The ‘M-o’ prefix can be uniformly used with characters like ‘d’ to group similar actions. @@ -185,8 +185,8 @@ File: ivy.info, Node: Installation, Next: Getting started, Prev: Introduction 2 Installation ************** -Install Ivy automatically through Emacs’s package manager, or manually -from Ivy’s development repository. +Install Ivy automatically through Emacs's package manager, or manually +from Ivy's development repository. Emacs 24.5 is the oldest version to run Ivy. @@ -236,7 +236,7 @@ Why install from Git? • No need to wait for GNU ELPA / MELPA builds • Easy to revert to previous versions - • Contribute to Ivy’s development; send patches; pull requests + • Contribute to Ivy's development; send patches; pull requests Configuration steps ................... @@ -285,7 +285,7 @@ Here are some basic settings particularly useful for new Ivy users: If you want, you can go without any customizations at all. The above settings are the most bang for the buck in terms of customization. So -users that typically don’t like customize a lot are advised to look at +users that typically don't like customize a lot are advised to look at these settings first. For more advanced customizations, refer to ‘M-x describe-variable’ @@ -472,7 +472,7 @@ extends usability of lists in Emacs. This is useful e.g. when you call ‘find-file’ to create a new file, but the desired name matches an existing file. In that case, - using ‘C-j’ would select that existing file, which isn’t what you + using ‘C-j’ would select that existing file, which isn't what you want - use this command instead. ‘C-'’ (‘ivy-avy’) @@ -594,7 +594,7 @@ File: ivy.info, Node: Key bindings that alter the minibuffer input, Next: Othe ‘C-r’ (‘ivy-reverse-i-search’) .............................. - Starts a recursive completion session through the command’s + Starts a recursive completion session through the command's history. This works just like ‘C-r’ at the bash command prompt, where the @@ -757,7 +757,7 @@ File: ivy.info, Node: Completion Styles, Next: Customization, Prev: Key bindi 5 Completion Styles ******************* -Ivy’s completion functions rely on a regex builder - a function that +Ivy's completion functions rely on a regex builder - a function that transforms a string input to a string regex. All current candidates simply have to match this regex. Each collection can be assigned its own regex builder by customizing ‘ivy-re-builders-alist’. @@ -770,7 +770,7 @@ of the following: • ‘ivy--regex-fuzzy’ • ‘regexp-quote’ - A catch-all key, ‘t’, applies to all collections that don’t have + A catch-all key, ‘t’, applies to all collections that don't have their own key. The default is: @@ -807,15 +807,15 @@ second argument to ‘completing-read’ for file name completion.  File: ivy.info, Node: ivy--regex-plus, Next: ivy--regex-ignore-order, Up: Completion Styles -5.1 ivy–regex-plus +5.1 ivy-regex-plus ================== -‘ivy--regex-plus’ is Ivy’s default completion method. +‘ivy--regex-plus’ is Ivy's default completion method. ‘ivy--regex-plus’ matches by splitting the input by spaces and rebuilding it into a regex. - As the search string is typed in Ivy’s minibuffer, it is transformed + As the search string is typed in Ivy's minibuffer, it is transformed into valid regex syntax. If the string is ‘"for example"’, it is transformed into @@ -844,7 +844,7 @@ of a negation group.  File: ivy.info, Node: ivy--regex-ignore-order, Next: ivy--regex-fuzzy, Prev: ivy--regex-plus, Up: Completion Styles -5.2 ivy–regex-ignore-order +5.2 ivy-regex-ignore-order ========================== ‘ivy--regex-ignore-order’ ignores the order of regexp tokens when @@ -854,13 +854,13 @@ example"’ will match ‘"example test for"’.  File: ivy.info, Node: ivy--regex-fuzzy, Prev: ivy--regex-ignore-order, Up: Completion Styles -5.3 ivy–regex-fuzzy +5.3 ivy-regex-fuzzy =================== ‘ivy--regex-fuzzy’ splits each character with a wild card. Searching for ‘"for"’ returns all ‘"f.*o.*r"’ matches, resulting in a large number of hits. Yet some searches need these extra hits. Ivy sorts such large -lists using ‘flx’ package’s scoring mechanism, if it’s installed. +lists using ‘flx’ package's scoring mechanism, if it's installed. ‘C-o m’ toggles the current regexp builder. @@ -1011,7 +1011,7 @@ File: ivy.info, Node: Defcustoms, Next: Actions, Prev: Faces, Up: Customizat This is usually the case when there is no text left to delete, i.e., when ‘DEL’ is typed at the beginning of the minibuffer. - The default behavior is to quit the completion after ‘DEL’ – a + The default behavior is to quit the completion after ‘DEL’ - a handy key to invoke after mistakenly triggering a completion. Another common option is ‘ignore’, which does nothing. @@ -1448,7 +1448,7 @@ File: ivy.info, Node: Optional arguments for ivy-read, Next: Example - counsel ........... Is a function to filter the initial collection. It has to be - compatible with ‘all-completions’. Tip: most of the time, it’s + compatible with ‘all-completions’. Tip: most of the time, it's simpler to just apply this filter to the ‘collection’ argument itself, e.g. ‘(cl-remove-if-not predicate collection)’. @@ -1464,7 +1464,7 @@ File: ivy.info, Node: Optional arguments for ivy-read, Next: Example - counsel This string argument is included for compatibility with ‘completing-read’, which inserts it into the minibuffer. - It’s recommended to use the ‘preselect’ argument instead of this. + It's recommended to use the ‘preselect’ argument instead of this. ‘history’ ......... @@ -1498,7 +1498,7 @@ File: ivy.info, Node: Optional arguments for ivy-read, Next: Example - counsel ........... Is the function called each time the current candidate changes. - This function takes no arguments and is called in the minibuffer’s + This function takes no arguments and is called in the minibuffer's ‘post-command-hook’. See ‘swiper’ for an example usage. ‘sort’ @@ -1563,7 +1563,7 @@ the rest of the arguments are for fine-tuning, and could be omitted. The ‘action’ argument could also be omitted - but then ‘ivy-read’ would do nothing except returning the string result, which you could -later use yourself. However, it’s recommended that you use the ‘action’ +later use yourself. However, it's recommended that you use the ‘action’ argument. (defun counsel-describe-function () @@ -1599,14 +1599,14 @@ that they appear: input is necessary. • The ‘history’ argument is for keeping the history of this command separate from the common history in ‘ivy-history’. - • The ‘require-match’ is set to ‘t’ since it doesn’t make sense to + • The ‘require-match’ is set to ‘t’ since it doesn't make sense to call ‘describe-function’ on an un-interned symbol. • The ‘action’ argument calls ‘describe-function’ on the interned selected candidate. • The ‘caller’ argument identifies this completion session. This is important, since with the collection being a list of strings and not a function name, the only other way for ‘ivy-read’ to identify - "who’s calling" and to apply the appropriate customizations is to + "who's calling" and to apply the appropriate customizations is to examine ‘this-command’. But ‘this-command’ would be modified if another command called ‘counsel-describe-function’. @@ -1665,8 +1665,8 @@ narrowing) or select a candidate from the visible collection. order that they appear: • ‘counsel-locate-function’ takes a string argument and returns a - list of strings. Note that it’s not compatible with - ‘all-completions’, but since we’re not using that here, might as + list of strings. Note that it's not compatible with + ‘all-completions’, but since we're not using that here, might as well use one argument instead of three. • ‘ivy-more-chars’ is a simple function that returns e.g. ‘'("2 chars more")’ asking the user for more input. @@ -1917,52 +1917,52 @@ File: ivy.info, Node: Keystroke Index, Prev: Variable Index, Up: Top  Tag Table: Node: Top1192 -Node: Introduction3103 -Node: Installation5626 -Node: Installing from Emacs Package Manager6002 -Node: Installing from the Git repository7249 -Node: Getting started8079 -Node: Basic customization8386 -Node: Key bindings8981 -Node: Global key bindings9173 -Node: Minibuffer key bindings11647 -Node: Key bindings for navigation12879 -Node: Key bindings for single selection action then exit minibuffer14086 -Node: Key bindings for multiple selections and actions keep minibuffer open16770 -Node: Key bindings that alter the minibuffer input19391 -Node: Other key bindings21338 -Node: Hydra in the minibuffer21716 -Node: Saving the current completion session to a buffer24134 -Node: Completion Styles25546 -Node: ivy--regex-plus27304 -Node: ivy--regex-ignore-order28790 -Node: ivy--regex-fuzzy29158 -Node: Customization29655 -Node: Faces29841 -Node: Defcustoms32270 -Node: Actions33596 -Node: What are actions?33922 -Node: How can different actions be called?34740 -Node: How to modify the actions list?35311 -Node: Example - add two actions to each command35971 -Node: How to undo adding the two actions36930 -Node: How to add actions to a specific command37382 -Node: Example - define a new command with several actions37798 -Node: Test the above function with ivy-occur38735 -Node: Packages39577 -Node: Commands40542 -Node: File Name Completion40727 -Node: Using TRAMP42684 -Node: Buffer Name Completion44186 -Node: Counsel commands44801 -Node: API45448 -Node: Required arguments for ivy-read46046 -Node: Optional arguments for ivy-read46565 -Node: Example - counsel-describe-function49991 -Node: Example - counsel-locate52975 -Node: Example - ivy-read-with-extra-properties56844 -Node: Variable Index58122 -Node: Keystroke Index65246 +Node: Introduction3101 +Node: Installation5616 +Node: Installing from Emacs Package Manager5988 +Node: Installing from the Git repository7235 +Node: Getting started8063 +Node: Basic customization8370 +Node: Key bindings8963 +Node: Global key bindings9155 +Node: Minibuffer key bindings11629 +Node: Key bindings for navigation12861 +Node: Key bindings for single selection action then exit minibuffer14068 +Node: Key bindings for multiple selections and actions keep minibuffer open16750 +Node: Key bindings that alter the minibuffer input19371 +Node: Other key bindings21316 +Node: Hydra in the minibuffer21694 +Node: Saving the current completion session to a buffer24112 +Node: Completion Styles25524 +Node: ivy--regex-plus27278 +Node: ivy--regex-ignore-order28758 +Node: ivy--regex-fuzzy29124 +Node: Customization29615 +Node: Faces29801 +Node: Defcustoms32230 +Node: Actions33554 +Node: What are actions?33880 +Node: How can different actions be called?34698 +Node: How to modify the actions list?35269 +Node: Example - add two actions to each command35929 +Node: How to undo adding the two actions36888 +Node: How to add actions to a specific command37340 +Node: Example - define a new command with several actions37756 +Node: Test the above function with ivy-occur38693 +Node: Packages39535 +Node: Commands40500 +Node: File Name Completion40685 +Node: Using TRAMP42642 +Node: Buffer Name Completion44144 +Node: Counsel commands44759 +Node: API45406 +Node: Required arguments for ivy-read46004 +Node: Optional arguments for ivy-read46523 +Node: Example - counsel-describe-function49943 +Node: Example - counsel-locate52921 +Node: Example - ivy-read-with-extra-properties56786 +Node: Variable Index58064 +Node: Keystroke Index65188  End Tag Table diff --git a/lisp/ledger-mode/ledger-mode.info b/lisp/ledger-mode/ledger-mode.info index 797498f4..b3e54042 100644 --- a/lisp/ledger-mode/ledger-mode.info +++ b/lisp/ledger-mode/ledger-mode.info @@ -1,4 +1,4 @@ -This is ledger-mode.info, produced by makeinfo version 6.8 from +This is ledger-mode.info, produced by makeinfo version 7.1.1 from ledger-mode.texi. Copyright © 2013, Craig Earls. All rights reserved. @@ -20,7 +20,7 @@ met: from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -“AS IS” AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, @@ -45,7 +45,7 @@ Overview Ledger is a command line accounting tool that provides double-entry accounting based on a text journal. It provides no bells or whistles, and returns the user to the days before user interfaces were even a -twinkling in their father’s CRT. +twinkling in their father's CRT. Ledger-mode assists you in maintaining input files for Ledger, running reports and much more... @@ -260,7 +260,7 @@ Beyond the two ways of quickly adding transactions (*note Quick Add::) Ledger-mode assists you by providing robust ‘TAB’ completion for payees and accounts. Ledger-mode will scan the existing buffer for payees and accounts. Included files are not currently included in the completion -scan. Ledger-mode respects Emacs’s variables that govern ‘TAB’ +scan. Ledger-mode respects Emacs's variables that govern ‘TAB’ completion, see especially ‘tab-always-indent’. To cycle between completions when hitting ‘TAB’ multiple times, you @@ -367,7 +367,7 @@ some additional meaning to the states: call these transactions _pending_, but Ledger-mode uses a slightly different meaning. - • Pending. Ledger-mode’s reconciliation function see pending + • Pending. Ledger-mode's reconciliation function see pending transactions as an intermediate step in reconciling an account. When doing a reconciliation (*note Reconciliation::), marking a transaction as pending means that you have seen the transaction @@ -416,11 +416,11 @@ File: ledger-mode.info, Node: Sorting Transactions, Next: Narrowing Transactio ======================== As you operating on the Ledger files, they may become disorganized. For -the most part, Ledger doesn’t care, but our human brains prefer a bit of +the most part, Ledger doesn't care, but our human brains prefer a bit of order. Sorting the transactions in a buffer into chronological order can help bring order to chaos. Either using ‘Sort Region’ menu entry or typing ‘C-c C-s’ will sort all of the transactions in a region by date. -Ledger-mode isn’t particularly smart about handling dates and it simply +Ledger-mode isn't particularly smart about handling dates and it simply sorts the transactions using the string at the beginning of the transaction. So, you should use the preferred ISO 8601 standard date format ‘YYYY/MM/DD’ which easily sorts. @@ -454,7 +454,7 @@ File: ledger-mode.info, Node: Narrowing Transactions, Prev: Sorting Transactio ========================== Often you will want to run Ledger register reports just to look at a -specific set of transactions. If you don’t need the running total +specific set of transactions. If you don't need the running total calculation handled by Ledger, Ledger-mode provides a rapid way of narrowing what is displayed in the buffer in a way that is simpler than the Ledger register command. @@ -463,7 +463,7 @@ the Ledger register command. hides all transactions that do _not_ meet a specific regular expression. The regular expression can match on any part of the transaction. If you want to find all transactions whose amount ends in ‘.37’, you can do -that (I don’t know why, but hey, whatever ever floats you aerostat). +that (I don't know why, but hey, whatever ever floats you aerostat). Using ‘C-c C-f’ or the ‘Narrow to Regex’ menu entry, enter a regular expression in the Minibuffer. Ledger-mode will hide all other @@ -491,7 +491,7 @@ here: To show back all transactions simply invoke ‘Narrow to Regex’ or ‘C-c C-f’ again. - If you’ve edited some transactions after narrowing such that they + If you've edited some transactions after narrowing such that they would no longer match the regular expression, you can refresh the narrowed view using ‘C-c C-g’. @@ -523,7 +523,7 @@ instantaneously, unless you are paying cash. When you swipe your debit card the money may take several days to actually come out of your account, or a check may take several days to _clear_. That is the root of the difference between _obligating_ funds and _expending_ funds. -Obligation says you have agreed to pay it, the expenditure doesn’t +Obligation says you have agreed to pay it, the expenditure doesn't happen until the money actually leaves your account. Or in the case of receiving payment, you have an account receivable until the money has actually made it to you. @@ -703,7 +703,7 @@ File: ledger-mode.info, Node: Adding and Editing Reports, Next: Reversing Repo * Expansion Formats:: * Make Report Transactions Active:: -If you type a report name that Ledger-mode doesn’t recognize it will +If you type a report name that Ledger-mode doesn't recognize it will prompt you for a ledger command line to run. That command is automatically saved with the name given and you can re-run it at any time. @@ -783,7 +783,7 @@ File: ledger-mode.info, Node: Make Report Transactions Active, Prev: Expansion In a large register report it is convenient to be able to jump to the source transaction. Ledger-mode will automatically include source -information in every register file that doesn’t contain a ‘--subtotal’ +information in every register file that doesn't contain a ‘--subtotal’ option. It does this by adding ‘--prepend-format='%(filename):%(beg_line):'’ to the register report command-line you specify. You should never have to see this, but if @@ -812,7 +812,7 @@ File: ledger-mode.info, Node: Scheduling Transactions, Next: Customizing Ledge ************************* The Ledger program provides for automating transactions but these -transaction aren’t _real_, they only exist inside a ledger session and +transaction aren't _real_, they only exist inside a ledger session and are not reflected in the actual data file. Many transactions are very repetitive, but may vary slightly in the date they occur on, or the amount. Some transactions are weekly, monthly, quarterly or annually. @@ -832,7 +832,7 @@ File: ledger-mode.info, Node: Specifying Upcoming Transactions, Prev: Scheduli 5.1 Specifying Upcoming Transactions ==================================== -The format for specifying transactions is identical to Ledger’s file +The format for specifying transactions is identical to Ledger's file format with the exception of the date field. The data field is modified by surrounding it with brackets and using wild cards and special characters to specify when the transactions should appear. @@ -984,7 +984,7 @@ File: ledger-mode.info, Node: Ledger Reconcile Customization Group, Next: Ledg ‘ledger-reconcile-buffer-header’ Header string for the reconcile buffer. If non-nil, the name of - the account being reconciled will be substituted into the ’%s’. If + the account being reconciled will be substituted into the '%s'. If nil, no header will be displayed. Defaults to "Reconciling account %s\n\n". @@ -1007,9 +1007,9 @@ File: ledger-mode.info, Node: Ledger Reconcile Customization Group, Next: Ledg characters. ‘ledger-reconcile-sort-key’ - Key for sorting reconcile buffer. Possible values are ’(date)’, - ’(amount)’, ’(payee)’ or ’(0)’ for no sorting, i.e. using ledger - file order. Defaults to ’(0)’. + Key for sorting reconcile buffer. Possible values are '(date)', + '(amount)', '(payee)' or '(0)' for no sorting, i.e. using ledger + file order. Defaults to '(0)'. ‘ledger-reconcile-insert-effective-date nil’ If t, prompt for effective date when clearing transactions during @@ -1134,7 +1134,7 @@ Ledger Exec: Interface to the Ledger command-line accounting program. Path to the ledger executable. ‘ledger-init-file-name’ - Location of the ledger initialization file. nil if you don’t have + Location of the ledger initialization file. nil if you don't have one.  @@ -1487,64 +1487,64 @@ Keystroke Index  Tag Table: -Node: Top1742 -Node: Introduction to Ledger-mode2555 -Node: Quick Installation2784 -Node: Menus3716 -Node: Quick Demo4031 -Node: Quick Add4461 -Node: Reconciliation5559 -Node: Reports7243 -Node: Narrowing8273 -Node: The Ledger Buffer8857 -Node: Navigating Transactions9263 -Node: Adding Transactions9823 -Node: Setting a Transactions Effective Date11322 -Node: Quick Balance Display12222 -Node: Copying Transactions12754 -Node: Editing Amounts13356 -Node: Marking Transactions14427 -Node: Formatting Transactions16122 -Node: Deleting Transactions16720 -Node: Sorting Transactions17160 -Node: Narrowing Transactions18712 -Node: The Reconcile Buffer20562 -Node: Basics of Reconciliation21027 -Node: Starting a Reconciliation21976 -Node: Mark Transactions Pending23825 -Node: Edit Transactions During Reconciliation24494 -Node: Finalize Reconciliation25137 -Node: Adding and Deleting Transactions during Reconciliation25794 -Node: Changing Reconciliation Account26378 -Node: Changing Reconciliation Target26928 -Node: The Report Buffer27246 -Node: Running Basic Reports27504 -Node: Adding and Editing Reports28937 -Node: Expansion Formats30324 -Node: Make Report Transactions Active31965 -Node: Reversing Report Order32672 -Node: Scheduling Transactions33365 -Node: Specifying Upcoming Transactions34221 -Node: Transactions that occur on specific dates34795 -Node: Transactions that occur on specific days35836 -Node: Customizing Ledger-mode36965 -Node: Ledger-mode Customization37229 -Node: Customization Variables37914 -Node: Ledger Customization Group38394 -Node: Ledger Reconcile Customization Group39034 -Node: Ledger Report Customization Group41985 -Node: Ledger Faces Customization Group42704 -Node: Ledger Post Customization Group44451 -Node: Ledger Exec Customization Group45278 -Node: Ledger Test Customization Group45777 -Node: Ledger Texi Customization Group46179 -Node: Generating Ledger Regression Tests46671 -Node: Embedding Example results in Ledger Documentation46934 -Node: Hacking Ledger-mode47223 -Node: Use org-like outlines47448 -Node: Concept Index48113 -Node: Command & Variable Index53629 -Node: Keystroke Index61739 +Node: Top1740 +Node: Introduction to Ledger-mode2551 +Node: Quick Installation2780 +Node: Menus3712 +Node: Quick Demo4027 +Node: Quick Add4457 +Node: Reconciliation5555 +Node: Reports7239 +Node: Narrowing8269 +Node: The Ledger Buffer8853 +Node: Navigating Transactions9259 +Node: Adding Transactions9819 +Node: Setting a Transactions Effective Date11316 +Node: Quick Balance Display12216 +Node: Copying Transactions12748 +Node: Editing Amounts13350 +Node: Marking Transactions14421 +Node: Formatting Transactions16114 +Node: Deleting Transactions16712 +Node: Sorting Transactions17152 +Node: Narrowing Transactions18700 +Node: The Reconcile Buffer20544 +Node: Basics of Reconciliation21009 +Node: Starting a Reconciliation21956 +Node: Mark Transactions Pending23805 +Node: Edit Transactions During Reconciliation24474 +Node: Finalize Reconciliation25117 +Node: Adding and Deleting Transactions during Reconciliation25774 +Node: Changing Reconciliation Account26358 +Node: Changing Reconciliation Target26908 +Node: The Report Buffer27226 +Node: Running Basic Reports27484 +Node: Adding and Editing Reports28917 +Node: Expansion Formats30302 +Node: Make Report Transactions Active31943 +Node: Reversing Report Order32648 +Node: Scheduling Transactions33341 +Node: Specifying Upcoming Transactions34195 +Node: Transactions that occur on specific dates34767 +Node: Transactions that occur on specific days35808 +Node: Customizing Ledger-mode36937 +Node: Ledger-mode Customization37201 +Node: Customization Variables37886 +Node: Ledger Customization Group38366 +Node: Ledger Reconcile Customization Group39006 +Node: Ledger Report Customization Group41933 +Node: Ledger Faces Customization Group42652 +Node: Ledger Post Customization Group44399 +Node: Ledger Exec Customization Group45226 +Node: Ledger Test Customization Group45723 +Node: Ledger Texi Customization Group46125 +Node: Generating Ledger Regression Tests46617 +Node: Embedding Example results in Ledger Documentation46880 +Node: Hacking Ledger-mode47169 +Node: Use org-like outlines47394 +Node: Concept Index48059 +Node: Command & Variable Index53575 +Node: Keystroke Index61685  End Tag Table diff --git a/lisp/llama/llama-pkg.el b/lisp/llama/llama-pkg.el new file mode 100644 index 00000000..92e26d0a --- /dev/null +++ b/lisp/llama/llama-pkg.el @@ -0,0 +1,9 @@ +(define-package "llama" "20250309.1622" "Compact syntax for short lambda" + '((emacs "26.1") + (compat "30.0.2.0")) + :commit "4d3141aceb70a1c672d1f4e9394037e2407d3a90" :keywords + '("extensions") + :url "https://github.com/tarsius/llama") +;; Local Variables: +;; no-byte-compile: t +;; End: diff --git a/lisp/llama/llama.el b/lisp/llama/llama.el new file mode 100644 index 00000000..ba5bcf07 --- /dev/null +++ b/lisp/llama/llama.el @@ -0,0 +1,552 @@ +;;; llama.el --- Compact syntax for short lambda -*- lexical-binding:t -*- + +;; Copyright (C) 2020-2025 Jonas Bernoulli + +;; Authors: Jonas Bernoulli +;; Homepage: https://github.com/tarsius/llama +;; Keywords: extensions + +;; Package-Version: 0.6.1 +;; Package-Requires: ((emacs "26.1") (compat "30.0.2.0")) + +;; SPDX-License-Identifier: GPL-3.0-or-later + +;; This file is free software: you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published +;; by the Free Software Foundation, either version 3 of the License, +;; or (at your option) any later version. +;; +;; This file is distributed in the hope that it will be useful, +;; but WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;; GNU General Public License for more details. +;; +;; You should have received a copy of the GNU General Public License +;; along with this file. If not, see . + +;;; Commentary: + +;; This package implements a macro named `##', which provides a compact way +;; to write short `lambda' expressions. + +;; The signature of the macro is (## FN &rest BODY) and it expands to a +;; `lambda' expression, which calls the function FN with the arguments BODY +;; and returns the value of that. The arguments of the `lambda' expression +;; are derived from symbols found in BODY. + +;; Each symbol from `%1' through `%9', which appears in an unquoted part +;; of BODY, specifies a mandatory argument. Each symbol from `&1' through +;; `&9', which appears in an unquoted part of BODY, specifies an optional +;; argument. The symbol `&*' specifies extra (`&rest') arguments. + +;; The shorter symbol `%' can be used instead of `%1', but using both in +;; the same expression is not allowed. Likewise `&' can be used instead +;; of `&1'. These shorthands are not recognized in function position. + +;; To support binding forms that use a vector as VARLIST (such as `-let' +;; from the `dash' package), argument symbols are also detected inside of +;; vectors. + +;; The space between `##' and FN can be omitted because `##' is read-syntax +;; for the symbol whose name is the empty string. If you prefer you can +;; place a space there anyway, and if you prefer to not use this somewhat +;; magical symbol at all, you can instead use the alternative name `llama'. + +;; Instead of: +;; +;; (lambda (a &optional _ c &rest d) +;; (foo a (bar c) d)) +;; +;; you can use this macro and write: +;; +;; (##foo %1 (bar &3) &*) +;; +;; which expands to: +;; +;; (lambda (%1 &optional _&2 &3 &rest &*) +;; (foo %1 (bar &3) &*)) + +;; Unused trailing arguments and mandatory unused arguments at the border +;; between mandatory and optional arguments are also supported: +;; +;; (##list %1 _%3 &5 _&6) +;; +;; becomes: +;; +;; (lambda (%1 _%2 _%3 &optional _&4 &5 _&6) +;; (list %1 &5)) +;; +;; Note how `_%3' and `_&6' are removed from the body, because their names +;; begin with an underscore. Also note that `_&4' is optional, unlike the +;; explicitly specified `_%3'. + +;;; Code: + +(require 'compat) + +;;;###autoload +(defmacro llama (fn &rest body) + "Expand to a `lambda' expression that wraps around FN and BODY. + +This macro provides a compact way to write short `lambda' expressions. +It expands to a `lambda' expression, which calls the function FN with +arguments BODY and returns its value. The arguments of the `lambda' +expression are derived from symbols found in BODY. + +Each symbol from `%1' through `%9', which appears in an unquoted part +of BODY, specifies a mandatory argument. Each symbol from `&1' through +`&9', which appears in an unquoted part of BODY, specifies an optional +argument. The symbol `&*' specifies extra (`&rest') arguments. + +The shorter symbol `%' can be used instead of `%1', but using both in +the same expression is not allowed. Likewise `&' can be used instead +of `&1'. These shorthands are not recognized in function position. + +To support binding forms that use a vector as VARLIST (such as `-let' +from the `dash' package), argument symbols are also detected inside of +vectors. + +The space between `##' and FN can be omitted because `##' is read-syntax +for the symbol whose name is the empty string. If you prefer you can +place a space there anyway, and if you prefer to not use this somewhat +magical symbol at all, you can instead use the alternative name `llama'. + +Instead of: + + (lambda (a &optional _ c &rest d) + (foo a (bar c) d)) + +you can use this macro and write: + + (##foo %1 (bar &3) &*) + +which expands to: + + (lambda (%1 &optional _&2 &3 &rest &*) + (foo %1 (bar &3) &*)) + +Unused trailing arguments and mandatory unused arguments at the border +between mandatory and optional arguments are also supported: + + (##list %1 _%3 &5 _&6) + +becomes: + + (lambda (%1 _%2 _%3 &optional _&4 &5 _&6) + (list %1 &5)) + +Note how `_%3' and `_&6' are removed from the body, because their names +begin with an underscore. Also note that `_&4' is optional, unlike the +explicitly specified `_%3'." + (cond ((symbolp fn)) + ((and (eq (car-safe fn) backquote-backquote-symbol) + (not body)) + (setq body (cdr fn)) + (setq fn backquote-backquote-symbol)) + ((signal 'wrong-type-argument + (list 'symbolp backquote-backquote-symbol fn)))) + (let* ((args (make-vector 10 nil)) + (body (cdr (llama--collect (cons fn body) args))) + (rest (aref args 0)) + (args (nreverse (cdr (append args nil)))) + (args (progn (while (and args (null (car args))) + (setq args (cdr args))) + args)) + (pos (length args)) + (opt nil) + (args (mapcar + (lambda (arg) + (if arg + (setq opt (string-match-p "\\`_?&" (symbol-name arg))) + (setq arg (intern (format "_%c%s" (if opt ?& ?%) pos)))) + (setq pos (1- pos)) + arg) + args)) + (opt nil) + (args (mapcar + (lambda (symbol) + (cond + ((string-match-p "\\`_?%" (symbol-name symbol)) + (when opt + (error "`%s' cannot follow optional arguments" symbol)) + (list symbol)) + (opt + (list symbol)) + ((setq opt t) + (list '&optional symbol)))) + (nreverse args)))) + `(lambda + (,@(apply #'nconc args) + ,@(and rest (list '&rest rest))) + (,fn ,@body)))) + +(defalias (intern "") 'llama) +(defalias '\#\# 'llama) + +(defconst llama--unused-argument (make-symbol "llama--unused-argument")) + +(defun llama--collect (expr args &optional fnpos backquoted unquote) + (cond + ((memq (car-safe expr) (list (intern "") 'llama 'quote)) expr) + ((and backquoted (symbolp expr)) expr) + ((and backquoted + (memq (car-safe expr) + (list backquote-unquote-symbol + backquote-splice-symbol))) + (list (car expr) + (llama--collect (cadr expr) args nil nil t))) + ((memq (car-safe expr) + (list backquote-backquote-symbol + backquote-splice-symbol)) + (list (car expr) + (llama--collect (cadr expr) args nil t))) + ((symbolp expr) + (let ((name (symbol-name expr))) + (save-match-data + (cond + ((string-match "\\`\\(_\\)?[%&]\\([1-9*]\\)?\\'" name) + (let* ((pos (match-string 2 name)) + (pos (cond ((equal pos "*") 0) + ((not pos) 1) + ((string-to-number pos)))) + (sym (aref args pos))) + (unless (and fnpos (not unquote) (memq expr '(% &))) + (when (and sym (not (equal expr sym))) + (error "`%s' and `%s' are mutually exclusive" sym expr)) + (aset args pos expr))) + (if (match-string 1 name) + llama--unused-argument + expr)) + (expr))))) + ((or (listp expr) + (vectorp expr)) + (let* ((vectorp (vectorp expr)) + (expr (if vectorp (append expr ()) expr)) + (fnpos (and (not vectorp) + (not backquoted) + (ignore-errors (length expr)))) ;proper-list-p + (ret ())) + (catch t + (while t + (let ((elt (llama--collect (car expr) args fnpos backquoted))) + (unless (eq elt llama--unused-argument) + (push elt ret))) + (setq fnpos nil) + (setq expr (cdr expr)) + (unless (and expr + (listp expr) + (not (eq (car expr) backquote-unquote-symbol))) + (throw t nil)))) + (setq ret (nreverse ret)) + (when expr + (setcdr (last ret) (llama--collect expr args nil backquoted))) + (if vectorp (vconcat ret) ret))) + (expr))) + +;;; Advices + +(define-advice elisp--expect-function-p (:around (fn pos) llama) + "Support function completion directly following `##'." + (or (and (eq (char-before pos) ?#) + (eq (char-before (- pos 1)) ?#)) + (and (eq (char-before pos) ?\s) + (eq (char-before (- pos 1)) ?#) + (eq (char-before (- pos 2)) ?#)) + (funcall fn pos))) + +(define-advice elisp-mode-syntax-propertize (:override (start end) llama) + ;; Synced with Emacs up to 6b9510d94f814cacf43793dce76250b5f7e6f64a. + "Like `elisp-mode-syntax-propertize' but don't change syntax of `##'." + (goto-char start) + (let ((case-fold-search nil)) + (funcall + (syntax-propertize-rules + ;; Empty symbol. + ;; {{ Comment out to prevent the `##' from becoming part of + ;; the following symbol when there is no space in between. + ;; ("##" (0 (unless (nth 8 (syntax-ppss)) + ;; (string-to-syntax "_")))) + ;; }} + ;; {{ As for other symbols, use `font-lock-constant-face' in + ;; docstrings and comments. + ("##" (0 (when (nth 8 (syntax-ppss)) + (string-to-syntax "_")))) + ;; }} + ;; {{ Preserve this part, even though it is absent from + ;; this function in 29.1; backporting it by association. + ;; Prevent the @ from becoming part of a following symbol. + (",@" (0 (unless (nth 8 (syntax-ppss)) + (string-to-syntax "'")))) + ;; }} + ;; Unicode character names. (The longest name is 88 characters + ;; long.) + ("\\?\\\\N{[-A-Za-z0-9 ]\\{,100\\}}" + (0 (unless (nth 8 (syntax-ppss)) + (string-to-syntax "_")))) + ((rx "#" (or (seq (group-n 1 "&" (+ digit)) ?\") ; Bool-vector. + (seq (group-n 1 "s") "(") ; Record. + (seq (group-n 1 (+ "^")) "["))) ; Char-table. + (1 (unless (save-excursion (nth 8 (syntax-ppss (match-beginning 0)))) + (string-to-syntax "'"))))) + start end))) + +(define-advice all-completions (:around (fn str table &rest rest) llama) + "Remove empty symbol from completion results if originating from `llama'. + +`##' is the notation for the symbol whose name is the empty string. + (intern \"\") => ## + (symbol-name \\='##) => \"\" + +The `llama' package uses `##' as the name of a macro, which allows +it to be used akin to syntax, without actually being new syntax. +\(`describe-function' won't let you select `##', but because that is an +alias for `llama', you can access the documentation under that name.) + +This advice prevents the empty string from being offered as a completion +candidate when `obarray' or a completion table that internally uses +that is used as TABLE." + (let ((result (apply fn str table rest))) + (if (and (eq obarray table) (equal str "")) + (delete "" result) + result))) + +(defvar llama-fontify-mode) + +(define-advice lisp--el-match-keyword (:override (limit) llama -80) + (catch 'found + (while (re-search-forward + (concat (if llama-fontify-mode + "(\\(?:## ?\\)?\\(" + "(\\(") + (static-if (get 'lisp-mode-symbol 'rx-definition) ;>= 29.1 + (rx lisp-mode-symbol) + lisp-mode-symbol-regexp) + "\\)\\_>") + limit t) + (let ((sym (intern-soft (match-string 1)))) + (when (and (or (special-form-p sym) + (macrop sym) + ;; Same as in advice of `morlock' package. + (get sym 'morlock-font-lock-keyword)) + (not (get sym 'no-font-lock-keyword)) + (static-if (fboundp 'lisp--el-funcall-position-p) ;>= 28.1 + (lisp--el-funcall-position-p (match-beginning 0)) + (not (lisp--el-non-funcall-position-p + (match-beginning 0))))) + (throw 'found t)))))) + +;;; Fontification + +(defgroup llama () + "Compact syntax for short lambda." + :group 'extensions + :group 'lisp) + +(defface llama-\#\#-macro '((t :inherit font-lock-function-call-face)) + "Face used for the name of the `##' macro.") + +(defface llama-llama-macro '((t :inherit font-lock-keyword-face)) + "Face used for the name of the `llama' macro.") + +(defface llama-mandatory-argument '((t :inherit font-lock-variable-use-face)) + "Face used for mandatory arguments `%1' through `%9' and `%'.") + +(defface llama-optional-argument '((t :inherit font-lock-type-face)) + "Face used for optional arguments `&1' through `&9', `&' and `&*'.") + +(defface llama-deleted-argument + `((((supports :box t)) + :box ( :line-width ,(if (>= emacs-major-version 28) (cons -1 -1) -1) + :color "red" + :style nil)) + (((supports :underline t)) + :underline "red") + (t + :inherit font-lock-warning-face)) + "Face used for deleted arguments `_%1'...`_%9', `_&1'...`_&9' and `_&*'. +This face is used in addition to one of llama's other argument faces. +Unlike implicit unused arguments (which do not appear in the function +body), these arguments are deleted from the function body during macro +expansion, and the looks of this face should hint at that.") + +(defconst llama-font-lock-keywords-28 + '(("(\\(##\\)" 1 'llama-\#\#-macro) + ("(\\(llama\\)\\_>" 1 'llama-llama-macro) + ("\\_<\\(?:_?%[1-9]?\\)\\_>" + 0 (llama--maybe-face 'llama-mandatory-argument)) + ("\\_<\\(?:_?&[1-9*]?\\)\\_>" + 0 (llama--maybe-face 'llama-optional-argument)) + ("\\_<\\(?:_\\(?:%[1-9]?\\|&[1-9*]?\\)\\)\\_>" + 0 'llama-deleted-argument prepend))) + +(defconst llama-font-lock-keywords-29 + `(("\\_<\\(&[1-9*]?\\)\\_>" 1 'default) + (,(apply-partially #'llama--match-and-fontify "(\\(##\\)") + 1 'llama-\#\#-macro) + (,(apply-partially #'llama--match-and-fontify "(\\(llama\\_>\\)") + 1 'llama-llama-macro))) + +(defvar llama-font-lock-keywords + (if (fboundp 'read-positioning-symbols) + llama-font-lock-keywords-29 + llama-font-lock-keywords-28)) + +(defun llama--maybe-face (face) + (and (not (and (member (match-string 0) '("%" "&")) + (and-let* ((beg (ignore-errors + (scan-lists (match-beginning 0) -1 1)))) + (string-match-p "\\`\\(##\\|llama\\_>\\)?[\s\t\n\r]*\\'" + (buffer-substring-no-properties + (1+ beg) (match-beginning 0)))))) + face)) + +(defun llama--match-and-fontify (re end) + (static-if (fboundp 'bare-symbol) + (and (re-search-forward re end t) + (prog1 t + (save-excursion + (goto-char (match-beginning 0)) + (when-let (((save-match-data (not (nth 8 (syntax-ppss))))) + (expr (ignore-errors + (read-positioning-symbols (current-buffer))))) + (put-text-property (match-beginning 0) (point) + 'font-lock-multiline t) + (llama--fontify (cdr expr) nil nil t))))) + (list re end))) ; Silence compiler. + +(defun llama--fontify (expr &optional fnpos backquoted top) + (static-if (fboundp 'bare-symbol) + (cond + ((null expr) expr) + ((eq (car-safe expr) 'quote)) + ((eq (ignore-errors (bare-symbol (car-safe expr))) 'quote)) + ((and (memq (ignore-errors (bare-symbol (car-safe expr))) + (list (intern "") 'llama)) + (not top))) + ((and backquoted (symbol-with-pos-p expr))) + ((and backquoted + (memq (car-safe expr) + (list backquote-unquote-symbol + backquote-splice-symbol))) + (llama--fontify expr)) + ((symbol-with-pos-p expr) + (save-match-data + (when-let* + ((name (symbol-name (bare-symbol expr))) + (face (cond + ((and (string-match + "\\_<\\(?:\\(_\\)?%\\([1-9]\\)?\\)\\_>" name) + (or (not fnpos) (match-end 2))) + 'llama-mandatory-argument) + ((and (string-match + "\\_<\\(?:\\(_\\)?&\\([1-9*]\\)?\\)\\_>" name) + (or (not fnpos) (match-end 2))) + 'llama-optional-argument)))) + (when (match-end 1) + (setq face (list 'llama-deleted-argument face))) + (let ((beg (symbol-with-pos-pos expr))) + (put-text-property + beg (save-excursion (goto-char beg) (forward-symbol 1)) + 'face face))))) + ((or (listp expr) + (vectorp expr)) + (let* ((vectorp (vectorp expr)) + (expr (if vectorp (append expr ()) expr)) + (fnpos (and (not vectorp) + (not backquoted) + (ignore-errors (length expr))))) + (catch t + (while t + (cond ((eq (car expr) backquote-backquote-symbol) + (setq expr (cdr expr)) + (llama--fontify (car expr) t t)) + ((llama--fontify (car expr) fnpos backquoted))) + (setq fnpos nil) + (setq expr (cdr expr)) + (unless (and expr + (listp expr) + (not (eq (car expr) backquote-unquote-symbol))) + (throw t nil)))) + (when expr + (llama--fontify expr fnpos)))))) + (list expr fnpos backquoted top)) ; Silence compiler. + +(defvar llama-fontify-mode-lighter nil) + +;;;###autoload +(define-minor-mode llama-fontify-mode + "Toggle fontification of the `##' macro and its positional arguments." + :lighter llama-fontify-mode-lighter + (if llama-fontify-mode + (font-lock-add-keywords nil llama-font-lock-keywords) + (font-lock-remove-keywords nil llama-font-lock-keywords))) + +(defun llama--turn-on-fontify-mode () + "Enable `llama-fontify-mode' if in an Emacs Lisp buffer." + (when (derived-mode-p #'emacs-lisp-mode) + (llama-fontify-mode))) + +;;;###autoload +(define-globalized-minor-mode global-llama-fontify-mode + llama-fontify-mode llama--turn-on-fontify-mode) + +;;; Partial applications + +(defun llama--left-apply-partially (fn &rest args) + "Return a function that is a partial application of FN to ARGS. + +ARGS is a list of the first N arguments to pass to FN. The result +is a new function which does the same as FN, except that the first N +arguments are fixed at the values with which this function was called. + +See also `llama--right-apply-partially', which instead fixes the last +N arguments. + +These functions are intended to be used using the names `partial' and +`rpartial'. To be able to use these shorthands in a file, you must set +the file-local value of `read-symbols-shorthands', which was added in +Emacs 28.1. For an example see the end of file \"llama.el\". + +This is an alternative to `apply-partially', whose name is too long." + (declare (pure t) (side-effect-free error-free)) + (lambda (&rest args2) + (apply fn (append args args2)))) + +(defun llama--right-apply-partially (fn &rest args) + "Return a function that is a right partial application of FN to ARGS. + +ARGS is a list of the last N arguments to pass to FN. The result +is a new function which does the same as FN, except that the last N +arguments are fixed at the values with which this function was called. + +See also `llama--left-apply-partially', which instead fixes the first +N arguments. + +These functions are intended to be used using the names `rpartial' and +`partial'. To be able to use these shorthands in a file, you must set +the file-local value of `read-symbols-shorthands', which was added in +Emacs 28.1. For an example see the end of file \"llama.el\"." + (declare (pure t) (side-effect-free error-free)) + (lambda (&rest args2) + (apply fn (append args2 args)))) + +;; An example of how one would use these functions: +;; +;; (list (funcall (partial (lambda (a b) (list a b)) 'fixed) 'after) +;; (funcall (rpartial (lambda (a b) (list a b)) 'fixed) 'before)) + +;; An example of the configuration that is necessary to enable this: +;; +;; Local Variables: +;; indent-tabs-mode: nil +;; read-symbol-shorthands: ( +;; ("partial" . "llama--left-apply-partially") +;; ("rpartial" . "llama--right-apply-partially")) +;; End: +;; +;; Do not set `read-symbol-shorthands' in the ".dir-locals.el" +;; file, because that does not work for uncompiled libraries. + +(provide 'llama) + +;;; llama.el ends here diff --git a/lisp/magit-section/magit-section-pkg.el b/lisp/magit-section/magit-section-pkg.el index f2df0d9d..a1d3da54 100644 --- a/lisp/magit-section/magit-section-pkg.el +++ b/lisp/magit-section/magit-section-pkg.el @@ -1,9 +1,9 @@ -(define-package "magit-section" "20250221.105" "Sections for read-only buffers" +(define-package "magit-section" "20250307.1739" "Sections for read-only buffers" '((emacs "27.1") (compat "30.0.2.0") - (llama "0.6.0") + (llama "0.6.1") (seq "2.24")) - :commit "3ad94012b0f570809c52eb3323fa1436e180984e" :authors + :commit "3f79700f1b9a6f5f6fd6a77fd1e812c1b8e6463b" :authors '(("Jonas Bernoulli" . "emacs.magit@jonas.bernoulli.dev")) :maintainers '(("Jonas Bernoulli" . "emacs.magit@jonas.bernoulli.dev")) diff --git a/lisp/magit-section/magit-section.el b/lisp/magit-section/magit-section.el index e5a43d6e..5ddd990a 100644 --- a/lisp/magit-section/magit-section.el +++ b/lisp/magit-section/magit-section.el @@ -8,11 +8,11 @@ ;; Homepage: https://github.com/magit/magit ;; Keywords: tools -;; Package-Version: 4.3.0 +;; Package-Version: 4.3.1 ;; Package-Requires: ( ;; (emacs "27.1") ;; (compat "30.0.2.0") -;; (llama "0.6.0") +;; (llama "0.6.1") ;; (seq "2.24")) ;; SPDX-License-Identifier: GPL-3.0-or-later @@ -396,8 +396,7 @@ no effect. This also has no effect for Emacs >= 28, where (defvar-keymap magit-section-heading-map :doc "Keymap used in the heading line of all expandable sections. -This keymap is used in addition to the section-specific keymap, -if any." +This keymap is used in addition to the section-specific keymap, if any." "" #'ignore "" #'magit-mouse-toggle-section "" #'magit-mouse-toggle-section) @@ -1392,7 +1391,7 @@ anything this time around. (pcase-let* ((bind (and (symbolp (car args)) (pop args))) (`((,class ,value ,hide . ,args) . ,body) args) - (obj (cl-gensym "section"))) + (obj (gensym "section"))) `(let* ((,obj (magit-insert-section--create ,(if (eq (car-safe class) 'eval) (cadr class) `',class) ,value ,hide ,@args)) @@ -1448,47 +1447,33 @@ anything this time around. (defun magit-insert-section--finish (obj) (run-hooks 'magit-insert-section-hook) - (let ((beg (oref obj start)) - (end (oset obj end - (if magit-section-inhibit-markers - (point) - (point-marker)))) - (props `( magit-section ,obj - ,@(and-let* ((map (symbol-value (oref obj keymap)))) - (list 'keymap map))))) - (unless magit-section-inhibit-markers - (set-marker-insertion-type beg t)) - (cond ((eq obj magit-root-section)) - ((oref obj children) - (magit-insert-child-count obj) - (magit-section-maybe-add-heading-map obj) - (save-excursion - (goto-char beg) - (while (< (point) end) - (let ((next (or (next-single-property-change - (point) 'magit-section) - end))) - (unless (magit-section-at) - (add-text-properties (point) next props)) - (goto-char next))))) - ((add-text-properties beg end props))) - (cond ((eq obj magit-root-section) - (when (eq magit-section-inhibit-markers 'delay) - (setq magit-section-inhibit-markers nil) - (magit-map-sections - (lambda (section) - (oset section start (copy-marker (oref section start) t)) - (oset section end (copy-marker (oref section end) t))))) - (let ((magit-section-cache-visibility nil)) - (magit-section-show obj))) - (magit-section-insert-in-reverse - (push obj (oref (oref obj parent) children))) - ((let ((parent (oref obj parent))) - (oset parent children - (nconc (oref parent children) - (list obj)))))) - (when magit-section-insert-in-reverse - (oset obj children (nreverse (oref obj children)))))) + (if magit-section-inhibit-markers + (oset obj end (point)) + (oset obj end (point-marker)) + (set-marker-insertion-type (oref obj start) t)) + (cond + ((eq obj magit-root-section) + (when (eq magit-section-inhibit-markers 'delay) + (setq magit-section-inhibit-markers nil) + (magit-map-sections + (lambda (section) + (oset section start (copy-marker (oref section start) t)) + (oset section end (copy-marker (oref section end) t))))) + (let ((magit-section-cache-visibility nil)) + (magit-section-show obj))) + (t + (magit-section--set-section-properties obj) + (magit-section-maybe-add-heading-map obj) + (when (oref obj children) + (magit-insert-child-count obj)) + (if magit-section-insert-in-reverse + (push obj (oref (oref obj parent) children)) + (let ((parent (oref obj parent))) + (oset parent children + (nconc (oref parent children) + (list obj))))))) + (when magit-section-insert-in-reverse + (oset obj children (nreverse (oref obj children))))) (defun magit-cancel-section (&optional if-empty) "Cancel inserting the section that is currently being inserted. @@ -1574,9 +1559,9 @@ If the section is expanded when it is created, then this is like `progn'. Otherwise BODY isn't evaluated until the section is explicitly expanded." (declare (indent 0)) - (let ((f (cl-gensym)) - (s (cl-gensym)) - (l (cl-gensym))) + (let ((f (gensym)) + (s (gensym)) + (l (gensym))) `(let ((,f (lambda () ,@body))) (if (oref magit-insert-section--current hidden) (oset magit-insert-section--current washer @@ -1588,6 +1573,7 @@ is explicitly expanded." (funcall ,f) (dolist (s ,l) (set-marker-insertion-type (oref s end) nil)) + (magit-section--set-section-properties ,s) (magit-section-maybe-remove-heading-map ,s) (magit-section-maybe-remove-visibility-indicator ,s))))) (funcall ,f))))) @@ -1615,6 +1601,22 @@ is explicitly expanded." (magit-section-maybe-add-heading-map 1st-header))))) (remove-hook 'magit-insert-section-hook fn t)))) +(defun magit-section--set-section-properties (section) + (pcase-let* (((eieio start end children keymap) section) + (props `( magit-section ,section + ,@(and-let* ((map (symbol-value keymap))) + (list 'keymap map))))) + (if children + (save-excursion + (goto-char start) + (while (< (point) end) + (let ((next (or (next-single-property-change (point) 'magit-section) + end))) + (unless (magit-section-at) + (add-text-properties (point) next props)) + (goto-char next)))) + (add-text-properties start end props)))) + (defun magit-section-maybe-add-heading-map (section) (when (magit-section-content-p section) (let ((start (oref section start)) diff --git a/lisp/magit-section/magit-section.info b/lisp/magit-section/magit-section.info index d336cac1..e082a0cb 100644 --- a/lisp/magit-section/magit-section.info +++ b/lisp/magit-section/magit-section.info @@ -1,4 +1,4 @@ -This is magit-section.info, produced by makeinfo version 6.8 from +This is magit-section.info, produced by makeinfo version 7.1.1 from magit-section.texi. Copyright (C) 2015-2025 Jonas Bernoulli @@ -34,7 +34,7 @@ packages that have nothing to do with Magit or Git. and user options see *note (magit)Sections::. This manual documents how you can use sections in your own packages. -This manual is for Magit-Section version 4.3.0. +This manual is for Magit-Section version 4.3.1. Copyright (C) 2015-2025 Jonas Bernoulli @@ -85,17 +85,17 @@ File: magit-section.info, Node: Creating Sections, Next: Core Functions, Prev body Create a section object of type CLASS, storing VALUE in its ‘value’ slot, and insert the section at point. CLASS is a subclass of - ‘magit-section’ or has the form ‘(eval FORM)’, in which case FORM + 'magit-section' or has the form ‘(eval FORM)’, in which case FORM is evaluated at runtime and should return a subclass. In other places a sections class is often referred to as its "type". Many commands behave differently depending on the class of the current section and sections of a certain class can have their own - keymap, which is specified using the ‘keymap’ class slot. The + keymap, which is specified using the 'keymap' class slot. The value of that slot should be a variable whose value is a keymap. For historic reasons Magit and Forge in most cases use symbols as - CLASS that don’t actually identify a class and that lack the + CLASS that don't actually identify a class and that lack the appropriate package prefix. This works due to some undocumented kludges, which are not available to other packages. @@ -106,19 +106,19 @@ File: magit-section.info, Node: Creating Sections, Next: Core Functions, Prev during a refresh, then the visibility of predecessor is inherited and HIDE is ignored (but the hook is still honored). - BODY is any number of forms that actually insert the section’s + BODY is any number of forms that actually insert the section's heading and body. Optional NAME, if specified, has to be a symbol, which is then bound to the object of the section being inserted. Before BODY is evaluated the ‘start’ of the section object is set - to the value of ‘point’ and after BODY was evaluated its ‘end’ is + to the value of 'point' and after BODY was evaluated its ‘end’ is set to the new value of ‘point’; BODY is responsible for moving ‘point’ forward. If it turns out inside BODY that the section is empty, then ‘magit-cancel-section’ can be used to abort and remove all traces of the partially inserted section. This can happen when creating a - section by washing Git’s output and Git didn’t actually output + section by washing Git's output and Git didn't actually output anything this time around. -- Function: magit-insert-heading [child-count] &rest args @@ -136,7 +136,7 @@ File: magit-section.info, Node: Creating Sections, Next: Core Functions, Prev any text before this happens and afterwards it should again only contain a single line. If the ‘face’ property is set anywhere inside any of these strings, then insert all of them unchanged. - Otherwise use the ‘magit-section-heading’ face for all inserted + Otherwise use the 'magit-section-heading' face for all inserted text. The ‘content’ property of the section object is the end of the @@ -145,7 +145,7 @@ File: magit-section.info, Node: Creating Sections, Next: Core Functions, Prev value of ‘content’ is nil, then the section has no heading and its body cannot be collapsed. If a section does have a heading, then its height must be exactly one line, including a trailing newline - character. This isn’t enforced, you are responsible for getting it + character. This isn't enforced, you are responsible for getting it right. The only exception is that this function does insert a newline character if necessary. @@ -159,7 +159,7 @@ File: magit-section.info, Node: Creating Sections, Next: Core Functions, Prev -- Macro: magit-insert-section-body &rest body Use BODY to insert the section body, once the section is expanded. If the section is expanded when it is created, then this is like - ‘progn’. Otherwise BODY isn’t evaluated until the section is + ‘progn’. Otherwise BODY isn't evaluated until the section is explicitly expanded. -- Function: magit-cancel-section @@ -254,13 +254,13 @@ File: magit-section.info, Node: Matching Functions, Prev: Core Functions, Up: CONDITION can take the following forms: • ‘(CONDITION...)’ matches if any of the CONDITIONs matches. - • ‘[CLASS...]’ matches if the section’s class is the same as the - first CLASS or a subclass of that; the section’s parent class + • ‘[CLASS...]’ matches if the section's class is the same as the + first CLASS or a subclass of that; the section's parent class matches the second CLASS; and so on. • ‘[* CLASS...]’ matches sections that match [CLASS...] and also recursively all their child sections. - • ‘CLASS’ matches if the section’s class is the same as CLASS or + • ‘CLASS’ matches if the section's class is the same as CLASS or a subclass of that; regardless of the classes of the parent sections. @@ -303,11 +303,11 @@ File: magit-section.info, Node: Matching Functions, Prev: Core Functions, Up:  Tag Table: -Node: Top808 -Node: Introduction2109 -Node: Creating Sections2879 -Node: Core Functions7812 -Node: Matching Functions10964 +Node: Top810 +Node: Introduction2111 +Node: Creating Sections2881 +Node: Core Functions7786 +Node: Matching Functions10938  End Tag Table diff --git a/lisp/magit/AUTHORS.md b/lisp/magit/AUTHORS.md index 8e308519..e0a1aea4 100644 --- a/lisp/magit/AUTHORS.md +++ b/lisp/magit/AUTHORS.md @@ -103,6 +103,7 @@ All Contributors - Clément Pit-Claudel - Cornelius Mika - Craig Andera +- Curt Brune - Daanturo - Dale Hagglund - Damien Cassou diff --git a/lisp/magit/magit-apply.el b/lisp/magit/magit-apply.el index 1c526cac..b0edf978 100644 --- a/lisp/magit/magit-apply.el +++ b/lisp/magit/magit-apply.el @@ -378,32 +378,32 @@ ignored) files." "--" plain) (when magit-auto-revert-mode (mapc #'magit-turn-on-auto-revert-mode-if-desired plain))) - (dolist (repo repos) - (save-excursion - (goto-char (oref (magit-get-section - `((file . ,repo) (untracked) (status))) - start)) - (when (and (fboundp 'borg-assimilate) - (fboundp 'borg--maybe-absorb-gitdir) - (fboundp 'borg--sort-submodule-sections)) - (let* ((topdir (magit-toplevel)) - (url (let ((default-directory - (file-name-as-directory (expand-file-name repo)))) - (or (magit-get "remote" (magit-get-some-remote) "url") - (concat (file-name-as-directory ".") repo)))) - (package - (and (equal borg-user-emacs-directory topdir) - (file-name-nondirectory (directory-file-name repo))))) - (if (and package - (y-or-n-p (format "Also assimilate `%s' drone?" package))) - (borg-assimilate package url) - (magit-submodule-add-1 - url repo (magit-submodule-read-name-for-path repo package)) - (when package - (borg--sort-submodule-sections - (expand-file-name ".gitmodules" topdir)) - (let ((default-directory borg-user-emacs-directory)) - (borg--maybe-absorb-gitdir package)))))))) + (when (and (fboundp 'borg-assimilate) + (fboundp 'borg--maybe-absorb-gitdir) + (fboundp 'borg--sort-submodule-sections)) + (dolist (repo repos) + (save-excursion + (when-let ((section (magit-get-section + `((file . ,repo) (untracked) (status))))) + (goto-char (oref section start)) + (let* ((topdir (magit-toplevel)) + (url (let ((default-directory + (file-name-as-directory (expand-file-name repo)))) + (or (magit-get "remote" (magit-get-some-remote) "url") + (concat (file-name-as-directory ".") repo)))) + (package + (and (equal borg-user-emacs-directory topdir) + (file-name-nondirectory (directory-file-name repo))))) + (if (and package + (y-or-n-p (format "Also assimilate `%s' drone?" package))) + (borg-assimilate package url) + (magit-submodule-add-1 + url repo (magit-submodule-read-name-for-path repo package)) + (when package + (borg--sort-submodule-sections + (expand-file-name ".gitmodules" topdir)) + (let ((default-directory borg-user-emacs-directory)) + (borg--maybe-absorb-gitdir package))))))))) (magit-wip-commit-after-apply files " after stage"))) (defvar magit-post-stage-hook-commands diff --git a/lisp/magit/magit-base.el b/lisp/magit/magit-base.el index 3a17b146..7007a648 100644 --- a/lisp/magit/magit-base.el +++ b/lisp/magit/magit-base.el @@ -129,11 +129,11 @@ The value has the form ((COMMAND nil|PROMPT DEFAULT)...). :group 'magit-commands :type '(repeat (list (symbol :tag "Command") ; It might not be fboundp yet. - (choice (const :tag "for all prompts" nil) - (regexp :tag "for prompts matching regexp")) - (choice (const :tag "offer other choices" nil) - (const :tag "require confirmation" ask) - (const :tag "use default without confirmation" t))))) + (choice (const :tag "For all prompts" nil) + (regexp :tag "For prompts matching regexp")) + (choice (const :tag "Offer other choices" nil) + (const :tag "Require confirmation" ask) + (const :tag "Use default without confirmation" t))))) (defconst magit--confirm-actions '((const discard) @@ -329,7 +329,7 @@ Various: Global settings: Instead of adding all of the above symbols to the value of this - option you can also set it to the atom t, which has the same + option you can also set it to the atom `t', which has the same effect as adding all of the above symbols. Doing that most certainly is a bad idea, especially because other symbols might be added in the future. So even if you don't want to be asked @@ -467,9 +467,9 @@ and delay of your graphical environment or operating system." `woman' View the respective man-page using the `woman' package." :package-version '(magit . "2.9.0") :group 'magit-miscellaneous - :type '(choice (const :tag "view info manual" info) - (const :tag "view manpage using `man'" man) - (const :tag "view manpage using `woman'" woman))) + :type '(choice (const :tag "View info manual" info) + (const :tag "View manpage using `man'" man) + (const :tag "View manpage using `woman'" woman))) ;;; Section Classes @@ -908,7 +908,7 @@ data, starting with 1 and incrementing by 1 for each symbol. If the last match was against a string, then that has to be provided as STRING." (declare (indent 2) (debug (listp form body))) - (let ((s (cl-gensym "string")) + (let ((s (gensym "string")) (i 0)) `(let ((,s ,string)) (let ,(save-match-data diff --git a/lisp/magit/magit-branch.el b/lisp/magit/magit-branch.el index fca914f1..e373c281 100644 --- a/lisp/magit/magit-branch.el +++ b/lisp/magit/magit-branch.el @@ -38,17 +38,17 @@ (defcustom magit-branch-read-upstream-first t "Whether to read upstream before name of new branch when creating a branch. -nil Read the branch name first. -t Read the upstream first. +`nil' Read the branch name first. +`t' Read the upstream first. `fallback' Read the upstream first, but if it turns out that the chosen value is not a valid upstream (because it cannot be resolved as an existing revision), then treat it as the name of the new branch and continue by reading the upstream next." :package-version '(magit . "2.2.0") :group 'magit-commands - :type '(choice (const :tag "read branch name first" nil) - (const :tag "read upstream first" t) - (const :tag "read upstream first, with fallback" fallback))) + :type '(choice (const :tag "Read branch name first" nil) + (const :tag "Read upstream first" t) + (const :tag "Read upstream first, with fallback" fallback))) (defcustom magit-branch-prefer-remote-upstream nil "Whether to favor remote upstreams when creating new branches. @@ -154,10 +154,10 @@ However, I recommend that you use local branches as UPSTREAM." :package-version '(magit . "2.9.0") :group 'magit-commands :type '(repeat (cons (string :tag "Use upstream") - (choice :tag "for branches" - (regexp :tag "matching") - (repeat :tag "except" - (string :tag "branch")))))) + (choice :tag "For branches" ;??? + (regexp :tag "Matching") + (repeat :tag "Except" + (string :tag "Branch")))))) (defcustom magit-branch-rename-push-target t "Whether the push-remote setup is preserved when renaming a branch. @@ -177,7 +177,7 @@ When t, then rename the branch named OLD on the remote specified remote and unless NEW already exists on the remote. When `forge-only' and the `forge' package is available, then - behave like t if the remote points to a repository on a forge + behave like `t' if the remote points to a repository on a forge (currently Github or Gitlab), otherwise like `local-only'." :package-version '(magit . "2.90.0") :group 'magit-commands diff --git a/lisp/magit/magit-clone.el b/lisp/magit/magit-clone.el index f7704369..42187eb3 100644 --- a/lisp/magit/magit-clone.el +++ b/lisp/magit/magit-clone.el @@ -43,9 +43,9 @@ If t, then set without asking. If nil, then don't set. If `ask', then ask." :package-version '(magit . "2.4.0") :group 'magit-commands - :type '(choice (const :tag "set" t) - (const :tag "ask" ask) - (const :tag "don't set" nil))) + :type '(choice (const :tag "Set" t) + (const :tag "Ask" ask) + (const :tag "Don't set" nil))) (defcustom magit-clone-default-directory nil "Default directory to use when `magit-clone' reads destination. @@ -54,9 +54,9 @@ If a directory, then use that. If a function, then call that with the remote url as only argument and use the returned value." :package-version '(magit . "2.90.0") :group 'magit-commands - :type '(choice (const :tag "value of default-directory") - (directory :tag "constant directory") - (function :tag "function's value"))) + :type '(choice (const :tag "Value of default-directory") + (directory :tag "Constant directory") + (function :tag "Function's value"))) (defcustom magit-clone-always-transient nil "Whether `magit-clone' always acts as a transient prefix command. diff --git a/lisp/magit/magit-commit.el b/lisp/magit/magit-commit.el index 1b0c4fb4..e8b84383 100644 --- a/lisp/magit/magit-commit.el +++ b/lisp/magit/magit-commit.el @@ -148,7 +148,10 @@ Also see https://github.com/magit/magit/issues/4132." ("W" "Revise" magit-commit-revise)] ["Edit and rebase" ("F" "Instant fixup" magit-commit-instant-fixup) - ("S" "Instant squash" magit-commit-instant-squash)] + ("S" "Instant squash" magit-commit-instant-squash) + "" + "" + ("R" "Reword past" magit-rebase-reword-commit :level 0)] ["Spread across commits" ("x" "Modified files" magit-commit-autofixup :level 6) ("X" "Updated modules" magit-commit-absorb-modules :level 6)]] diff --git a/lisp/magit/magit-diff.el b/lisp/magit/magit-diff.el index bf47e03c..cf98b2a0 100644 --- a/lisp/magit/magit-diff.el +++ b/lisp/magit/magit-diff.el @@ -193,8 +193,8 @@ keep their distinct foreground colors." (defcustom magit-diff-refine-hunk nil "Whether to show word-granularity differences within diff hunks. -nil Never show fine differences. -t Show fine differences for the current diff hunk only. +`nil' Never show fine differences. +`t' Show fine differences for the current diff hunk only. `all' Show fine differences for all displayed diff hunks." :group 'magit-diff :safe (lambda (val) (memq val '(nil t all))) @@ -217,13 +217,13 @@ t Show fine differences for the current diff hunk only. Determining the correct width can be expensive if it requires opening large and/or many files, so the widths are cached in -the variable `magit-diff--tab-width-cache'. Set that to nil +the variable `magit-diff--tab-width-cache'. Set that to `nil' to invalidate the cache. -nil Never adjust tab width. Use `tab-width's value from +`nil' Never adjust tab width. Use `tab-width's value from the Magit buffer itself instead. -t If the corresponding file-visiting buffer exits, then +`t' If the corresponding file-visiting buffer exits, then use `tab-width's value from that buffer. Doing this is cheap, so this value is used even if a corresponding cache entry exists. @@ -243,8 +243,8 @@ NUMBER Like `always', but don't visit files larger than NUMBER (defcustom magit-diff-paint-whitespace t "Specify where to highlight whitespace errors. -nil Never highlight whitespace errors. -t Highlight whitespace errors everywhere. +`nil' Never highlight whitespace errors. +`t' Highlight whitespace errors everywhere. `uncommitted' Only highlight whitespace errors in diffs showing uncommitted changes. @@ -266,15 +266,15 @@ whitespace errors are highlighted." (defcustom magit-diff-paint-whitespace-lines t "Specify in what kind of lines to highlight whitespace errors. -t Highlight only in added lines. +`t' Highlight only in added lines. `both' Highlight in added and removed lines. `all' Highlight in added, removed and context lines." :package-version '(magit . "3.0.0") :group 'magit-diff :safe (lambda (val) (memq val '(t both all))) - :type '(choice (const :tag "in added lines" t) - (const :tag "in added and removed lines" both) - (const :tag "in added, removed and context lines" all))) + :type '(choice (const :tag "In added lines" t) + (const :tag "In added and removed lines" both) + (const :tag "In added, removed and context lines" all))) (defcustom magit-diff-highlight-trailing t "Whether to highlight whitespace at the end of a line in diffs. @@ -412,8 +412,8 @@ subject to option `magit-revision-insert-related-refs'." (defcustom magit-revision-insert-related-refs t "Whether to show related branches in revision buffers. -nil Don't show any related branches. -t Show related local branches. +`nil' Don't show any related branches. +`t' Show related local branches. `all' Show related local and remote branches. `mixed' Show all containing branches and local merged branches. @@ -421,10 +421,10 @@ See user option `magit-revision-insert-related-refs-display-alist' to hide specific sets of related branches." :package-version '(magit . "2.1.0") :group 'magit-revision - :type '(choice (const :tag "don't" nil) - (const :tag "local only" t) - (const :tag "all related" all) - (const :tag "all containing, local merged" mixed))) + :type '(choice (const :tag "Do not" nil) + (const :tag "Local only" t) + (const :tag "All related" all) + (const :tag "All containing, local merged" mixed))) (defcustom magit-revision-insert-related-refs-display-alist nil "How `magit-insert-revision-headers' displays related branch types. @@ -433,11 +433,11 @@ This is an alist, with recognised keys being the symbols `parents', `merged', `contained', `follows', and `precedes'; and the supported values for each key being: -nil Hide these related branches. -t Show these related branches. +`nil' Hide these related branches. +`t' Show these related branches. -Keys which are not present in the alist have an implicit value t -\(so the default alist value of nil means all related branch types +Keys which are not present in the alist have an implicit value `t' +\(so the default alist value of `nil' means all related branch types will be shown.) The types to be shown are additionally subject to user option @@ -465,7 +465,7 @@ performance and reliability: long and which contain at least one number as well as at least one letter. -If nil, then no hashes are turned into sections, but you can +If `nil', then no hashes are turned into sections, but you can still visit the commit at point using \"RET\"." :package-version '(magit . "2.12.0") :group 'magit-revision @@ -478,9 +478,9 @@ still visit the commit at point using \"RET\"." (defcustom magit-revision-show-gravatars nil "Whether to show gravatar images in revision buffers. -If nil, then don't insert any gravatar images. If t, then insert -both images. If `author' or `committer', then insert only the -respective image. +If `nil', then don't insert any gravatar images. If `t', then +insert both images. If `author' or `committer', then insert +only the respective image. If you have customized the option `magit-revision-header-format' and want to insert the images then you might also have to specify @@ -489,7 +489,7 @@ two regular expressions. The car specifies where to insert the author's image. The top half of the image is inserted right after the matched text, the bottom half on the next line in the same column. The cdr specifies where to insert the committer's -image, accordingly. Either the car or the cdr may be nil." +image, accordingly. Either the car or the cdr may be `nil'." :package-version '(magit . "2.3.0") :group 'magit-revision :type '(choice diff --git a/lisp/magit/magit-ediff.el b/lisp/magit/magit-ediff.el index 650268d8..8c8d026c 100644 --- a/lisp/magit/magit-ediff.el +++ b/lisp/magit/magit-ediff.el @@ -181,8 +181,8 @@ is put in FILE." (setq get (nreverse get)) (setq make (nreverse make)) (setq kill (nreverse kill)) - (let ((mconf (cl-gensym "conf")) - (mfile (cl-gensym "file"))) + (let ((mconf (gensym "conf")) + (mfile (gensym "file"))) `(magit-with-toplevel (let ((,mconf (current-window-configuration)) (,mfile ,file) diff --git a/lisp/magit/magit-git.el b/lisp/magit/magit-git.el index 76b976dc..334d2550 100644 --- a/lisp/magit/magit-git.el +++ b/lisp/magit/magit-git.el @@ -252,8 +252,8 @@ See info node `(magit)Debugging Tools' for more information." (defmacro magit--with-refresh-cache (key &rest body) (declare (indent 1) (debug (form body))) - (let ((k (cl-gensym)) - (hit (cl-gensym))) + (let ((k (gensym)) + (hit (gensym))) `(if magit--refresh-cache (let ((,k ,key)) (if-let ((,hit (assoc ,k (cdr magit--refresh-cache)))) @@ -299,7 +299,7 @@ propagated by `with-temp-buffer', so we explicitly ensure that happens, so that processes will be invoked consistently. BODY is as for that macro." (declare (indent 0) (debug (body))) - (let ((p (cl-gensym))) + (let ((p (gensym))) `(let ((,p process-environment)) (with-temp-buffer (setq-local process-environment ,p) @@ -2402,7 +2402,7 @@ and this option only controls what face is used.") (defmacro magit-with-temp-index (tree arg &rest body) (declare (indent 2) (debug (form form body))) - (let ((file (cl-gensym "file"))) + (let ((file (gensym "file"))) `(let ((magit--refresh-cache nil) (,file (magit-convert-filename-for-git (make-temp-name diff --git a/lisp/magit/magit-log.el b/lisp/magit/magit-log.el index 9a2e46a6..8ad1b56b 100644 --- a/lisp/magit/magit-log.el +++ b/lisp/magit/magit-log.el @@ -262,10 +262,10 @@ The message can be shown in the `echo-area' or the `header-line', or in be nil, in which case no usage information is shown." :package-version '(magit . "2.1.0") :group 'magit-log - :type '(choice (const :tag "in echo-area" echo-area) - (const :tag "in header-line" header-line) - (const :tag "in both places" both) - (const :tag "nowhere"))) + :type '(choice (const :tag "In echo-area" echo-area) + (const :tag "In header-line" header-line) + (const :tag "In both places" both) + (const :tag "Nowhere"))) (defcustom magit-log-select-margin (list (nth 0 magit-log-margin) diff --git a/lisp/magit/magit-mode.el b/lisp/magit/magit-mode.el index 567e2d3a..5303ad6f 100644 --- a/lisp/magit/magit-mode.el +++ b/lisp/magit/magit-mode.el @@ -234,10 +234,10 @@ and Buffer Variables'." :group 'magit-diff :group 'magit-log :type '(choice - (const :tag "always use args from buffer" always) - (const :tag "use args from buffer if displayed in frame" selected) - (const :tag "use args from buffer if it is current" current) - (const :tag "never use args from buffer" never))) + (const :tag "Always use args from buffer" always) + (const :tag "Use args from buffer if displayed in frame" selected) + (const :tag "Use args from buffer if it is current" current) + (const :tag "Never use args from buffer" never))) (defcustom magit-direct-use-buffer-arguments 'selected "Whether certain commands reuse arguments active in relevant buffer. @@ -267,10 +267,10 @@ and Buffer Variables'." :group 'magit-diff :group 'magit-log :type '(choice - (const :tag "always use args from buffer" always) - (const :tag "use args from buffer if displayed in frame" selected) - (const :tag "use args from buffer if it is current" current) - (const :tag "never use args from buffer" never))) + (const :tag "Always use args from buffer" always) + (const :tag "Use args from buffer if displayed in frame" selected) + (const :tag "Use args from buffer if it is current" current) + (const :tag "Never use args from buffer" never))) (defcustom magit-region-highlight-hook '(magit-diff-update-hunk-region) ; from magit-diff.el @@ -1142,12 +1142,13 @@ Run hooks `magit-pre-refresh-hook' and `magit-post-refresh-hook'." (defvar magit-after-save-refresh-buffers nil) (defun magit-after-save-refresh-buffers () - (dolist (buffer magit-after-save-refresh-buffers) - (when (buffer-live-p buffer) - (with-current-buffer buffer - (magit-refresh-buffer)))) - (setq magit-after-save-refresh-buffers nil) - (remove-hook 'post-command-hook #'magit-after-save-refresh-buffers)) + (unless magit-inhibit-refresh + (dolist (buffer magit-after-save-refresh-buffers) + (when (buffer-live-p buffer) + (with-current-buffer buffer + (magit-refresh-buffer)))) + (setq magit-after-save-refresh-buffers nil) + (remove-hook 'post-command-hook #'magit-after-save-refresh-buffers))) (defun magit-after-save-refresh-status () "Refresh the status buffer of the current repository. @@ -1426,7 +1427,7 @@ repositories." (defmacro magit--with-repository-local-cache (key &rest body) (declare (indent 1) (debug (form body))) - (let ((k (cl-gensym))) + (let ((k (gensym))) `(let ((,k ,key)) (if-let ((kv (magit-repository-local-exists-p ,k))) (cdr kv) diff --git a/lisp/magit/magit-patch.el b/lisp/magit/magit-patch.el index 4c6bba86..88641d51 100644 --- a/lisp/magit/magit-patch.el +++ b/lisp/magit/magit-patch.el @@ -40,12 +40,12 @@ a constant list of arguments, depending on this option and the prefix argument." :package-version '(magit . "2.12.0") :group 'magit-diff - :type '(choice (const :tag "use buffer arguments" buffer) - (cons :tag "use buffer arguments except" + :type '(choice (const :tag "Use buffer arguments" buffer) + (cons :tag "Use buffer arguments except" (const :format "" exclude) (repeat :format "%v%i\n" (string :tag "Argument"))) - (repeat :tag "use constant arguments" + (repeat :tag "Use constant arguments" (string :tag "Argument")))) ;;; Commands diff --git a/lisp/magit/magit-pkg.el b/lisp/magit/magit-pkg.el index dd257d34..8d1bb9fd 100644 --- a/lisp/magit/magit-pkg.el +++ b/lisp/magit/magit-pkg.el @@ -1,12 +1,12 @@ -(define-package "magit" "20250221.105" "A Git porcelain inside Emacs" +(define-package "magit" "20250305.2342" "A Git porcelain inside Emacs" '((emacs "27.1") (compat "30.0.2.0") - (llama "0.6.0") - (magit-section "4.3.0") + (llama "0.6.1") + (magit-section "4.3.1") (seq "2.24") - (transient "0.8.4") + (transient "0.8.5") (with-editor "3.4.3")) - :commit "9914feb4d5a2feab091076be554d80781594869d" :authors + :commit "225ea6fd009300ba80e55a0162f3e46eb6e4f2d3" :authors '(("Marius Vollmer" . "marius.vollmer@gmail.com") ("Jonas Bernoulli" . "emacs.magit@jonas.bernoulli.dev")) :maintainers diff --git a/lisp/magit/magit-process.el b/lisp/magit/magit-process.el index 201b4b57..bc4c0ce7 100644 --- a/lisp/magit/magit-process.el +++ b/lisp/magit/magit-process.el @@ -49,8 +49,8 @@ If nil, use pipes: this is usually more efficient, and works on Cygwin. If t, use ptys: this enables Magit to prompt for passphrases when needed." :group 'magit-process - :type '(choice (const :tag "pipe" nil) - (const :tag "pty" t))) + :type '(choice (const :tag "Pipe" nil) + (const :tag "Pty" t))) (defcustom magit-need-cygwin-noglob (and (eq system-type 'windows-nt) @@ -257,7 +257,7 @@ process section in the process buffer, and insert the returned string in the heading of its section." :package-version '(magit . "4.0.0") :group 'magit-process - :type '(choice (const :tag "none" nil) string)) + :type '(choice (const :tag "None" nil) string)) (defvar tramp-pipe-stty-settings) (defvar magit-tramp-pipe-stty-settings "" diff --git a/lisp/magit/magit-remote.el b/lisp/magit/magit-remote.el index 2d23d7cc..b5fdbf28 100644 --- a/lisp/magit/magit-remote.el +++ b/lisp/magit/magit-remote.el @@ -40,10 +40,10 @@ the name of the added remote is equal to that string and the variable isn't already set." :package-version '(magit . "2.4.0") :group 'magit-commands - :type '(choice (const :tag "ask if unset" ask-if-unset) - (const :tag "always ask" ask) - (string :tag "set if named") - (const :tag "don't set"))) + :type '(choice (const :tag "Ask if unset" ask-if-unset) + (const :tag "Always ask" ask) + (string :tag "Set if named") + (const :tag "Don't set"))) (defcustom magit-remote-direct-configure t "Whether the command `magit-remote' shows Git variables. diff --git a/lisp/magit/magit-sequence.el b/lisp/magit/magit-sequence.el index b1836779..0fd0142e 100644 --- a/lisp/magit/magit-sequence.el +++ b/lisp/magit/magit-sequence.el @@ -560,8 +560,8 @@ This discards all changes made since the sequence started." ("s" "a subset" magit-rebase-subset)] [("m" "to modify a commit" magit-rebase-edit-commit) ("w" "to reword a commit" magit-rebase-reword-commit) - ("k" "to remove a commit" magit-rebase-remove-commit) - ("f" "to autosquash" magit-rebase-autosquash) + ("k" "to remove a commit" magit-rebase-remove-commit)] + [("f" "to autosquash" magit-rebase-autosquash) (6 "t" "to change dates" magit-reshelve-since)]] ["Actions" :if magit-rebase-in-progress-p diff --git a/lisp/magit/magit-status.el b/lisp/magit/magit-status.el index 494c940b..2b90b21d 100644 --- a/lisp/magit/magit-status.el +++ b/lisp/magit/magit-status.el @@ -109,9 +109,9 @@ See option `magit-section-initial-visibility-alist' for how to control the initial visibility of the jumped to section." :package-version '(magit . "2.90.0") :group 'magit-status - :type '(choice (const :tag "as usual" nil) - (repeat (choice (number :tag "nth top-level section") - (sexp :tag "section identity"))))) + :type '(choice (const :tag "As usual" nil) + (repeat (choice (number :tag "Nth top-level section") + (sexp :tag "Section identity"))))) (defcustom magit-status-goto-file-position nil "Whether to go to position corresponding to file position. @@ -237,10 +237,10 @@ Valid values are: :group 'magit-buffers :group 'magit-commands :type '(choice - (const :tag "always use args from buffer" always) - (const :tag "use args from buffer if displayed in frame" selected) - (const :tag "use args from buffer if it is current" current) - (const :tag "never use args from buffer" never))) + (const :tag "Always use args from buffer" always) + (const :tag "Use args from buffer if displayed in frame" selected) + (const :tag "Use args from buffer if it is current" current) + (const :tag "Never use args from buffer" never))) ;;; Commands diff --git a/lisp/magit/magit-version.el b/lisp/magit/magit-version.el index 27d8a458..e38b7798 100644 --- a/lisp/magit/magit-version.el +++ b/lisp/magit/magit-version.el @@ -1,6 +1,6 @@ ;;; magit-version.el --- the Magit version you are using -(setq magit-version "4.3.0") +(setq magit-version "4.3.1") (provide 'migit-version) diff --git a/lisp/magit/magit-wip.el b/lisp/magit/magit-wip.el index 50cf8167..3a6c32ba 100644 --- a/lisp/magit/magit-wip.el +++ b/lisp/magit/magit-wip.el @@ -40,41 +40,12 @@ :group 'magit-modes :group 'magit-essentials) -(defgroup magit-wip-legacy nil - "It is better to not use these modes individually." - :link '(info-link "(magit)Legacy Wip Modes") - :group 'magit-wip) - (defcustom magit-wip-mode-lighter " Wip" "Lighter for Magit-Wip mode." :package-version '(magit . "2.90.0") :group 'magit-wip :type 'string) -(defcustom magit-wip-after-save-local-mode-lighter "" - "Lighter for Magit-Wip-After-Save-Local mode." - :package-version '(magit . "2.1.0") - :group 'magit-wip-legacy - :type 'string) - -(defcustom magit-wip-after-apply-mode-lighter "" - "Lighter for Magit-Wip-After-Apply mode." - :package-version '(magit . "2.1.0") - :group 'magit-wip-legacy - :type 'string) - -(defcustom magit-wip-before-change-mode-lighter "" - "Lighter for Magit-Wip-Before-Change mode." - :package-version '(magit . "2.1.0") - :group 'magit-wip-legacy - :type 'string) - -(defcustom magit-wip-initial-backup-mode-lighter "" - "Lighter for Magit-Wip-Initial Backup mode." - :package-version '(magit . "2.1.0") - :group 'magit-wip-legacy - :type 'string) - (defcustom magit-wip-merge-branch nil "Whether to merge the current branch into its wip ref. @@ -138,7 +109,6 @@ the current branch. This mode should be enabled globally by turning on the globalized variant `magit-wip-after-save-mode'." :package-version '(magit . "2.1.0") - :lighter magit-wip-after-save-local-mode-lighter (if magit-wip-after-save-local-mode (if (and buffer-file-name (magit-inside-worktree-p t)) (add-hook 'after-save-hook #'magit-wip-commit-buffer-file t t) @@ -205,7 +175,6 @@ in the worktree and the other contains snapshots of the entries in the index." :package-version '(magit . "2.1.0") :group 'magit-wip - :lighter magit-wip-after-apply-mode-lighter :global t) (defun magit-wip-commit-after-apply (&optional files msg) @@ -227,7 +196,6 @@ Only changes to files which could potentially be affected by the command which is about to be called are committed." :package-version '(magit . "2.1.0") :group 'magit-wip - :lighter magit-wip-before-change-mode-lighter :global t) (defun magit-wip-commit-before-change (&optional files msg) @@ -239,7 +207,6 @@ command which is about to be called are committed." "Before saving a buffer for the first time, commit to a wip ref." :package-version '(magit . "2.90.0") :group 'magit-wip - :lighter magit-wip-initial-backup-mode-lighter :global t (if magit-wip-initial-backup-mode (add-hook 'before-save-hook #'magit-wip-commit-initial-backup) diff --git a/lisp/magit/magit.el b/lisp/magit/magit.el index 1b3a3767..504ec9a1 100644 --- a/lisp/magit/magit.el +++ b/lisp/magit/magit.el @@ -17,14 +17,14 @@ ;; Homepage: https://github.com/magit/magit ;; Keywords: git tools vc -;; Package-Version: 4.3.0 +;; Package-Version: 4.3.1 ;; Package-Requires: ( ;; (emacs "27.1") ;; (compat "30.0.2.0") -;; (llama "0.6.0") -;; (magit-section "4.3.0") +;; (llama "0.6.1") +;; (magit-section "4.3.1") ;; (seq "2.24") -;; (transient "0.8.4") +;; (transient "0.8.5") ;; (with-editor "3.4.3")) ;; SPDX-License-Identifier: GPL-3.0-or-later diff --git a/lisp/magit/magit.info b/lisp/magit/magit.info index 45acad5b..0ac3bc0f 100644 --- a/lisp/magit/magit.info +++ b/lisp/magit/magit.info @@ -1,4 +1,4 @@ -This is magit.info, produced by makeinfo version 6.8 from magit.texi. +This is magit.info, produced by makeinfo version 7.1.1 from magit.texi. Copyright (C) 2015-2025 Jonas Bernoulli @@ -32,7 +32,7 @@ to perform almost all of their daily version control tasks directly from within Emacs. While many fine Git clients exist, only Magit and Git itself deserve to be called porcelains. -This manual is for Magit version 4.3.0. +This manual is for Magit version 4.3.1. Copyright (C) 2015-2025 Jonas Bernoulli @@ -65,7 +65,7 @@ This manual is for Magit version 4.3.0. * Function and Command Index:: * Variable Index:: -— The Detailed Node Listing — +-- The Detailed Node Listing -- Installation @@ -167,18 +167,18 @@ itself deserve to be called porcelains. Staging and otherwise applying changes is one of the most important features in a Git porcelain and here Magit outshines anything else, -including Git itself. Git’s own staging interface (‘git add --patch’) +including Git itself. Git's own staging interface (‘git add --patch’) is so cumbersome that many users only use it in exceptional cases. In Magit staging a hunk or even just part of a hunk is as trivial as staging all changes made to a file. - The most visible part of Magit’s interface is the status buffer, + The most visible part of Magit's interface is the status buffer, which displays information about the current repository. Its content is created by running several Git commands and making their output actionable. Among other things, it displays information about the current branch, lists unpulled and unpushed changes and contains sections displaying the staged and unstaged changes. That might sound -noisy, but, since sections are collapsible, it’s not. +noisy, but, since sections are collapsible, it's not. To stage or unstage a change one places the cursor on the change and then types ‘s’ or ‘u’. The change can be a file or a hunk, or when the @@ -188,13 +188,13 @@ commands - and many others - would act on are highlighted. Magit also implements several other "apply variants" in addition to staging and unstaging. One can discard or reverse a change, or apply it -to the working tree. Git’s own porcelain only supports this for staging +to the working tree. Git's own porcelain only supports this for staging and unstaging and you would have to do something like ‘git diff ... | ??? | git apply ...’ to discard, revert, or apply a single hunk on the -command line. In fact that’s exactly what Magit does internally (which +command line. In fact that's exactly what Magit does internally (which is what lead to the term "apply variants"). - Magit isn’t just for Git experts, but it does assume some prior + Magit isn't just for Git experts, but it does assume some prior experience with Git as well as Emacs. That being said, many users have reported that using Magit was what finally taught them what Git is capable of and how to use it to its fullest. Other users wished they @@ -202,7 +202,7 @@ had switched to Emacs sooner so that they would have gotten their hands on Magit earlier. While one has to know the basic features of Emacs to be able to make -full use of Magit, acquiring just enough Emacs skills doesn’t take long +full use of Magit, acquiring just enough Emacs skills doesn't take long and is worth it, even for users who prefer other editors. Vim users are advised to give Evil (https://github.com/emacs-evil/evil), the "Extensible VI Layer for Emacs", and Spacemacs @@ -218,7 +218,7 @@ past. Magit fully embraces Git. It exposes many advanced features using a simple but flexible interface instead of only wrapping the trivial ones like many GUI clients do. Of course Magit supports logging, cloning, -pushing, and other commands that usually don’t fail in spectacular ways; +pushing, and other commands that usually don't fail in spectacular ways; but it also supports tasks that often cannot be completed in a single step. Magit fully supports tasks such as merging, rebasing, cherry-picking, reverting, and blaming by not only providing a command @@ -241,7 +241,7 @@ File: magit.info, Node: Installation, Next: Getting Started, Prev: Introducti 2 Installation ************** -Magit can be installed using Emacs’ package manager or manually from its +Magit can be installed using Emacs' package manager or manually from its development repository. * Menu: @@ -256,8 +256,8 @@ File: magit.info, Node: Installing from Melpa, Next: Installing from the Git R 2.1 Installing from Melpa ========================= -Magit is available from Melpa and Melpa-Stable. If you haven’t used -Emacs’ package manager before, then it is high time you familiarize +Magit is available from Melpa and Melpa-Stable. If you haven't used +Emacs' package manager before, then it is high time you familiarize yourself with it by reading the documentation in the Emacs manual, see *note (emacs)Packages::. Then add one of the archives to ‘package-archives’: @@ -307,7 +307,7 @@ install them manually from their repository. $ make - If you haven’t installed ‘compat’, ‘llama’, ‘seq’ (for Emacs < 29.1), + If you haven't installed ‘compat’, ‘llama’, ‘seq’ (for Emacs < 29.1), ‘transient’ and ‘with-editor’ from Melpa, or at ‘/path/to/magit/../’, then you have to tell ‘make’ where to find them. To do so create the file ‘/path/to/magit/config.mk’ with the @@ -370,7 +370,7 @@ File: magit.info, Node: Post-Installation Tasks, Prev: Installing from the Git =========================== After installing Magit you should verify that you are indeed using the -Magit, Git, and Emacs releases you think you are using. It’s best to +Magit, Git, and Emacs releases you think you are using. It's best to restart Emacs before doing so, to make sure you are not using an outdated value for ‘load-path’. @@ -454,7 +454,7 @@ but not all of them. Again type ‘s’ to stage. file section, type ‘C-SPC’, move to the next file using ‘n’, and then ‘s’ to stage both files. Note that both the mark and point have to be on the headings of sibling sections for this to work. If the region -looks like it does in other buffers, then it doesn’t select Magit +looks like it does in other buffers, then it doesn't select Magit sections that can be acted on as a unit. And then of course you want to commit your changes. Type ‘c’. This @@ -467,7 +467,7 @@ create a "normal" commit, which is done by typing ‘c’ again. the other shows a diff with the changes that you are about to commit. Write a message and then type ‘C-c C-c’ to actually create the commit. - You probably don’t want to push the commit you just created because + You probably don't want to push the commit you just created because you just committed some random changes, but if that is not the case you could push it by typing ‘P’ to show all the available push commands and arguments and then ‘p’ to push to a branch with the same name as the @@ -535,7 +535,7 @@ usually exists only one buffer per repository. Separate modes and thus buffers exist for commits, diffs, logs, and some other things. Besides these special purpose buffers, there also exists an overview -buffer, called the *status buffer*. It’s usually from this buffer that +buffer, called the *status buffer*. It's usually from this buffer that the user invokes Git commands, or creates or visits other buffers. In this manual we often speak about "Magit buffers". By that we mean @@ -551,7 +551,7 @@ buffers whose major-modes derive from ‘magit-mode’. the unlocked buffer. Not all Magit buffers can be locked to their values; for example, - it wouldn’t make sense to lock a status buffer. + it wouldn't make sense to lock a status buffer. There can only be a single unlocked buffer using a certain major-mode per repository. So when a buffer is being unlocked and @@ -607,7 +607,7 @@ buffers whose major-modes derive from ‘magit-mode’. -- Function: magit-display-buffer-same-window-except-diff-v1 This function displays most buffers in the currently selected - window. If a buffer’s mode derives from ‘magit-diff-mode’ or + window. If a buffer's mode derives from ‘magit-diff-mode’ or ‘magit-process-mode’, it is displayed in another window. -- Function: magit-display-buffer-fullframe-status-v1 @@ -627,8 +627,8 @@ buffers whose major-modes derive from ‘magit-mode’. -- Function: magit-display-buffer-fullcolumn-most-v1 This function displays most buffers so that they fill the entire height of the frame. However, the buffer is displayed in another - window if (1) the buffer’s mode derives from ‘magit-process-mode’, - or (2) the buffer’s mode derives from ‘magit-diff-mode’, provided + window if (1) the buffer's mode derives from ‘magit-process-mode’, + or (2) the buffer's mode derives from ‘magit-diff-mode’, provided that the mode of the current buffer derives from ‘magit-log-mode’ or ‘magit-cherry-mode’. @@ -660,7 +660,7 @@ buffers whose major-modes derive from ‘magit-mode’. Such a function should take the options ‘magit-uniquify-buffer-names’ as well as ‘magit-buffer-name-format’ - into account. If it doesn’t, then should be clearly stated in the + into account. If it doesn't, then should be clearly stated in the doc-string. And if it supports %-sequences beyond those mentioned in the doc-string of the option ‘magit-buffer-name-format’, then its own doc-string should describe the additions. @@ -785,7 +785,7 @@ keep the delay to a minimum and also because doing so can sometimes be undesirable. Buffers can also be refreshed explicitly, which is useful in buffers -that weren’t current during the last refresh and after changes were made +that weren't current during the last refresh and after changes were made to the repository outside of Magit. ‘g’ (‘magit-refresh’) @@ -825,14 +825,14 @@ to the repository outside of Magit. Note that refreshing a Magit buffer is done by re-creating its contents from scratch, which can be slow in large repositories. If - you are not satisfied with Magit’s performance, then you should + you are not satisfied with Magit's performance, then you should obviously not add this function to that hook. 4.1.5 Automatic Saving of File-Visiting Buffers ----------------------------------------------- File-visiting buffers are by default saved at certain points in time. -This doesn’t guarantee that Magit buffers are always up-to-date, but, +This doesn't guarantee that Magit buffers are always up-to-date, but, provided one only edits files by editing them in Emacs and uses only Magit to interact with Git, one can be fairly confident. When in doubt or after outside changes, type ‘g’ (‘magit-refresh’) to save and refresh @@ -901,7 +901,7 @@ the visiting buffer before you could continue making changes. This option controls whether ‘magit-auto-revert-mode’ only reverts tracked files or all files that are located inside Git repositories, including untracked files and files located inside - Git’s control directory. + Git's control directory. -- User Option: auto-revert-mode The global mode ‘magit-auto-revert-mode’ works by turning on this @@ -935,7 +935,7 @@ the visiting buffer before you could continue making changes. predicates provided by Magit - especially if you also use Tramp. Users who do turn on ‘auto-revert-mode’ in buffers in which Magit - doesn’t do that for them, should likely not use any filter. Users + doesn't do that for them, should likely not use any filter. Users who turn on ‘global-auto-revert-mode’, do not have to worry about this option, because it is disregarded if the global mode is enabled. @@ -954,7 +954,7 @@ Risk of Reverting Automatically For the vast majority of users, automatically reverting file-visiting buffers after they have changed on disk is harmless. - If a buffer is modified (i.e., it contains changes that haven’t been + If a buffer is modified (i.e., it contains changes that haven't been saved yet), then Emacs will refuse to automatically revert it. If you save a previously modified buffer, then that results in what is seen by Git as an uncommitted change. Git will then refuse to carry out any @@ -987,7 +987,7 @@ crashes or if you quit Emacs by mistake, then you would also lose the buffer content. There would be no autosave file still containing the intermediate version (because that was deleted when you saved the buffer) and you would not be asked whether you want to save the buffer -(because it isn’t modified). +(because it isn't modified).  File: magit.info, Node: Sections, Next: Transient Commands, Prev: Modes and Buffers, Up: Interface Concepts @@ -1040,7 +1040,7 @@ Any of the functions listed below can be used as members of this hook. You might want to remove some of the functions that Magit adds using ‘add-hook’. In doing so you have to make sure you do not attempt to -remove function that haven’t even been added yet, for example: +remove function that haven't even been added yet, for example: (with-eval-after-load 'magit-diff (remove-hook 'magit-section-movement-hook @@ -1059,7 +1059,7 @@ remove function that haven’t even been added yet, for example: -- Function: magit-section-set-window-start This hook function ensures that the beginning of the current - section is visible, regardless of the section’s type. If you add + section is visible, regardless of the section's type. If you add this to ‘magit-section-movement-hook’, then you must remove the hunk-only variant in turn. @@ -1195,7 +1195,7 @@ certain sections can also be overwritten using the hook -- User Option: magit-section-initial-visibility-alist This options can be used to override the initial visibility of sections. In the future it will also be used to define the - defaults, but currently a section’s default is still hardcoded. + defaults, but currently a section's default is still hardcoded. The value is an alist. Each element maps a section type or lineage to the initial visibility state for such sections. The state has @@ -1204,7 +1204,7 @@ certain sections can also be overwritten using the hook argument. Use the command ‘magit-describe-section-briefly’ to determine a - section’s lineage or type. The vector in the output is the section + section's lineage or type. The vector in the output is the section lineage and the type is the first element of that vector. Wildcards can be used, see ‘magit-section-match’. @@ -1296,12 +1296,12 @@ this manual along with the appropriate "section inserter functions". right before AT. If FUNCTION already is a member of the list but AT is not, then leave FUNCTION where ever it already is. - If optional LOCAL is non-nil, then modify the hook’s buffer-local + If optional LOCAL is non-nil, then modify the hook's buffer-local value rather than its global value. This makes the hook local by copying the default value. That copy is then modified. HOOK should be a symbol. If HOOK is void, it is first set to nil. - HOOK’s value must not be a single hook function. FUNCTION should + HOOK's value must not be a single hook function. FUNCTION should be a function that takes no arguments and inserts one or multiple sections at point, moving point forward. FUNCTION may choose not to insert its section(s), when doing so would not make sense. It @@ -1316,7 +1316,7 @@ Each section has a type, for example ‘hunk’, ‘file’, and ‘commit’. Instances of certain section types also have a value. The value of a section of type ‘file’, for example, is a file name. - Users usually do not have to worry about a section’s type and value, + Users usually do not have to worry about a section's type and value, but knowing them can be handy at times. ‘H’ (‘magit-describe-section’) @@ -1369,7 +1369,7 @@ library ‘magit-key-mode’. ‘C-x M-g’ (‘magit-dispatch’) ‘C-c g’ (‘magit-dispatch’) - This transient prefix command binds most of Magit’s other prefix + This transient prefix command binds most of Magit's other prefix commands as suffix commands and displays them in a temporary buffer until one of them is invoked. Invoking such a sub-prefix causes the suffixes of that command to be bound and displayed instead of @@ -1388,7 +1388,7 @@ File: magit.info, Node: Transient Arguments and Buffer Variables, Next: Comple 4.4 Transient Arguments and Buffer Variables ============================================ -The infix arguments of many of Magit’s transient prefix commands cease +The infix arguments of many of Magit's transient prefix commands cease to have an effect once the ‘git’ command that is called with those arguments has returned. Commands that create a commit are a good example for this. If the user changes the arguments, then that only @@ -1408,7 +1408,7 @@ obviously continue to have an effect for as long as the respective diff or log is being displayed. Furthermore the used arguments are stored in buffer-local variables for future reference. - For commands in the second group it isn’t always desirable to reset + For commands in the second group it isn't always desirable to reset their arguments to the global value when the transient prefix command is invoked again. @@ -1485,7 +1485,7 @@ I am afraid it gets more complicated still: • When ‘magit-show-commit’ is invoked directly from a log buffer, then the file filter is picked up from that buffer, not from the - revision buffer or the mode’s global diff arguments. + revision buffer or the mode's global diff arguments. • Even though they are suffixes of the diff prefix ‘magit-show-commit’ and ‘magit-stash-show’ do not use the diff @@ -1505,7 +1505,7 @@ I am afraid it gets more complicated still: • If ‘magit-show-refs’ is invoked from a ‘magit-refs-mode’ buffer, then it acts as a refresh prefix and therefore unconditionally uses - the buffer’s arguments as initial arguments. If it is invoked + the buffer's arguments as initial arguments. If it is invoked elsewhere with a prefix argument, then it acts as regular prefix and therefore respects ‘magit-prefix-use-buffer-arguments’. If it is invoked elsewhere without a prefix argument, then it acts as a @@ -1543,7 +1543,7 @@ telling Magit to ask fewer questions. which, when invoked unintentionally or without being fully aware of the consequences, could lead to tears. In many cases there are several commands that perform variations of a certain action, so we - don’t use the command names but more generic symbols. + don't use the command names but more generic symbols. • Applying changes: @@ -1563,7 +1563,7 @@ telling Magit to ask fewer questions. • Files: - • ‘delete’ When a file that isn’t yet tracked by Git is + • ‘delete’ When a file that isn't yet tracked by Git is deleted, then it is completely lost, not just the last changes. Very dangerous. @@ -1597,7 +1597,7 @@ telling Magit to ask fewer questions. user. • ‘abort-rebase’ Aborting a rebase throws away all already - modified commits, but it’s possible to restore those from + modified commits, but it's possible to restore those from the reflog. • ‘abort-merge’ Aborting a merge throws away all conflict @@ -1637,7 +1637,7 @@ telling Magit to ask fewer questions. • Publishing: • ‘set-and-push’ When pushing to the upstream or the - push-remote and that isn’t actually configured yet, then + push-remote and that isn't actually configured yet, then the user can first set the target. If s/he confirms the default too quickly, then s/he might end up pushing to the wrong branch and if the remote repository is @@ -1672,7 +1672,7 @@ telling Magit to ask fewer questions. • ‘stash-apply-3way’ When a stash cannot be applied using ‘git stash apply’, then Magit uses ‘git apply’ instead, - possibly using the ‘--3way’ argument, which isn’t always + possibly using the ‘--3way’ argument, which isn't always perfectly safe. See also ‘magit-stash-apply’. • ‘kill-process’ There seldom is a reason to kill a @@ -1681,10 +1681,10 @@ telling Magit to ask fewer questions. • Global settings: Instead of adding all of the above symbols to the value of - this option, you can also set it to the atom ‘t’, which has + this option, you can also set it to the atom 't', which has the same effect as adding all of the above symbols. Doing that most certainly is a bad idea, especially because other - symbols might be added in the future. So even if you don’t + symbols might be added in the future. So even if you don't want to be asked for confirmation for any of these actions, you are still better of adding all of the respective symbols individually. @@ -1768,7 +1768,7 @@ the previous section — this section only covers how multiple things are selected, how that is visualized, and how certain commands behave when that is the case. - Magit’s mechanism for selecting multiple things, or rather sections + Magit's mechanism for selecting multiple things, or rather sections that represent these things, is based on the Emacs region, but the area that Magit considers to be selected is typically larger than the region and additional restrictions apply. @@ -1847,12 +1847,12 @@ function used by ‘magit-completing-read’. This option also makes it possible to use a different completing mechanism for Magit than for the rest of Emacs, but doing that is not recommend. - You most likely don’t have to customize the magit-specific option to + You most likely don't have to customize the magit-specific option to use an alternative completion framework. For example, if you enable ‘ivy-mode’, then Magit will respect that, and if you enable ‘helm-mode’, then you are done too. - However if you want to use Ido, then ‘ido-mode’ won’t do the trick. + However if you want to use Ido, then ‘ido-mode’ won't do the trick. You will also have to install the ‘ido-completing-read+’ package and use ‘magit-ido-completing-read’ as ‘magit-completing-read-function’. @@ -1963,9 +1963,9 @@ some value (e.g., the name of the current branch). When Git is run for side-effects, the process output is logged in a per-repository log buffer, which can be consulted using the -‘magit-process’ command when things don’t go as expected. +‘magit-process’ command when things don't go as expected. - The output/errors for up to ‘magit-process-log-max’ Git commands are + The output/errors for up to 'magit-process-log-max' Git commands are retained. ‘$’ (‘magit-process’) @@ -1987,14 +1987,14 @@ sections are available. There is one additional command. When git is run for side-effects then its output, including error messages, go into the process buffer which is shown when using ‘$’. - When git’s output is consumed in some way, then it would be too + When git's output is consumed in some way, then it would be too expensive to also insert it into this buffer, but with this command that can be enabled temporarily. In that case, if git returns with a non-zero exit status, then at least its standard error is inserted into this buffer. Also note that just because git exits with a non-zero status and - prints an error message, that usually doesn’t mean that it is an + prints an error message, that usually doesn't mean that it is an error as far as Magit is concerned, which is another reason we usually hide these error messages. Whether some error message is relevant in the context of some unexpected behavior has to be @@ -2126,7 +2126,7 @@ the order in ‘exec-path’ or ‘tramp-remote-path’ is correct. Note that ‘exec-path’ is set based on the value of the ‘PATH’ environment variable that is in effect when Emacs is started. If you -set ‘PATH’ in your shell’s init files, then that only has an effect on +set ‘PATH’ in your shell's init files, then that only has an effect on Emacs if you start it from that shell (because the environment of a process is only passed to its child processes, not to arbitrary other processes). If that is not how you start Emacs, then the @@ -2169,17 +2169,17 @@ File: magit.info, Node: Inspecting, Next: Manipulating, Prev: Interface Conce The functionality provided by Magit can be roughly divided into three groups: inspecting existing data, manipulating existing data or adding new data, and transferring data. Of course that is a rather crude -distinction that often falls short, but it’s more useful than no +distinction that often falls short, but it's more useful than no distinction at all. This section is concerned with inspecting data, the next two with manipulating and transferring it. Then follows a section about miscellaneous functionality, which cannot easily be fit into this distinction. - Of course other distinctions make sense too, e.g., Git’s distinction + Of course other distinctions make sense too, e.g., Git's distinction between porcelain and plumbing commands, which for the most part is -equivalent to Emacs’ distinction between interactive commands and +equivalent to Emacs' distinction between interactive commands and non-interactive functions. All of the sections mentioned before are -mainly concerned with the porcelain – Magit’s plumbing layer is +mainly concerned with the porcelain - Magit's plumbing layer is described later. * Menu: @@ -2206,8 +2206,8 @@ unstaged changes, logs for unpushed and unpulled commits, lists of stashes and untracked files, and information related to the current branch. - During certain incomplete operations – for example when a merge -resulted in a conflict – additional information is displayed that helps + During certain incomplete operations - for example when a merge +resulted in a conflict - additional information is displayed that helps proceeding with or aborting the operation. The command ‘magit-status’ displays the status buffer belonging to @@ -2220,7 +2220,7 @@ that it should be bound globally. We recommend using ‘C-x g’: When invoked from within an existing Git repository, then this command shows the status of that repository in a buffer. - If the current directory isn’t located within a Git repository, + If the current directory isn't located within a Git repository, then this command prompts for an existing repository or an arbitrary directory, depending on the option ‘magit-repository-directories’, and the status for the selected @@ -2268,7 +2268,7 @@ that it should be bound globally. We recommend using ‘C-x g’: This command is an alternative to ‘magit-status’ that usually avoids refreshing the status buffer. - If the status buffer of the current Git repository exists but isn’t + If the status buffer of the current Git repository exists but isn't being displayed in the selected frame, then it is displayed without being refreshed. @@ -2366,25 +2366,25 @@ such hooks and how to customize them. "Stashes:". -- Function: magit-insert-unpulled-from-upstream - Insert section showing commits that haven’t been pulled from the + Insert section showing commits that haven't been pulled from the upstream branch yet. -- Function: magit-insert-unpulled-from-pushremote - Insert section showing commits that haven’t been pulled from the + Insert section showing commits that haven't been pulled from the push-remote branch yet. -- Function: magit-insert-unpushed-to-upstream - Insert section showing commits that haven’t been pushed to the + Insert section showing commits that haven't been pushed to the upstream yet. -- Function: magit-insert-unpushed-to-pushremote - Insert section showing commits that haven’t been pushed to the + Insert section showing commits that haven't been pushed to the push-remote yet. 5.1.2 Status File List Sections ------------------------------- -These functions honor the buffer’s file filter, which can be set using +These functions honor the buffer's file filter, which can be set using ‘D - -’. -- Function: magit-insert-untracked-files @@ -2432,7 +2432,7 @@ These functions honor the buffer’s file filter, which can be set using While the above function is a member of ‘magit-status-section-hook’ by default, the following functions have to be explicitly added by the user. Because that negatively affects performance, it is recommended -that you don’t do that. +that you don't do that. -- Function: magit-insert-tracked-files Insert a list of tracked files. @@ -2506,7 +2506,7 @@ hook variable. This function is only aware of the last error that occur when Git was run for side-effects. If, for example, an error occurs while - generating a diff, then that error won’t be inserted. Refreshing + generating a diff, then that error won't be inserted. Refreshing the status buffer causes this section to disappear again. -- Function: magit-insert-diff-filter-header @@ -2577,25 +2577,25 @@ variable. Press ‘RET’ on such a submodule section to show its own status buffer. Press ‘RET’ on the "Modules" section to display a list of submodules in a separate buffer. This shows additional information - not displayed in the super-repository’s status buffer. + not displayed in the super-repository's status buffer. -- Function: magit-insert-modules-unpulled-from-upstream - Insert sections for modules that haven’t been pulled from the + Insert sections for modules that haven't been pulled from the upstream yet. These sections can be expanded to show the respective commits. -- Function: magit-insert-modules-unpulled-from-pushremote - Insert sections for modules that haven’t been pulled from the + Insert sections for modules that haven't been pulled from the push-remote yet. These sections can be expanded to show the respective commits. -- Function: magit-insert-modules-unpushed-to-upstream - Insert sections for modules that haven’t been pushed to the + Insert sections for modules that haven't been pushed to the upstream yet. These sections can be expanded to show the respective commits. -- Function: magit-insert-modules-unpushed-to-pushremote - Insert sections for modules that haven’t been pushed to the + Insert sections for modules that haven't been pushed to the push-remote yet. These sections can be expanded to show the respective commits. @@ -2676,7 +2676,7 @@ The following functions can be added to the above option: This function inserts the absolute path of the repository. -- Function: magit-repolist-column-version - This function inserts a description of the repository’s ‘HEAD’ + This function inserts a description of the repository's ‘HEAD’ revision. -- Function: magit-repolist-column-branch @@ -2755,7 +2755,7 @@ File: magit.info, Node: Logging, Next: Diffing, Prev: Repository List, Up: I =========== The status buffer contains logs for the unpushed and unpulled commits, -but that obviously isn’t enough. The transient prefix command +but that obviously isn't enough. The transient prefix command ‘magit-log’, on ‘l’, features several suffix commands, which show a specific log in a separate log buffer. @@ -2763,7 +2763,7 @@ specific log in a separate log buffer. several infix arguments that can be changed before invoking one of the suffix commands. However, in the case of the log transient, these arguments may be taken from those currently in use in the current -repository’s log buffer, depending on the value of +repository's log buffer, depending on the value of ‘magit-prefix-use-buffer-arguments’ (see *note Transient Arguments and Buffer Variables::). @@ -2864,10 +2864,10 @@ the status buffer. displayed in the current frame. ‘C-c C-b’ (‘magit-go-backward’) - Move backward in current buffer’s history. + Move backward in current buffer's history. ‘C-c C-f’ (‘magit-go-forward’) - Move forward in current buffer’s history. + Move forward in current buffer's history. ‘C-c C-n’ (‘magit-log-move-to-parent’) Move to a parent of the current commit. By default, this is the @@ -2877,7 +2877,7 @@ the status buffer. ‘j’ (‘magit-log-move-to-revision’) Read a revision and move to it in current log buffer. - If the chosen reference or revision isn’t being displayed in the + If the chosen reference or revision isn't being displayed in the current log buffer, then inform the user about that and do nothing else. @@ -2940,7 +2940,7 @@ it. Local branches are blue and remote branches are green. Of course that depends on the used theme, as do the colors used for other types of references. The current branch has a box around it, as do remote -branches that are their respective remote’s ‘HEAD’ branch. +branches that are their respective remote's ‘HEAD’ branch. If a local branch and its push-target point at the same commit, then their names are combined to preserve space and to make that relationship @@ -2955,7 +2955,7 @@ visible. For example: [blue-] [green-------] Also note that while the transient features the ‘--show-signature’ -argument, that won’t actually be used when enabled, because Magit +argument, that won't actually be used when enabled, because Magit defaults to use just one line per commit. Instead the commit colorized to indicate the validity of the signed commit object, using the faces named ‘magit-signature-*’ (which see). @@ -3050,7 +3050,7 @@ buffers: argument. ‘C-c C-k’ (‘magit-log-select-quit’) - Abort selecting a commit, don’t act on any commit. + Abort selecting a commit, don't act on any commit. -- User Option: magit-log-select-margin This option specifies whether the margin is initially shown in @@ -3118,7 +3118,7 @@ Also see *note (gitman)git-reflog::. 5.3.6 Cherries -------------- -Cherries are commits that haven’t been applied upstream (yet), and are +Cherries are commits that haven't been applied upstream (yet), and are usually visualized using a log. Each commit is prefixed with ‘-’ if it has an equivalent in the upstream and ‘+’ if it does not, i.e., if it is a cherry. @@ -3163,7 +3163,7 @@ File: magit.info, Node: Diffing, Next: Ediffing, Prev: Logging, Up: Inspecti =========== The status buffer contains diffs for the staged and unstaged commits, -but that obviously isn’t enough. The transient prefix command +but that obviously isn't enough. The transient prefix command ‘magit-diff’, on ‘d’, features several suffix commands, which show a specific diff in a separate diff buffer. @@ -3171,7 +3171,7 @@ specific diff in a separate diff buffer. several infix arguments that can be changed before invoking one of the suffix commands. However, in the case of the diff transient, these arguments may be taken from those currently in use in the current -repository’s diff buffer, depending on the value of +repository's diff buffer, depending on the value of ‘magit-prefix-use-buffer-arguments’ (see *note Transient Arguments and Buffer Variables::). @@ -3233,7 +3233,7 @@ Buffer Variables::). ‘d p’ (‘magit-diff-paths’) Show changes between any two files on disk. - All of the above suffix commands update the repository’s diff buffer. + All of the above suffix commands update the repository's diff buffer. The diff transient also features two commands which show differences in another buffer: @@ -3298,7 +3298,7 @@ not support these arguments.) current buffer, allowing you to quickly switch between viewing all the changes in the commit and the restricted subset. As a special case, when this command is called from a log buffer, it toggles the - file restriction in the repository’s revision buffer, which is + file restriction in the repository's revision buffer, which is useful when you display a revision from a log buffer that is restricted to a file or files. @@ -3329,10 +3329,10 @@ without having to using one of the diff transient. message buffer. ‘C-c C-b’ (‘magit-go-backward’) - This command moves backward in current buffer’s history. + This command moves backward in current buffer's history. ‘C-c C-f’ (‘magit-go-forward’) - This command moves forward in current buffer’s history. + This command moves forward in current buffer's history. 5.4.2 Commands Available in Diffs --------------------------------- @@ -3352,7 +3352,7 @@ Files and Blobs from a Diff:: for more information and the key bindings. The function specified by this option is used by ‘magit-log-trace-definition’ to determine the function at point. For major-modes that have special needs, you could set the local - value using the mode’s hook. + value using the mode's hook. ‘C-c C-e’ (‘magit-diff-edit-hunk-commit’) From a hunk, this command edits the respective commit and visits @@ -3411,17 +3411,17 @@ they are available here too. variable ‘magit-diff--tab-width-cache’. Set that to nil to invalidate the cache. - • ‘nil’ Never adjust tab width. Use ‘tab-width’s value from the + • ‘nil’ Never adjust tab width. Use 'tab-width's value from the Magit buffer itself instead. • ‘t’ If the corresponding file-visiting buffer exits, then use - ‘tab-width’’s value from that buffer. Doing this is cheap, so + ‘tab-width’'s value from that buffer. Doing this is cheap, so this value is used even if a corresponding cache entry exists. • ‘always’ If there is no such buffer, then temporarily visit the file to determine the value. - • NUMBER Like ‘always’, but don’t visit files larger than NUMBER + • NUMBER Like ‘always’, but don't visit files larger than NUMBER bytes. -- User Option: magit-diff-paint-whitespace @@ -3480,14 +3480,14 @@ they are available here too. ‘magit-diff-highlight-hunk-region-using-underline’ emphasize the region by placing delimiting horizontal lines before and after it. Both of these functions have glitches which cannot be fixed due to - limitations of Emacs’ display engine. For more information see + limitations of Emacs' display engine. For more information see ff. Instead of, or in addition to, using delimiting horizontal lines, to emphasize the boundaries, you may wish to emphasize the text itself, using ‘magit-diff-highlight-hunk-region-using-face’. - In terminal frames it’s not possible to draw lines as the overlay + In terminal frames it's not possible to draw lines as the overlay and underline variants normally do, so there they fall back to calling the face function instead. @@ -3522,7 +3522,7 @@ they are available here too. -- User Option: magit-revision-insert-related-refs Whether to show related branches in revision buffers. - • ‘nil’ Don’t show any related branches. + • ‘nil’ Don't show any related branches. • ‘t’ Show related local branches. • ‘all’ Show related local and remote branches. • ‘mixed’ Show all containing branches and local merged @@ -3531,7 +3531,7 @@ they are available here too. -- User Option: magit-revision-show-gravatars Whether to show gravatar images in revision buffers. - If ‘nil’, then don’t insert any gravatar images. If ‘t’, then + If ‘nil’, then don't insert any gravatar images. If ‘t’, then insert both images. If ‘author’ or ‘committer’, then insert only the respective image. @@ -3539,9 +3539,9 @@ they are available here too. and want to insert the images then you might also have to specify where to do so. In that case the value has to be a cons-cell of two regular expressions. The car specifies where to insert the - author’s image. The top half of the image is inserted right after + author's image. The top half of the image is inserted right after the matched text, the bottom half on the next line in the same - column. The cdr specifies where to insert the committer’s image, + column. The cdr specifies where to insert the committer's image, accordingly. Either the car or the cdr may be nil." -- User Option: magit-revision-use-hash-sections @@ -3553,7 +3553,7 @@ they are available here too. • ‘slow’ calls git for every word to be absolutely sure. • ‘quick’ skips words less than seven characters long. - • ‘quicker’ additionally skips words that don’t contain a + • ‘quicker’ additionally skips words that don't contain a number. • ‘quickest’ uses all words that are at least seven characters long and which contain at least one number as well as at least @@ -3569,17 +3569,17 @@ file restriction as that log buffer (also see the command ‘magit-diff-toggle-file-filter’). -- User Option: magit-revision-filter-files-on-follow - Whether showing a commit from a log buffer honors the log’s file + Whether showing a commit from a log buffer honors the log's file filter when the log arguments include ‘--follow’. When this option is nil, displaying a commit from a log ignores the - log’s file filter if the log arguments include ‘--follow’. Doing + log's file filter if the log arguments include ‘--follow’. Doing so avoids showing an empty diff in revision buffers for commits before a rename event. In such cases, the ‘--patch’ argument of the log transient can be used to show the file-restricted diffs inline. - Set this option to non-nil to keep the log’s file restriction even + Set this option to non-nil to keep the log's file restriction even if ‘--follow’ is present in the log arguments. If the revision buffer is not displayed from a log buffer, the file @@ -3603,7 +3603,7 @@ information on how to use Ediff itself, see *note (ediff)Top::. only be able to guess either the file, or range/commit, in which case the user is asked about the other. It might not always guess right, in which case the appropriate ‘magit-ediff-*’ command has to - be used explicitly. If it cannot read the user’s mind at all, then + be used explicitly. If it cannot read the user's mind at all, then it asks the user for a command to run. ‘E’ (‘magit-ediff’) @@ -3621,11 +3621,11 @@ information on how to use Ediff itself, see *note (ediff)Top::. ‘E m’ (‘magit-ediff-resolve-rest’) This command allows you to resolve outstanding conflicts in the file at point using Ediff. If there is no file at point or if it - doesn’t have any unmerged changes, then this command prompts for a + doesn't have any unmerged changes, then this command prompts for a file. Provided that the value of ‘merge.conflictstyle’ is ‘diff3’, you - can view the file’s merge-base revision using ‘/’ in the Ediff + can view the file's merge-base revision using ‘/’ in the Ediff control buffer. The A, B and Ancestor buffers are constructed from the conflict @@ -3635,11 +3635,11 @@ information on how to use Ediff itself, see *note (ediff)Top::. ‘E M’ (‘magit-ediff-resolve-all’) This command allows you to resolve all conflicts in the file at - point using Ediff. If there is no file at point or if it doesn’t + point using Ediff. If there is no file at point or if it doesn't have any unmerged changes, then this command prompts for a file. Provided that the value of ‘merge.conflictstyle’ is ‘diff3’, you - can view the file’s merge-base revision using ‘/’ in the Ediff + can view the file's merge-base revision using ‘/’ in the Ediff control buffer. First the file in the worktree is moved aside, appending the suffix @@ -3706,7 +3706,7 @@ information on how to use Ediff itself, see *note (ediff)Top::. -- User Option: magit-ediff-show-stash-with-index This option controls whether ‘magit-ediff-show-stash’ includes a - buffer containing the file’s state in the index at the time the + buffer containing the file's state in the index at the time the stash was created. This makes it possible to tell which changes in the stash were staged. @@ -3783,7 +3783,7 @@ the other references are compared. already shown in the heading preceding the list of its branches. -- User Option: magit-refs-primary-column-width - Width of the primary column in ‘magit-refs-mode’ buffers. The + Width of the primary column in 'magit-refs-mode' buffers. The primary column is the column that contains the name of the branch that the current row is about. @@ -3795,13 +3795,13 @@ the other references are compared. taken into account when calculating to optimal width.) -- User Option: magit-refs-focus-column-width - Width of the focus column in ‘magit-refs-mode’ buffers. + Width of the focus column in 'magit-refs-mode' buffers. The focus column is the first column, which marks one branch (usually the current branch) as the focused branch using ‘*’ or ‘@’. For each other reference, this column optionally shows how many commits it is ahead of the focused branch and ‘<’, or if it - isn’t ahead then the commits it is behind and ‘>’, or if it isn’t + isn't ahead then the commits it is behind and ‘>’, or if it isn't behind either, then a ‘=’. This column may also display only ‘*’ or ‘@’ for the focused @@ -3849,7 +3849,7 @@ you should also change the others to keep things aligned. The following • ‘%C’ For the ref which all other refs are compared this is "@", if it is the current branch, or "#" otherwise. For all other refs " ". - • ‘%h’ Hash of this ref’s tip. + • ‘%h’ Hash of this ref's tip. • ‘%m’ Commit summary of the tip of this ref. • ‘%n’ Name of this ref. • ‘%u’ Upstream of this local branch. @@ -3897,7 +3897,7 @@ you should also change the others to keep things aligned. The following ‘magit-show-commit’, and when the type is either ‘branch’ or ‘tag’ then it is bound to ‘magit-visit-ref’. - "RET" is one of Magit’s most essential keys and at least by default + "RET" is one of Magit's most essential keys and at least by default it should behave consistently across all of Magit, especially because users quickly learn that it does something very harmless; it shows more information about the thing at point in another @@ -3905,10 +3905,10 @@ you should also change the others to keep things aligned. The following However "RET" used to behave differently in ‘magit-refs-mode’ buffers, doing surprising things, some of which cannot really be - described as "visit this thing". If you’ve grown accustomed this + described as "visit this thing". If you've grown accustomed this behavior, you can restore it by adding one or more of the below symbols to the value of this option. But keep in mind that by - doing so you don’t only introduce inconsistencies, you also lose + doing so you don't only introduce inconsistencies, you also lose some functionality and might have to resort to ‘M-x magit-show-commit’ to get it back. @@ -3992,8 +3992,8 @@ following suffix commands. Bisecting a bug means to find the commit that introduced it. This command starts such a bisect session by asking for a known good - commit and a known bad commit. If you’re bisecting a change that - isn’t a regression, you can select alternate terms that are + commit and a known bad commit. If you're bisecting a change that + isn't a regression, you can select alternate terms that are conceptually more fitting than "bad" and "good", but the infix arguments to do so are disabled by default. @@ -4180,7 +4180,7 @@ you have to enter the blaming sub-prefix first. Note that not all of the following suffixes are available at all times. For example if ‘magit-blame-mode’ is not enabled, then the command whose purpose is to turn off that mode would not be of any use -and therefore isn’t available. +and therefore isn't available. ‘C-c M-g b’ (‘magit-blame-addition’) ‘C-c M-g B b’ @@ -4189,7 +4189,7 @@ and therefore isn’t available. commits last touched these lines. If the buffer visits a revision of that file, then history up to - that revision is considered. Otherwise, the file’s full history is + that revision is considered. Otherwise, the file's full history is considered, including uncommitted changes. If Magit-Blame mode is already turned on in the current buffer then @@ -4215,7 +4215,7 @@ and therefore isn’t available. ‘C-c M-g e’ (‘magit-blame-echo’) ‘C-c M-g B e’ - This command is like ‘magit-blame-addition’ except that it doesn’t + This command is like ‘magit-blame-addition’ except that it doesn't turn on ‘read-only-mode’ and that it initially uses the visualization style specified by option ‘magit-blame-echo-style’. @@ -4273,10 +4273,10 @@ and Read-Only mode are enabled. during a recursive blame, then it also kills the buffer. ‘M-w’ (‘magit-blame-copy-hash’) - This command saves the hash of the current chunk’s commit to the + This command saves the hash of the current chunk's commit to the kill ring. - When the region is active, the command saves the region’s content + When the region is active, the command saves the region's content instead of the hash, like ‘kill-ring-save’ would. ‘c’ (‘magit-blame-cycle-style’) @@ -4421,7 +4421,7 @@ is used and on the value of ‘magit-clone-always-transient’. insists on creating it. This is because the reference has not been found to be particularly useful as it is not automatically updated when the ‘HEAD’ of the remote changes. Setting this option to ‘t’ - preserves Git’s default behavior of creating the reference. + preserves Git's default behavior of creating the reference. -- User Option: magit-clone-set-remote.pushDefault This option controls whether the value of the Git variable @@ -4519,7 +4519,7 @@ apply variants are described in the next section. With a prefix argument and an untracked file (or files) at point, stage the file but not its content. This makes it possible to - stage only a subset of the new file’s changes. + stage only a subset of the new file's changes. ‘S’ (‘magit-stage-modified’) Stage all changes to files modified in the worktree. Stage all new @@ -4572,7 +4572,7 @@ apply variants are described in the next section. ---------------------------------------- Fine-grained un-/staging has to be done from the status or a diff -buffer, but it’s also possible to un-/stage all changes made to the file +buffer, but it's also possible to un-/stage all changes made to the file visited in the current buffer right from inside that buffer. ‘M-x magit-stage-file’ @@ -4657,7 +4657,7 @@ that file in the editor specified by ‘$EDITOR’ (or ‘$GIT_EDITOR’). Magit arranges for that editor to be the Emacsclient. Once the user finishes the editing session, the Emacsclient exits and Git creates the -commit, using the file’s content as the commit message. +commit, using the file's content as the commit message. 6.5.1 Initiating a Commit ------------------------- @@ -4892,7 +4892,7 @@ Options used by commit commands committed is automatically shown. The idea is that the diff is shown in a different window of the same frame and for most users that just works. In other words most users can - completely ignore this option because its value doesn’t make a + completely ignore this option because its value doesn't make a difference for them. However for users who configured Emacs to never create a new @@ -5031,7 +5031,7 @@ Using the Revision Stack First INDEX-REGEXP is used to find the previously inserted entry, by searching backward from point. The first submatch must match the index number. That number is incremented by one, and becomes - the index number of the entry to be inserted. If you don’t want to + the index number of the entry to be inserted. If you don't want to number the inserted revisions, then use nil for INDEX-REGEXP. If INDEX-REGEXP is non-nil then both POINT-FORMAT and EOB-FORMAT @@ -5093,7 +5093,7 @@ different projects impose different commit message conventions. The value of this option is the major mode used to edit Git commit messages. - Because ‘git-commit-mode’ is a minor mode, we don’t use its mode hook + Because ‘git-commit-mode’ is a minor mode, we don't use its mode hook to setup the buffer, except for the key bindings. All other setup happens in the function ‘git-commit-setup’, which among other things runs the hook ‘git-commit-setup-hook’. @@ -5139,7 +5139,7 @@ The following functions are suitable for this hook: typing a message into a buffer, then this hook is not run. This hook is not run until the new commit has been created. If - doing so takes Git longer than one second, then this hook isn’t run + doing so takes Git longer than one second, then this hook isn't run at all. For certain commands such as ‘magit-rebase-continue’ this hook is never run because doing so would lead to a race condition. @@ -5154,7 +5154,7 @@ Git-Commit highlights certain violations of commonly accepted commit message conventions. Certain violations even cause Git-Commit to ask you to confirm that you really want to do that. This nagging can of course be turned off, but the result of doing that usually is that -instead of some code it’s now the human who is reviewing your commits +instead of some code it's now the human who is reviewing your commits who has to waste some time telling you to fix your commits. -- User Option: git-commit-summary-max-length @@ -5207,7 +5207,7 @@ the branch it is being pushed to should differ. The commits on feature branches too should _eventually_ end up in a remote branch such as ‘origin/master’ or ‘origin/maint’. Such a branch should therefore be used as the upstream. But feature branches -shouldn’t be pushed directly to such branches. Instead a feature branch +shouldn't be pushed directly to such branches. Instead a feature branch ‘my-feature’ is usually pushed to ‘my-fork/my-feature’ or if you are a contributor ‘origin/my-feature’. After the new feature has been reviewed, the maintainer merges the feature into ‘master’. And finally @@ -5233,7 +5233,7 @@ push-remote, ‘u’ is bound to a command which acts on the upstream, and buffer shows unpushed and unpulled commits for both the push-remote and the upstream. - It’s fairly simple to configure these two remotes. The values of all + It's fairly simple to configure these two remotes. The values of all the variables that are related to fetching, pulling, and pushing (as well as some other branch-related variables) can be inspected and changed using the command ‘magit-branch-configure’, which is available @@ -5278,7 +5278,7 @@ them. Those features are available from separate transient command. Without a prefix argument this depends on whether it was invoked as a suffix of ‘magit-branch’ and on the ‘magit-branch-direct-configure’ option. If ‘magit-branch’ already - displays the variables for the current branch, then it isn’t useful + displays the variables for the current branch, then it isn't useful to invoke another transient that displays them for the same branch. In that case this command prompts for a branch. @@ -5353,7 +5353,7 @@ them. Those features are available from separate transient command. The commit at the other end of the selection actually does not matter, all commits between FROM and ‘HEAD’ are moved to the new branch. If FROM is not reachable from ‘HEAD’ or is reachable from - the source branch’s upstream, then an error is raised. + the source branch's upstream, then an error is raised. ‘b S’ (‘magit-branch-spinout’) This command behaves like ‘magit-branch-spinoff’, except that it @@ -5369,7 +5369,7 @@ them. Those features are available from separate transient command. user has to confirm the reset because those changes would be lost. This is useful when you have started work on a feature branch but - realize it’s all crap and want to start over. + realize it's all crap and want to start over. When resetting to another branch and a prefix argument is used, then the target branch is set as the upstream of the branch that is @@ -5407,7 +5407,7 @@ them. Those features are available from separate transient command. If the chosen starting point is a branch, then it may also be set as the upstream of the new branch, depending on the value of the - Git variable ‘branch.autoSetupMerge’. By default this is done for + Git variable 'branch.autoSetupMerge'. By default this is done for remote branches, but not for local branches. You might prefer to always use some remote branch as upstream. If @@ -5418,7 +5418,7 @@ them. Those features are available from separate transient command. the chosen branch is used as starting point, but its own upstream is used as the upstream of the new branch. - Members of this option’s value are treated as branch names that + Members of this option's value are treated as branch names that have to match exactly unless they contain a character that makes them invalid as a branch name. Recommended characters to use to trigger interpretation as a regexp are "*" and "^". Some other @@ -5586,7 +5586,7 @@ set at this time. This variable specifies under what circumstances creating a branch NAME should result in the variables ‘branch.NAME.merge’ and ‘branch.NAME.remote’ being set according to the starting point used - to create the branch. If the starting point isn’t a branch, then + to create the branch. If the starting point isn't a branch, then these variables are never set. • When ‘always’ then the variables are set regardless of whether @@ -5700,7 +5700,7 @@ following suffix commands. Before the source branch is merged, it is first force pushed to its push-remote, provided the respective remote branch already exists. - This ensures that the respective pull-request (if any) won’t get + This ensures that the respective pull-request (if any) won't get stuck on some obsolete version of the commits that are being merged. Finally, if ‘magit-branch-pull-request’ was used to create the merged branch, then the respective remote branch is also @@ -5713,7 +5713,7 @@ following suffix commands. Before the source branch is merged, it is first force pushed to its push-remote, provided the respective remote branch already exists. - This ensures that the respective pull-request (if any) won’t get + This ensures that the respective pull-request (if any) won't get stuck on some obsolete version of the commits that are being merged. Finally, if ‘magit-branch-pull-request’ was used to create the merged branch, then the respective remote branch is also @@ -5740,7 +5740,7 @@ following suffix commands. ‘m m’ (‘magit-merge’) After the user resolved conflicts, this command proceeds with the - merge. If some conflicts weren’t resolved, then this command + merge. If some conflicts weren't resolved, then this command fails. ‘m a’ (‘magit-merge-abort’) @@ -5761,7 +5761,7 @@ versions, or "sides of the conflict", are to be combined into one. Here we can only provide a brief introduction to the subject and point you toward some tools that can help. If you are new to this, then -please also consult Git’s own documentation as well as other resources. +please also consult Git's own documentation as well as other resources. If a file has conflicts and Git cannot resolve them by itself, then it puts both versions into the affected file along with special markers @@ -5816,7 +5816,7 @@ also provides some packages that help in the process: Smerge, Ediff (*note (ediff)Top::), and Emerge (*note (emacs)Emerge::). Magit does not provide its own tools for conflict resolution, but it does make using Smerge and Ediff more convenient. (Ediff supersedes Emerge, so -you probably don’t want to use the latter anyway.) +you probably don't want to use the latter anyway.) In the Magit status buffer, files with unresolved conflicts are listed in the "Unstaged changes" and/or "Staged changes" sections. They @@ -5933,7 +5933,7 @@ onto ‘master’. That way if things turn out to be more complicated than you thought and/or you make a mistake and have to start over, then you only have to redo half the work. - Explicitly enabling ‘--interactive’ won’t have an effect on the + Explicitly enabling ‘--interactive’ won't have an effect on the following commands as they always use that argument anyway, even if it is not enabled in the transient. @@ -6026,7 +6026,7 @@ following suffix commands. ‘f’ (‘git-rebase-fixup’) Meld commit on current line into previous commit, discarding the - current commit’s message. + current commit's message. ‘k’ (‘git-rebase-kill-line’) Kill the current action line. @@ -6120,7 +6120,7 @@ shown in different colors to indicate the status of the commits. • The blue commit is the ‘HEAD’ commit. • The green commit is the commit the rebase sequence stopped at. If - this is the same commit as ‘HEAD’ (e.g., because you haven’t done + this is the same commit as ‘HEAD’ (e.g., because you haven't done anything yet after rebase stopped at the commit, then this commit is shown in blue, not green). There can only be a green *and* a blue commit at the same time, if you create one or more new commits @@ -6169,7 +6169,7 @@ shown in different colors to indicate the status of the commits. • When a commit is prefixed with ‘void’, then that indicates that Magit knows for sure that all the changes in that commit have been applied using several new commits. This commit is - no longer reachable from ‘HEAD’, and it also isn’t one of the + no longer reachable from ‘HEAD’, and it also isn't one of the commits that will be applied when resuming the session. • When a commit is prefixed with ‘join’, then that indicates @@ -6178,7 +6178,7 @@ shown in different colors to indicate the status of the commits. has already been applied. In a sense this is the commit rebase stopped at, but while its effect is already in the index and in the worktree (with conflict markers), the commit - itself has not actually been applied yet (it isn’t the + itself has not actually been applied yet (it isn't the ‘HEAD’). So it is shown in yellow, like the other commits that still have to be applied. @@ -6248,7 +6248,7 @@ shown in different colors to indicate the status of the commits. be, but if so, then there must also be other changes which makes it impossible to know for sure. - Do not worry if you do not fully understand the above. That’s okay, + Do not worry if you do not fully understand the above. That's okay, you will acquire a good enough understanding through practice. For other sequence operations such as cherry-picking, a similar @@ -6307,7 +6307,7 @@ using either ‘git-update-ref’ or if necessary ‘git-rebase’. Both applying commits as well as removing them using ‘git-rebase’ can lead to conflicts. If that happens, then these commands abort and you not only have to resolve the conflicts but also finish the process the same way -you would have to if these commands didn’t exist at all. +you would have to if these commands didn't exist at all. ‘A h’ (‘magit-cherry-harvest’) This command moves the selected COMMITS that must be located on @@ -6411,7 +6411,7 @@ Also see *note (gitman)git-reset::. Reset the ‘HEAD’ and index to some commit read from the user and defaulting to the commit at point, and possibly also reset the working tree. With a prefix argument reset the working tree - otherwise don’t. + otherwise don't. ‘X m’ (‘magit-reset-mixed’) Reset the ‘HEAD’ and index to some commit read from the user and @@ -6508,7 +6508,7 @@ Also see *note (gitman)git-stash::. First try ‘git stash apply --index’, which tries to preserve the index stored in the stash, if any. This may fail because applying the stash could result in conflicts and those have to be stored in - the index, making it impossible to also store the stash’s index + the index, making it impossible to also store the stash's index there. If ‘git stash’ fails, then potentially fall back to using ‘git @@ -6520,7 +6520,7 @@ Also see *note (gitman)git-stash::. ‘z p’ (‘magit-stash-pop’) Apply a stash to the working tree. On complete success (if the stash can be applied without any conflicts, and while preserving - the stash’s index) then remove the stash from stash list. + the stash's index) then remove the stash from stash list. When using a Git release before v2.38.0, simply run ‘git stash pop’ or with a prefix argument ‘git stash pop --index’. @@ -6530,7 +6530,7 @@ Also see *note (gitman)git-stash::. First try ‘git stash pop --index’, which tries to preserve the index stored in the stash, if any. This may fail because applying the stash could result in conflicts and those have to be stored in - the index, making it impossible to also store the stash’s index + the index, making it impossible to also store the stash's index there. If ‘git stash’ fails, then potentially fall back to using ‘git @@ -6560,7 +6560,7 @@ Also see *note (gitman)git-stash::. Create a patch from STASH. ‘k’ (‘magit-stash-clear’) - Remove all stashes saved in REF’s reflog by deleting REF. + Remove all stashes saved in REF's reflog by deleting REF. ‘z l’ (‘magit-stash-list’) List all stashes in a buffer. @@ -6694,11 +6694,11 @@ features are available from separate transient commands. set ‘remote.pushDefault’ after adding a remote. If ‘ask’, then users is always ask. If ‘ask-if-unset’, then the - user is only if the variable isn’t set already. If ‘nil’, then the - user isn’t asked and the variable isn’t set. If the value is a + user is only if the variable isn't set already. If ‘nil’, then the + user isn't asked and the variable isn't set. If the value is a string, then the variable is set without the user being asked, provided that the name of the added remote is equal to that string - and the variable isn’t already set. + and the variable isn't already set. 7.1.2 Remote Git Variables -------------------------- @@ -6889,9 +6889,9 @@ and the push-remote, see *note The Two Remotes::. One of the infix arguments, ‘--force-with-lease’, deserves a word of caution. It is passed without a value, which means "permit a force push as long as the remote-tracking branches match their counterparts on the -remote end". If you’ve set up a tool to do automatic fetches (Magit +remote end". If you've set up a tool to do automatic fetches (Magit itself does not provide such functionality), using ‘--force-with-lease’ -can be dangerous because you don’t actually control or know the state of +can be dangerous because you don't actually control or know the state of the remote-tracking refs. In that case, you should consider setting ‘push.useForceIfIncludes’ to ‘true’ (available since Git 2.30). @@ -7143,14 +7143,14 @@ Also see *note (gitman)git-submodule::. ------------------------ The command ‘magit-list-submodules’ displays a list of the current -repository’s submodules in a separate buffer. It’s also possible to +repository's submodules in a separate buffer. It's also possible to display information about submodules directly in the status buffer of the super-repository by adding ‘magit-insert-modules’ to the hook ‘magit-status-sections-hook’ as described in *note Status Module Sections::. -- Command: magit-list-submodules - This command displays a list of the current repository’s populated + This command displays a list of the current repository's populated submodules in a separate buffer. It can be invoked by pressing ‘RET’ on the section titled @@ -7193,7 +7193,7 @@ Sections::. Some of the below commands default to act on the modules that are selected using the region. For brevity their description talk about "the selected modules", but if no modules are selected, then they act on -the current module instead, or if point isn’t on a module, then the read +the current module instead, or if point isn't on a module, then the read a single module to act on. With a prefix argument these commands ignore the selection and the current module and instead act on all suitable modules. @@ -7207,7 +7207,7 @@ modules. ‘o r’ (‘magit-submodule-register’) This command registers the selected modules by copying their urls from ".gitmodules" to "$GIT_DIR/config". These values can then be - edited before running ‘magit-submodule-populate’. If you don’t + edited before running ‘magit-submodule-populate’. If you don't need to edit any urls, then use the latter directly. ‘o p’ (‘magit-submodule-populate’) @@ -7227,7 +7227,7 @@ modules. This command removes the working directory of the selected modules. ‘o l’ (‘magit-list-submodules’) - This command displays a list of the current repository’s modules. + This command displays a list of the current repository's modules. ‘o f’ (‘magit-fetch-modules’) This command fetches all populated modules. With a prefix @@ -7334,8 +7334,8 @@ of directories. See *note (gitman)git-sparse-checkout::. *Warning*: Git introduced the ‘git sparse-checkout’ command in version 2.25 and still advertises it as experimental and subject to -change. Magit’s interface should be considered the same. In -particular, if Git introduces a backward incompatible change, Magit’s +change. Magit's interface should be considered the same. In +particular, if Git introduces a backward incompatible change, Magit's sparse checkout functionality may be updated in a way that requires a more recent Git version. @@ -7416,7 +7416,7 @@ File: magit.info, Node: Common Commands, Next: Wip Modes, Prev: Bundle, Up: These are some of the commands that can be used in all buffers whose major-modes derive from ‘magit-mode’. There are other common commands -beside the ones below, but these didn’t fit well anywhere else. +beside the ones below, but these didn't fit well anywhere else. ‘C-w’ (‘magit-copy-section-value’) This command saves the value of the current section to the @@ -7526,11 +7526,11 @@ when using these commands. have existed before invoking this command (but of course only after committing that to the working tree wip ref). - Note that even if you enable ‘magit-wip-mode’ this won’t give you + Note that even if you enable ‘magit-wip-mode’ this won't give you perfect protection. The most likely scenario for losing changes despite the use of ‘magit-wip-mode’ is making a change outside Emacs and then destroying it also outside Emacs. In some such a scenario, Magit, being -an Emacs package, didn’t get the opportunity to keep you from shooting +an Emacs package, didn't get the opportunity to keep you from shooting yourself in the foot. When you are unsure whether Magit did commit a change to the wip @@ -7688,7 +7688,7 @@ restart Emacs. (setq magit-define-global-key-bindings 'recommended) - If you don’t want Magit to add any bindings to the global keymap at + If you don't want Magit to add any bindings to the global keymap at all, add this to your init file and restart Emacs. (setq magit-define-global-key-bindings nil) @@ -7890,7 +7890,7 @@ File: magit.info, Node: Customizing, Next: Plumbing, Prev: Miscellaneous, Up Both Git and Emacs are highly customizable. Magit is both a Git porcelain as well as an Emacs package, so it makes sense to customize it using both Git variables as well as Emacs options. However this -flexibility doesn’t come without problems, including but not limited to +flexibility doesn't come without problems, including but not limited to the following. • Some Git variables automatically have an effect in Magit without @@ -7907,7 +7907,7 @@ the following. commands (because they simply call the respective Git command) but their value is not reflected in the respective transient buffers. In this case the ‘--prune’ argument in ‘magit-fetch’ might be - active or inactive, but that doesn’t keep the Git variable from + active or inactive, but that doesn't keep the Git variable from being honored by the suffix commands anyway. So pruning might happen despite the ‘--prune’ arguments being displayed in a way that seems to indicate that no pruning will happen. @@ -8011,15 +8011,15 @@ disabled by adding a symbol to ‘magit-no-confirm’ (see *note Completion and Confirmation::). If you enable the various wip modes then you should add ‘safe-with-wip’ to this list. - Similarly it isn’t necessary to require confirmation before moving a + Similarly it isn't necessary to require confirmation before moving a file to the system trash - if you trashed a file by mistake then you can recover it from there. Option ‘magit-delete-by-moving-to-trash’ controls whether the system trash is used, which is the case by default. -Nevertheless, ‘trash’ isn’t a member of ‘magit-no-confirm’ - you might +Nevertheless, ‘trash’ isn't a member of ‘magit-no-confirm’ - you might want to change that. By default buffers visiting files are automatically reverted when the -visited file changes on disk. This isn’t as risky as it might seem, but +visited file changes on disk. This isn't as risky as it might seem, but to make an informed decision you should see *note Risk of Reverting Automatically::. @@ -8069,7 +8069,7 @@ should help. File-Visiting Buffers::. If you have enabled any features that are disabled by default, then -you should check whether they impact performance significantly. It’s +you should check whether they impact performance significantly. It's likely that they were not enabled by default because it is known that they reduce performance at least in large repositories. @@ -8087,18 +8087,18 @@ Log Performance When showing logs, Magit limits the number of commits initially shown in the hope that this avoids unnecessary work. When ‘--graph’ is used, then this unfortunately does not have the desired effect for large -histories. Junio, Git’s maintainer, said on the Git mailing list +histories. Junio, Git's maintainer, said on the Git mailing list (): "‘--graph’ wants to compute the whole history and the max-count only affects the output phase after ‘--graph’ does its computation". - In other words, it’s not that Git is slow at outputting the + In other words, it's not that Git is slow at outputting the differences, or that Magit is slow at parsing the output - the problem is that Git first goes outside and has a smoke. We actually work around this issue by limiting the number of commits not only by using ‘-’ but by also using a range. But unfortunately -that’s not always possible. +that's not always possible. When more than a few thousand commits are shown, then the use of ‘--graph’ can slow things down. @@ -8137,7 +8137,7 @@ both the diff (‘d’) and the diff refresh (‘D’) transient popups. Refs Buffer Performance ....................... -When refreshing the "references buffer" is slow, then that’s usually +When refreshing the "references buffer" is slow, then that's usually because several hundred refs are being displayed. The best way to address that is to display fewer refs, obviously. @@ -8156,7 +8156,7 @@ Committing Performance When you initiate a commit, then Magit by default automatically shows a diff of the changes you are about to commit. For large commits this can take a long time, which is especially distracting when you are -committing large amounts of generated data which you don’t actually +committing large amounts of generated data which you don't actually intend to inspect before committing. This behavior can be turned off using: @@ -8177,7 +8177,7 @@ Microsoft Windows Performance In order to update the status buffer, ‘git’ has to be run a few dozen times. That is problematic on Microsoft Windows, because that operating system is exceptionally slow at starting processes. Sadly this is an -issue that can only be fixed by Microsoft itself, and they don’t appear +issue that can only be fixed by Microsoft itself, and they don't appear to be particularly interested in doing so. Beside the subprocess issue, there are also other Windows-specific @@ -8212,7 +8212,7 @@ more information. Additionally, ‘git’ installed from a package manager like ‘brew’ or ‘nix’ seems to be slower than the native executable. Profile the ‘git’ -executable you’re running against the one at ‘/usr/bin/git’, and if you +executable you're running against the one at ‘/usr/bin/git’, and if you notice a notable difference try using the latter as ‘magit-git-executable’. @@ -8259,7 +8259,7 @@ notice a notable difference try using the latter as To set this variable use either ‘setq’ or the Custom interface. Do not use the function ‘customize-set-variable’ because doing that would cause Magit to be loaded immediately, when that form is - evaluated (this differs from ‘custom-set-variables’, which doesn’t + evaluated (this differs from ‘custom-set-variables’, which doesn't load the libraries that define the customized variables). Setting this variable has no effect if ‘after-init-hook’ has @@ -8276,14 +8276,14 @@ File: magit.info, Node: Plumbing, Next: FAQ, Prev: Customizing, Up: Top 10 Plumbing *********** -The following sections describe how to use several of Magit’s core +The following sections describe how to use several of Magit's core abstractions to extend Magit itself or implement a separate extension. A few of the low-level features used by Magit have been factored out into separate libraries/packages, so that they can be used by other packages, without having to depend on Magit. See *note (with-editor)Top:: for information about ‘with-editor’. ‘transient’ -doesn’t have a manual yet. +doesn't have a manual yet. If you are trying to find an unused key that you can bind to a command provided by your own Magit extension, then checkout @@ -8370,20 +8370,20 @@ side-effects, but that should be avoided. If the value of option ‘magit-git-debug’ is non-nil and git exits with a non-zero exit status, then warn about that in the echo area - and add a section containing git’s standard error in the current - repository’s process buffer. + and add a section containing git's standard error in the current + repository's process buffer. -- Function: magit-process-git destination &rest args Calls Git synchronously in a separate process, returning its exit code. DESTINATION specifies how to handle the output, like for ‘call-process’, except that file handlers are supported. Enables - Cygwin’s "noglob" option during the call and ensures unix eol + Cygwin's "noglob" option during the call and ensures unix eol conversion. -- Function: magit-process-file process &optional infile buffer display &rest args Processes files synchronously in a separate process. Identical to - ‘process-file’ but temporarily enables Cygwin’s "noglob" option + ‘process-file’ but temporarily enables Cygwin's "noglob" option during the call and ensures unix eol conversion. If an error occurs when using one of the above functions, then that @@ -8395,15 +8395,15 @@ need to be able to debug them. Whether to report errors that occur when using ‘magit-git-insert’, ‘magit-git-string’, ‘magit-git-lines’, or ‘magit-git-items’. This does not actually raise an error. Instead a message is shown in - the echo area, and git’s standard error is insert into a new - section in the current repository’s process buffer. + the echo area, and git's standard error is insert into a new + section in the current repository's process buffer. -- Function: magit-git-str &rest args This is a variant of ‘magit-git-string’ that ignores the option ‘magit-git-debug’. It is mainly intended to be used while handling errors in functions that do respect that option. Using such a function while handing an error could cause yet another error and - therefore lead to an infinite recursion. You probably won’t ever + therefore lead to an infinite recursion. You probably won't ever need to use this function. 10.1.2 Calling Git for Effect @@ -8412,7 +8412,7 @@ need to be able to debug them. These functions are used to run git to produce some effect. Most Magit commands that actually run git do so by using such a function. - Because we do not need to consume git’s output when using these + Because we do not need to consume git's output when using these functions, their output is instead logged into a per-repository buffer, which can be shown using ‘$’ from a Magit buffer or ‘M-x magit-process’ elsewhere. @@ -8420,7 +8420,7 @@ elsewhere. These functions can have an effect in two distinct ways. Firstly, running git may change something, i.e., create or push a new commit. Secondly, that change may require that Magit buffers are refreshed to -reflect the changed state of the repository. But refreshing isn’t +reflect the changed state of the repository. But refreshing isn't always desirable, so only some of these functions do perform such a refresh after git has returned. @@ -8444,7 +8444,7 @@ refresh because that also automatically moves to the next change. Calls git synchronously with ARGS and sends it the content of the current buffer on standard input. - If the current buffer’s ‘default-directory’ is on a remote + If the current buffer's ‘default-directory’ is on a remote filesystem, this function actually runs git asynchronously. But then it waits for the process to return, so the function itself is synchronous. @@ -8561,7 +8561,7 @@ File: magit.info, Node: Section Plumbing, Next: Refreshing Buffers, Prev: Cal recreated during a refresh, then the visibility of predecessor is inherited and HIDE is ignored (but the hook is still honored). - BODY is any number of forms that actually insert the section’s + BODY is any number of forms that actually insert the section's heading and body. Optional NAME, if specified, has to be a symbol, which is then bound to the struct of the section being inserted. @@ -8573,7 +8573,7 @@ File: magit.info, Node: Section Plumbing, Next: Refreshing Buffers, Prev: Cal If it turns out inside BODY that the section is empty, then ‘magit-cancel-section’ can be used to abort and remove all traces of the partially inserted section. This can happen when creating a - section by washing Git’s output and Git didn’t actually output + section by washing Git's output and Git didn't actually output anything this time around. -- Function: magit-insert-heading &rest args @@ -8600,7 +8600,7 @@ File: magit.info, Node: Section Plumbing, Next: Refreshing Buffers, Prev: Cal ‘content’ is nil, then the section has no heading and its body cannot be collapsed. If a section does have a heading then its height must be exactly one line, including a trailing newline - character. This isn’t enforced; you are responsible for getting it + character. This isn't enforced; you are responsible for getting it right. The only exception is that this function does insert a newline character if necessary. @@ -8637,7 +8637,7 @@ File: magit.info, Node: Section Plumbing, Next: Refreshing Buffers, Prev: Cal selection is invalid. When the selection is valid then the region uses the ‘magit-section-highlight’ face. This does not apply to diffs where things get a bit more complicated, but even here if the - region looks like it usually does, then that’s not a valid + region looks like it usually does, then that's not a valid selection as far as this function is concerned. If optional CONDITION is non-nil, then the selection not only has @@ -8678,8 +8678,8 @@ File: magit.info, Node: Section Plumbing, Next: Refreshing Buffers, Prev: Cal • ‘[CLASS...]’ - matches if the section’s class is the same as the first CLASS - or a subclass of that; the section’s parent class matches the + matches if the section's class is the same as the first CLASS + or a subclass of that; the section's parent class matches the second CLASS; and so on. • ‘[* CLASS...]’ @@ -8689,7 +8689,7 @@ File: magit.info, Node: Section Plumbing, Next: Refreshing Buffers, Prev: Cal • ‘CLASS’ - matches if the section’s class is the same as CLASS or a + matches if the section's class is the same as CLASS or a subclass of that; regardless of the classes of the parent sections. @@ -8743,8 +8743,8 @@ File: magit.info, Node: Section Plumbing, Next: Refreshing Buffers, Prev: Cal ‘committed’, or ‘undefined’. This type serves a similar purpose as the general type common to all sections (which is stored in the ‘type’ slot of the corresponding ‘magit-section’ struct) but takes - additional information into account. When the SECTION isn’t - related to diffs and the buffer containing it also isn’t a + additional information into account. When the SECTION isn't + related to diffs and the buffer containing it also isn't a diff-only buffer, then return nil. Currently the type can also be one of ‘tracked’ and ‘untracked’, @@ -8761,7 +8761,7 @@ File: magit.info, Node: Section Plumbing, Next: Refreshing Buffers, Prev: Cal -- Function: magit-diff-scope &optional section strict Return the diff scope of SECTION or the selected section(s). - A diff’s "scope" describes what part of a diff is selected, it is a + A diff's "scope" describes what part of a diff is selected, it is a symbol, one of ‘region’, ‘hunk’, ‘hunks’, ‘file’, ‘files’, or ‘list’. Do not confuse this with the diff "type", as returned by ‘magit-diff-type’. @@ -8821,7 +8821,7 @@ where ‘*’ may be something like ‘diff’) with the value of can later be restored by ‘magit-mode-bury-buffer’. The buffer is displayed and selected using SWITCH-FUNCTION. If - that is ‘nil’ then ‘pop-to-buffer’ is used if the current buffer’s + that is ‘nil’ then ‘pop-to-buffer’ is used if the current buffer's major mode derives from ‘magit-mode’. Otherwise ‘switch-to-buffer’ is used. @@ -8836,7 +8836,7 @@ where ‘*’ may be something like ‘diff’) with the value of arguments. The value is usually set using ‘magit-mode-setup’, but in some - cases it’s also useful to provide commands that can change the + cases it's also useful to provide commands that can change the value. For example, the ‘magit-diff-refresh’ transient can be used to change any of the arguments used to display the diff, without having to specify again which differences should be shown, but @@ -8866,7 +8866,7 @@ color and a box around them. The basic default faces no longer do so, to make Magit buffers much less noisy, and you should follow that example at least with regards to boxes. (Boxes were used in the past to work around a conflict between the highlighting overlay and text -property backgrounds. That’s no longer necessary because highlighting +property backgrounds. That's no longer necessary because highlighting no longer causes other background colors to disappear.) Alternatively you can keep the background color and/or box, but then have to take special care to adjust ‘magit-branch-current’ accordingly. By default @@ -8899,7 +8899,7 @@ use a light (possibly tinted) gray as the background color of ‘default’ and a somewhat darker gray for the background of ‘region’. That should usually be enough to not collide with the foreground color of any other face. But if some other faces also set a light gray as background -color, then you should also make sure it doesn’t collide with those (in +color, then you should also make sure it doesn't collide with those (in some cases it might be acceptable though). Magit only uses the ‘region’ face when the region is "invalid" by its @@ -8907,13 +8907,13 @@ own definition. In a Magit buffer the region is used to either select multiple sibling sections, so that commands which support it act on all of these sections instead of just the current section, or to select lines within a single hunk section. In all other cases, the section is -considered invalid and Magit won’t act on it. But such invalid sections +considered invalid and Magit won't act on it. But such invalid sections happen, either because the user has not moved point enough yet to make it valid or because she wants to use a non-magit command to act on the region, e.g., ‘kill-region’. So using the regular ‘region’ face for invalid sections is a feature. -It tells the user that Magit won’t be able to act on it. It’s +It tells the user that Magit won't be able to act on it. It's acceptable if that face looks a bit odd and even (but less so) if it collides with the background colors of section headings and other things that have a background color. @@ -8970,7 +8970,7 @@ make sure the file and diff headings work nicely with context lines foreground and the background color. For example, for added lines use two different greens. - It’s best if the foreground color of both the highlighted and the + It's best if the foreground color of both the highlighted and the unhighlighted variants are the same, so you will need to have to find a color that works well on the highlight and unhighlighted background, the refine background, and the highlight context background. When there is @@ -8998,7 +8998,7 @@ Appendix A FAQ ************** The next two nodes lists frequently asked questions. For a list of -frequently *and recently* asked questions, i.e., questions that haven’t +frequently *and recently* asked questions, i.e., questions that haven't made it into the manual yet, see . @@ -9020,7 +9020,7 @@ A.1.1 How to pronounce Magit? Either ‘mu[m's] git’ or ‘magi{c => t}’ is fine. - The slogan is "It’s Magit! The magical Git client", so it makes + The slogan is "It's Magit! The magical Git client", so it makes sense to pronounce Magit like magic, while taking into account that C and T do not sound the same. @@ -9034,26 +9034,26 @@ like it better. Also see . Also see . -A.1.2 How to show git’s output? +A.1.2 How to show git's output? ------------------------------- To show the output of recently run git commands, press ‘$’ (or, if that -isn’t available, use ‘M-x magit-process-buffer’). This shows a buffer +isn't available, use ‘M-x magit-process-buffer’). This shows a buffer containing a section per git invocation; as always press ‘TAB’ to expand or collapse them. - By default, git’s output is only inserted into the process buffer if + By default, git's output is only inserted into the process buffer if it is run for side-effects. When the output is consumed in some way, also inserting it into the process buffer would be too expensive. For -debugging purposes, it’s possible to do so anyway, using ‘M-x +debugging purposes, it's possible to do so anyway, using ‘M-x magit-toggle-git-debug’. A.1.3 How to install the gitman info manual? -------------------------------------------- -Git’s manpages can be exported as an info manual called ‘gitman’. -Magit’s own info manual links to nodes in that manual instead of the -actual manpages, simply because Info doesn’t support linking to +Git's manpages can be exported as an info manual called ‘gitman’. +Magit's own info manual links to nodes in that manual instead of the +actual manpages, simply because Info doesn't support linking to manpages. Unfortunately some distributions do not install the ‘gitman’ manual @@ -9086,7 +9086,7 @@ Please see *note Branching:: and A.1.6 Should I disable VC? -------------------------- -If you don’t use VC (the built-in version control interface) then you +If you don't use VC (the built-in version control interface) then you might be tempted to disable it, not least because we used to recommend that you do that. @@ -9130,7 +9130,7 @@ With-Editor:: and *note (with-editor)Debugging::. A.2.4 I am using MS Windows and cannot push with Magit ------------------------------------------------------ -It’s almost certain that Magit is only incidental to this issue. It is +It's almost certain that Magit is only incidental to this issue. It is much more likely that this is a configuration issue, even if you can push on the command line. @@ -9140,14 +9140,14 @@ push on the command line. A.2.5 I am using macOS and SOMETHING works in shell, but not in Magit --------------------------------------------------------------------- -This usually occurs because Emacs doesn’t have the same environment +This usually occurs because Emacs doesn't have the same environment variables as your shell. Try installing and configuring . By default it synchronizes ‘$PATH’, which helps Magit find the same ‘git’ as the one you are using on the shell. If SOMETHING is "passphrase caching with gpg-agent for commit and/or -tag signing", then you’ll also need to synchronize ‘$GPG_AGENT_INFO’. +tag signing", then you'll also need to synchronize ‘$GPG_AGENT_INFO’. A.2.6 Expanding a file to show the diff causes it to disappear -------------------------------------------------------------- @@ -9177,7 +9177,7 @@ help: (when (or git-commit-mode git-rebase-mode) (pointback-mode -1)))) -A.2.8 The mode-line information isn’t always up-to-date +A.2.8 The mode-line information isn't always up-to-date ------------------------------------------------------- Magit is not responsible for the version control information that is @@ -9187,11 +9187,11 @@ information, and can be told to do so more often: (setq auto-revert-check-vc-info t) - But doing so isn’t good for performance. For more (overly + But doing so isn't good for performance. For more (overly optimistic) information see *note (emacs)VC Mode Line::. - If you don’t really care about seeing this information in the -mode-line, but just don’t want to see _incorrect_ information, then + If you don't really care about seeing this information in the +mode-line, but just don't want to see _incorrect_ information, then consider simply not displaying it in the mode-line: (setq-default mode-line-format @@ -9221,7 +9221,7 @@ subprocesses with the ‘--literal-pathspecs’ argument. You can therefore override this setting in hook scripts using ‘unset GIT_LITERAL_PATHSPECS’. -A.2.11 ‘git-commit-mode’ isn’t used when committing from the command-line +A.2.11 ‘git-commit-mode’ isn't used when committing from the command-line ------------------------------------------------------------------------- The reason for this is that ‘git-commit.el’ has not been loaded yet @@ -9236,7 +9236,7 @@ care of these things yourself. Your ‘init.el’ file should contain: (require 'git-commit) (server-mode) - Instead of ‘(require ’git-commit)‘ you may also use: + Instead of '(require 'git-commit)' you may also use: (load "/path/to/magit-autoloads.el") @@ -9261,7 +9261,7 @@ to try. Personally I use: This will actually end up using ‘emacs’, not ‘emacsclient’. If you do this, then you can still edit the commit message but -‘git-commit-mode’ won’t be used and you have to exit ‘emacs’ to finish +‘git-commit-mode’ won't be used and you have to exit ‘emacs’ to finish the process. Tautology ahead. If you want to be able to use ‘emacsclient’ to @@ -9288,7 +9288,7 @@ A.2.13 I am no longer able to save popup defaults ------------------------------------------------- Magit used to use Magit-Popup to implement the transient popup menus. -Now it used Transient instead, which is Magit-Popup’s successor. +Now it used Transient instead, which is Magit-Popup's successor. In the older Magit-Popup menus, it was possible to save user settings (e.g., setting the gpg signing key for commits) by using ‘C-c C-c’ in @@ -9338,14 +9338,14 @@ issue. Please include all relevant output when reporting an issue. When git is run for side-effects then its output, including error messages, go into the process buffer which is shown when using ‘$’. - When git’s output is consumed in some way, then it would be too + When git's output is consumed in some way, then it would be too expensive to also insert it into this buffer, but with this command that can be enabled temporarily. In that case, if git returns with a non-zero exit status, then at least its standard error is inserted into this buffer. Also note that just because git exits with a non-zero status and - prints an error message, that usually doesn’t mean that it is an + prints an error message, that usually doesn't mean that it is an error as far as Magit is concerned, which is another reason we usually hide these error messages. Whether some error message is relevant in the context of some unexpected behavior has to be @@ -9404,6 +9404,9 @@ Appendix C Keystroke Index [index] * Menu: +* -: Logging. (line 163) +* - <1>: Diffing. (line 151) +* :: Running Git. (line 94) * !: Running Git. (line 82) * ! !: Running Git. (line 86) * ! a: Running Git. (line 122) @@ -9414,18 +9417,9 @@ Appendix C Keystroke Index * ! p: Running Git. (line 94) * ! s: Running Git. (line 103) * ! S: Running Git. (line 107) -* $: Running Git. (line 20) +* ^: Sections. (line 44) * +: Logging. (line 160) * + <1>: Diffing. (line 154) -* -: Logging. (line 163) -* - <1>: Diffing. (line 151) -* 0: Diffing. (line 157) -* 1: Sections. (line 163) -* 2: Sections. (line 163) -* 3: Sections. (line 163) -* 4: Sections. (line 163) -* 5: Repository List. (line 115) -* :: Running Git. (line 94) * =: Logging. (line 155) * >: Sparse checkouts. (line 17) * > a: Sparse checkouts. (line 39) @@ -9433,7 +9427,13 @@ Appendix C Keystroke Index * > e: Sparse checkouts. (line 21) * > r: Sparse checkouts. (line 44) * > s: Sparse checkouts. (line 33) -* ^: Sections. (line 44) +* $: Running Git. (line 20) +* 0: Diffing. (line 157) +* 1: Sections. (line 163) +* 2: Sections. (line 163) +* 3: Sections. (line 163) +* 4: Sections. (line 163) +* 5: Repository List. (line 115) * a: Applying. (line 34) * A: Cherry Picking. (line 9) * A A: Cherry Picking. (line 17) @@ -9751,11 +9751,11 @@ Appendix C Keystroke Index * M r: Remotes. (line 55) * m s: Merging. (line 67) * M u: Remotes. (line 59) +* M-: Sections. (line 153) * M-1: Sections. (line 169) * M-2: Sections. (line 169) * M-3: Sections. (line 169) * M-4: Sections. (line 169) -* M-: Sections. (line 153) * M-n: Sections. (line 40) * M-n <1>: Committing. (line 326) * M-n <2>: Rebasing. (line 151) @@ -10824,184 +10824,184 @@ Appendix E Variable Index  Tag Table: -Node: Top774 +Node: Top776 Node: Introduction3572 -Node: Installation8288 -Node: Installing from Melpa8618 -Node: Installing from the Git Repository9693 -Node: Post-Installation Tasks12745 -Node: Getting Started14028 -Node: Interface Concepts19839 -Node: Modes and Buffers20218 -Ref: Switching Buffers21720 -Ref: Naming Buffers26366 -Ref: Quitting Windows29323 -Ref: Automatic Refreshing of Magit Buffers31120 -Ref: Automatic Saving of File-Visiting Buffers33836 -Ref: Automatic Reverting of File-Visiting Buffers34827 -Ref: Risk of Reverting Automatically39619 -Node: Sections41890 -Ref: Section Movement42695 -Ref: Section Visibility47482 -Ref: Section Hooks54060 -Ref: Section Types and Values56349 -Ref: Section Options57650 -Node: Transient Commands58029 -Node: Transient Arguments and Buffer Variables59505 -Node: Completion Confirmation and the Selection66522 -Ref: Action Confirmation66783 -Ref: Completion and Confirmation75156 -Ref: The Selection78187 -Ref: The hunk-internal region80926 -Ref: Support for Completion Frameworks81850 -Ref: Additional Completion Options86554 -Node: Mouse Support87004 -Node: Running Git87580 -Ref: Viewing Git Output87700 -Ref: Git Process Status89591 -Ref: Running Git Manually90435 -Ref: Git Executable93008 -Ref: Global Git Arguments95897 -Node: Inspecting96612 -Node: Status Buffer97769 -Ref: Status Sections102677 -Ref: Status File List Sections105404 -Ref: Status Log Sections107981 -Ref: Status Header Sections109331 -Ref: Status Module Sections111824 -Ref: Status Options114196 -Node: Repository List115465 -Node: Logging120243 -Ref: Refreshing Logs122978 -Ref: Log Buffer124322 -Ref: Log Margin129049 -Ref: Select from Log132106 -Ref: Reflog134224 -Ref: Cherries135771 -Node: Diffing137543 -Ref: Refreshing Diffs141494 -Ref: Commands Available in Diffs145088 -Ref: Diff Options147485 -Ref: Revision Buffer153283 -Node: Ediffing156524 -Node: References Buffer162574 -Ref: References Sections173134 -Node: Bisecting173919 -Node: Visiting Files and Blobs176230 -Ref: General-Purpose Visit Commands176672 -Ref: Visiting Files and Blobs from a Diff177490 -Node: Blaming180799 -Node: Manipulating187787 -Node: Creating Repository188129 -Node: Cloning Repository188666 -Node: Staging and Unstaging195107 -Ref: Staging from File-Visiting Buffers199031 -Node: Applying200046 -Node: Committing202119 -Ref: Initiating a Commit202746 -Ref: Creating a new commit203058 -Ref: Editing the last commit203168 -Ref: Editing any reachable commit205147 -Ref: Editing any reachable commit and rebasing immediately209560 -Ref: Options used by commit commands211208 -Ref: Used by all or most commit commands211280 -Ref: Used by all squash and fixup commands213511 -Ref: Used by specific commit commands214059 -Ref: Editing Commit Messages214383 -Ref: Using the Revision Stack216937 -Ref: Commit Pseudo Headers219869 -Ref: Commit Mode and Hooks221021 -Ref: Commit Message Conventions223734 -Node: Branching225606 -Ref: The Two Remotes225727 -Ref: Branch Commands228296 -Ref: Branch Git Variables241033 -Ref: Auxiliary Branch Commands246280 -Node: Merging247297 -Node: Resolving Conflicts251453 -Node: Rebasing256827 -Ref: Editing Rebase Sequences261536 -Ref: Information About In-Progress Rebase265639 -Ref: Rebasing-Footnote-1274639 -Node: Cherry Picking275235 -Ref: Reverting279545 -Node: Resetting280905 -Node: Stashing282731 -Node: Transferring288972 -Node: Remotes289194 -Ref: Remote Commands289291 -Ref: Remote Git Variables293243 -Node: Fetching294427 -Node: Pulling296910 -Node: Pushing297936 -Node: Plain Patches302227 -Node: Maildir Patches303698 -Node: Miscellaneous305177 -Node: Tagging305523 -Node: Notes307416 -Node: Submodules309751 -Ref: Listing Submodules309912 -Ref: Submodule Transient311968 -Node: Subtree314321 -Node: Worktree316252 -Node: Sparse checkouts317328 -Node: Bundle320104 -Node: Common Commands320479 -Node: Wip Modes323107 -Ref: Wip Graph327953 -Ref: Legacy Wip Modes330187 -Node: Commands for Buffers Visiting Files332995 -Node: Minor Mode for Buffers Visiting Blobs341222 -Node: Customizing342020 -Node: Per-Repository Configuration343616 -Node: Essential Settings345870 -Ref: Safety346159 -Ref: Performance347840 -Ref: Log Performance350633 -Ref: Diff Performance351938 -Ref: Refs Buffer Performance353279 -Ref: Committing Performance353854 -Ref: Microsoft Windows Performance354836 -Ref: MacOS Performance355925 -Ref: Global Bindings356810 -Ref: Essential Settings-Footnote-1358985 -Node: Plumbing359067 -Node: Calling Git359896 -Ref: Getting a Value from Git361355 -Ref: Calling Git for Effect364981 -Node: Section Plumbing370773 -Ref: Creating Sections370925 -Ref: Section Selection374726 -Ref: Matching Sections376401 -Node: Refreshing Buffers382227 -Node: Conventions385371 -Ref: Theming Faces385535 -Node: FAQ393580 -Node: FAQ - How to ...?394018 -Ref: How to pronounce Magit?394151 -Ref: How to show git's output?394845 -Ref: How to install the gitman info manual?395470 -Ref: How to show diffs for gpg-encrypted files?396281 -Ref: How does branching and pushing work?396690 -Ref: Should I disable VC?396854 -Node: FAQ - Issues and Errors397339 -Ref: Magit is slow397484 -Ref: I changed several thousand files at once and now Magit is unusable397630 -Ref: I am having problems committing398169 -Ref: I am using MS Windows and cannot push with Magit398434 -Ref: I am using macOS and SOMETHING works in shell but not in Magit398834 -Ref: Expanding a file to show the diff causes it to disappear399425 -Ref: Point is wrong in the COMMIT_EDITMSG buffer399775 -Ref: The mode-line information isn't always up-to-date400599 -Ref: A branch and tag sharing the same name breaks SOMETHING401438 -Ref: My Git hooks work on the command-line but not inside Magit402086 -Ref: git-commit-mode isn't used when committing from the command-line402678 -Ref: Point ends up inside invisible text when jumping to a file-visiting buffer404676 -Ref: I am no longer able to save popup defaults405268 -Node: Debugging Tools406065 -Node: Keystroke Index410004 -Node: Function and Command Index447954 -Node: Variable Index499464 +Node: Installation8272 +Node: Installing from Melpa8600 +Node: Installing from the Git Repository9671 +Node: Post-Installation Tasks12721 +Node: Getting Started14002 +Node: Interface Concepts19809 +Node: Modes and Buffers20188 +Ref: Switching Buffers21686 +Ref: Naming Buffers26326 +Ref: Quitting Windows29281 +Ref: Automatic Refreshing of Magit Buffers31078 +Ref: Automatic Saving of File-Visiting Buffers33790 +Ref: Automatic Reverting of File-Visiting Buffers34779 +Ref: Risk of Reverting Automatically39567 +Node: Sections41834 +Ref: Section Movement42639 +Ref: Section Visibility47422 +Ref: Section Hooks53996 +Ref: Section Types and Values56281 +Ref: Section Options57580 +Node: Transient Commands57959 +Node: Transient Arguments and Buffer Variables59433 +Node: Completion Confirmation and the Selection66442 +Ref: Action Confirmation66703 +Ref: Completion and Confirmation75060 +Ref: The Selection78091 +Ref: The hunk-internal region80828 +Ref: Support for Completion Frameworks81752 +Ref: Additional Completion Options86452 +Node: Mouse Support86902 +Node: Running Git87478 +Ref: Viewing Git Output87598 +Ref: Git Process Status89479 +Ref: Running Git Manually90323 +Ref: Git Executable92896 +Ref: Global Git Arguments95783 +Node: Inspecting96498 +Node: Status Buffer97645 +Ref: Status Sections102545 +Ref: Status File List Sections105264 +Ref: Status Log Sections107837 +Ref: Status Header Sections109187 +Ref: Status Module Sections111678 +Ref: Status Options114040 +Node: Repository List115309 +Node: Logging120085 +Ref: Refreshing Logs122816 +Ref: Log Buffer124160 +Ref: Log Margin128877 +Ref: Select from Log131934 +Ref: Reflog134050 +Ref: Cherries135597 +Node: Diffing137367 +Ref: Refreshing Diffs141312 +Ref: Commands Available in Diffs144900 +Ref: Diff Options147295 +Ref: Revision Buffer153081 +Node: Ediffing156306 +Node: References Buffer162344 +Ref: References Sections172884 +Node: Bisecting173669 +Node: Visiting Files and Blobs175976 +Ref: General-Purpose Visit Commands176418 +Ref: Visiting Files and Blobs from a Diff177236 +Node: Blaming180545 +Node: Manipulating187523 +Node: Creating Repository187865 +Node: Cloning Repository188402 +Node: Staging and Unstaging194841 +Ref: Staging from File-Visiting Buffers198763 +Node: Applying199776 +Node: Committing201849 +Ref: Initiating a Commit202474 +Ref: Creating a new commit202786 +Ref: Editing the last commit202896 +Ref: Editing any reachable commit204875 +Ref: Editing any reachable commit and rebasing immediately209288 +Ref: Options used by commit commands210936 +Ref: Used by all or most commit commands211008 +Ref: Used by all squash and fixup commands213237 +Ref: Used by specific commit commands213785 +Ref: Editing Commit Messages214109 +Ref: Using the Revision Stack216663 +Ref: Commit Pseudo Headers219593 +Ref: Commit Mode and Hooks220745 +Ref: Commit Message Conventions223454 +Node: Branching225324 +Ref: The Two Remotes225445 +Ref: Branch Commands228010 +Ref: Branch Git Variables240735 +Ref: Auxiliary Branch Commands245980 +Node: Merging246997 +Node: Resolving Conflicts251147 +Node: Rebasing256517 +Ref: Editing Rebase Sequences261224 +Ref: Information About In-Progress Rebase265325 +Ref: Rebasing-Footnote-1274317 +Node: Cherry Picking274913 +Ref: Reverting279221 +Node: Resetting280581 +Node: Stashing282405 +Node: Transferring288638 +Node: Remotes288860 +Ref: Remote Commands288957 +Ref: Remote Git Variables292901 +Node: Fetching294085 +Node: Pulling296568 +Node: Pushing297594 +Node: Plain Patches301881 +Node: Maildir Patches303352 +Node: Miscellaneous304831 +Node: Tagging305177 +Node: Notes307070 +Node: Submodules309405 +Ref: Listing Submodules309566 +Ref: Submodule Transient311616 +Node: Subtree313963 +Node: Worktree315894 +Node: Sparse checkouts316970 +Node: Bundle319742 +Node: Common Commands320117 +Node: Wip Modes322743 +Ref: Wip Graph327585 +Ref: Legacy Wip Modes329819 +Node: Commands for Buffers Visiting Files332627 +Node: Minor Mode for Buffers Visiting Blobs340852 +Node: Customizing341650 +Node: Per-Repository Configuration343242 +Node: Essential Settings345496 +Ref: Safety345785 +Ref: Performance347460 +Ref: Log Performance350251 +Ref: Diff Performance351550 +Ref: Refs Buffer Performance352891 +Ref: Committing Performance353464 +Ref: Microsoft Windows Performance354444 +Ref: MacOS Performance355531 +Ref: Global Bindings356414 +Ref: Essential Settings-Footnote-1358587 +Node: Plumbing358669 +Node: Calling Git359494 +Ref: Getting a Value from Git360953 +Ref: Calling Git for Effect364565 +Node: Section Plumbing370351 +Ref: Creating Sections370503 +Ref: Section Selection374296 +Ref: Matching Sections375969 +Node: Refreshing Buffers381783 +Node: Conventions384923 +Ref: Theming Faces385087 +Node: FAQ393120 +Node: FAQ - How to ...?393556 +Ref: How to pronounce Magit?393689 +Ref: How to show git's output?394381 +Ref: How to install the gitman info manual?394998 +Ref: How to show diffs for gpg-encrypted files?395803 +Ref: How does branching and pushing work?396212 +Ref: Should I disable VC?396376 +Node: FAQ - Issues and Errors396859 +Ref: Magit is slow397004 +Ref: I changed several thousand files at once and now Magit is unusable397150 +Ref: I am having problems committing397689 +Ref: I am using MS Windows and cannot push with Magit397954 +Ref: I am using macOS and SOMETHING works in shell but not in Magit398352 +Ref: Expanding a file to show the diff causes it to disappear398939 +Ref: Point is wrong in the COMMIT_EDITMSG buffer399289 +Ref: The mode-line information isn't always up-to-date400113 +Ref: A branch and tag sharing the same name breaks SOMETHING400944 +Ref: My Git hooks work on the command-line but not inside Magit401592 +Ref: git-commit-mode isn't used when committing from the command-line402184 +Ref: Point ends up inside invisible text when jumping to a file-visiting buffer404172 +Ref: I am no longer able to save popup defaults404764 +Node: Debugging Tools405559 +Node: Keystroke Index409494 +Node: Function and Command Index447444 +Node: Variable Index498954  End Tag Table diff --git a/lisp/markdown-mode/markdown-mode-pkg.el b/lisp/markdown-mode/markdown-mode-pkg.el index bda85d1f..9929084f 100644 --- a/lisp/markdown-mode/markdown-mode-pkg.el +++ b/lisp/markdown-mode/markdown-mode-pkg.el @@ -1,6 +1,6 @@ -(define-package "markdown-mode" "20250226.231" "Major mode for Markdown-formatted text" +(define-package "markdown-mode" "20250310.417" "Major mode for Markdown-formatted text" '((emacs "28.1")) - :commit "f945f12d517ea3fd03bf7d8496c1251dbdf71ebe" :authors + :commit "dd2cb2cdcd6594c3663cda20b465f09c773fcc90" :authors '(("Jason R. Blevins" . "jblevins@xbeta.org")) :maintainers '(("Jason R. Blevins" . "jblevins@xbeta.org")) diff --git a/lisp/markdown-mode/markdown-mode.el b/lisp/markdown-mode/markdown-mode.el index 18fadee8..e9d9bec8 100644 --- a/lisp/markdown-mode/markdown-mode.el +++ b/lisp/markdown-mode/markdown-mode.el @@ -53,6 +53,7 @@ (declare-function sh-set-shell "sh-script") (declare-function mailcap-file-name-to-mime-type "mailcap") (declare-function dnd-get-local-file-name "dnd") +(declare-function dnd-open-local-file "dnd") ;; for older emacs<29 (declare-function mailcap-mime-type-to-extension "mailcap") @@ -108,7 +109,7 @@ Any changes to the output buffer made by this hook will be saved.") :group 'text :link '(url-link "https://jblevins.org/projects/markdown-mode/")) -(defcustom markdown-command (let ((command (cl-loop for cmd in '("markdown" "pandoc" "markdown_py") +(defcustom markdown-command (let ((command (cl-loop for cmd in '("markdown" "pandoc" "markdown_py" "cmark" "cmark-gfm") when (executable-find cmd) return (file-name-nondirectory it)))) (or command "markdown")) @@ -705,6 +706,20 @@ This may also be a cons cell where the behavior for `C-a' and (const :tag "on: before closing tags first" t) (const :tag "reversed: after closing tags first" reversed)))) :package-version '(markdown-mode . "2.7")) + +(defcustom markdown-yank-dnd-method 'file-link + "Action to perform on the dropped files. +When the value is the symbol, + - `copy-and-insert' -- copy file in current directory and insert its link + - `open' -- open dropped file in Emacs + - `insert-link' -- insert link of dropped/pasted file + - `ask' -- ask what to do out of the above." + :group 'markdown + :package-version '(markdown-mode "2.8") + :type '(choice (const :tag "Copy and insert" copy-and-insert) + (const :tag "Open file" open) + (const :tag "Insert file link" file-link) + (const :tag "Ask what to do" ask))) ;;; Markdown-Specific `rx' Macro ============================================== @@ -9898,12 +9913,8 @@ indicate that sorting should be done in reverse order." (t 1)))) (sorting-type (or sorting-type - (progn - ;; workaround #641 - ;; Emacs < 28 hides prompt message by another message. This erases it. - (message "") - (read-char-exclusive - "Sort type: [a]lpha [n]umeric (A/N means reversed): "))))) + (read-char-exclusive + "Sort type: [a]lpha [n]umeric (A/N means reversed): ")))) (save-restriction ;; Narrow buffer to appropriate sorting area (if (region-active-p) @@ -10119,18 +10130,50 @@ rows and columns and the column alignment." (insert " ")) (setq files (cdr files)))))) -(defun markdown--dnd-local-file-handler (url _action) +(defun markdown--dnd-read-method () + (let ((choice (read-multiple-choice "What to do with file?" + '((?c "copy and insert") + (?o "open") + (?i "insert link"))))) + (cl-case (car choice) + (?c 'copy-and-insert) + (?o 'open) + (?i 'insert) + (otherwise (markdown--dnd-read-method))))) + +(defun markdown--dnd-insert-path (filename) + (let ((mimetype (mailcap-file-name-to-mime-type filename)) + (link-text "link text")) + (when (string-match-p "\\s-" filename) + (setq filename (concat "<" filename ">"))) + (if (string-prefix-p "image/" mimetype) + (markdown-insert-inline-image link-text filename) + (markdown-insert-inline-link link-text filename)))) + +(defun markdown--dnd-local-file-handler (url action) (require 'mailcap) (require 'dnd) (let* ((filename (dnd-get-local-file-name url)) - (mimetype (mailcap-file-name-to-mime-type filename)) - (file (file-relative-name filename)) - (link-text "link text")) - (when (string-match-p "\\s-" file) - (setq file (concat "<" file ">"))) - (if (string-prefix-p "image/" mimetype) - (markdown-insert-inline-image link-text file) - (markdown-insert-inline-link link-text file)))) + (method (if (eq markdown-yank-dnd-method 'ask) + (markdown--dnd-read-method) + markdown-yank-dnd-method))) + (cl-case method + (copy-and-insert + (let ((copied (expand-file-name (file-name-nondirectory filename)))) + (copy-file filename copied) + (markdown--dnd-insert-path (file-relative-name copied)))) + (open + (dnd-open-local-file url action)) + (insert (markdown--dnd-insert-path (file-relative-name filename)))))) + +(defun markdown--dnd-multi-local-file-handler (urls action) + (let ((multile-urls-p (> (length urls) 1))) + (dolist (url urls) + (markdown--dnd-local-file-handler url action) + (when multile-urls-p + (insert " "))))) + +(put 'markdown--dnd-multi-local-file-handler 'dnd-multiple-handler t) ;;; Mode Definition ========================================================== @@ -10188,10 +10231,10 @@ rows and columns and the column alignment." ;; Add a buffer-local hook to reload after file-local variables are read (add-hook 'hack-local-variables-hook #'markdown-handle-local-variables nil t) ;; For imenu support - (setq imenu-create-index-function - (if markdown-nested-imenu-heading-index - #'markdown-imenu-create-nested-index - #'markdown-imenu-create-flat-index)) + (setq-local imenu-create-index-function (if markdown-nested-imenu-heading-index + #'markdown-imenu-create-nested-index + #'markdown-imenu-create-flat-index) + imenu-submenus-on-top nil) ;; Defun movement (setq-local beginning-of-defun-function #'markdown-beginning-of-defun) @@ -10261,8 +10304,14 @@ rows and columns and the column alignment." #'markdown--inhibit-electric-quote nil :local) ;; drag and drop handler - (setq-local dnd-protocol-alist (cons '("^file:///" . markdown--dnd-local-file-handler) - dnd-protocol-alist)) + (let ((dnd-handler (if (>= emacs-major-version 30) + #'markdown--dnd-multi-local-file-handler + #'markdown--dnd-local-file-handler))) + (setq-local dnd-protocol-alist (append + (list (cons "^file:///" dnd-handler) + (cons "^file:/[^/]" dnd-handler) + (cons "^file:[^/]" dnd-handler)) + dnd-protocol-alist))) ;; media handler (when (version< "29" emacs-version) diff --git a/lisp/ol-notmuch/ol-notmuch-pkg.el b/lisp/ol-notmuch/ol-notmuch-pkg.el index 8884c22f..991dec39 100644 --- a/lisp/ol-notmuch/ol-notmuch-pkg.el +++ b/lisp/ol-notmuch/ol-notmuch-pkg.el @@ -1,17 +1,17 @@ -(define-package "ol-notmuch" "20230511.2048" "Links to notmuch messages" - '((emacs "25.1") - (compat "29.1.4.1") - (notmuch "0.37") - (org "9.6.5")) - :commit "781c3518a537da2a8b5e8a4424f9441df463a147" :authors +(define-package "ol-notmuch" "20250117.1242" "Links to notmuch messages" + '((emacs "29.1") + (compat "30.0.2.0") + (notmuch "0.38.2") + (org "9.7.19")) + :commit "9a69506a3f9ed31e2f1f967dfaa600702089be45" :authors '(("Matthieu Lemerre" . "racin@free.fr")) :maintainers - '(("Jonas Bernoulli" . "jonas@bernoul.li")) + '(("Jonas Bernoulli" . "emacs.ol-notmuch@jonas.bernoulli.dev")) :maintainer - '("Jonas Bernoulli" . "jonas@bernoul.li") + '("Jonas Bernoulli" . "emacs.ol-notmuch@jonas.bernoulli.dev") :keywords '("hypermedia" "mail") - :url "https://git.sr.ht/~tarsius/ol-notmuch") + :url "https://github.com/tarsius/ol-notmuch") ;; Local Variables: ;; no-byte-compile: t ;; End: diff --git a/lisp/ol-notmuch/ol-notmuch.el b/lisp/ol-notmuch/ol-notmuch.el index c7ae254f..77563944 100644 --- a/lisp/ol-notmuch/ol-notmuch.el +++ b/lisp/ol-notmuch/ol-notmuch.el @@ -2,18 +2,19 @@ ;; Copyright (C) 2010-2011 Matthieu Lemerre ;; Copyright (C) 2010-2021 The Org Contributors -;; Copyright (C) 2021-2023 Jonas Bernoulli +;; Copyright (C) 2021-2025 Jonas Bernoulli ;; Author: Matthieu Lemerre -;; Maintainer: Jonas Bernoulli -;; Homepage: https://git.sr.ht/~tarsius/ol-notmuch +;; Maintainer: Jonas Bernoulli +;; Homepage: https://github.com/tarsius/ol-notmuch ;; Keywords: hypermedia mail +;; Package-Version: 2.1.0 ;; Package-Requires: ( -;; (emacs "25.1") -;; (compat "29.1.4.1") -;; (notmuch "0.37") -;; (org "9.6.5")) +;; (emacs "29.1") +;; (compat "30.0.2.0") +;; (notmuch "0.38.2") +;; (org "9.7.19")) ;; SPDX-License-Identifier: GPL-3.0-or-later @@ -37,12 +38,12 @@ ;; to folders in other mail clients. Similarly, mails are referred to ;; by a query, so both a link can refer to several mails. -;; Links have one the following forms +;; Links have one of the following forms: ;; - notmuch: ;; - notmuch-search:. -;; The first form open the queries in `notmuch-show-mode', whereas the -;; second link open it in `notmuch-search-mode'. Note that queries are +;; The first form opens the queries in `notmuch-show-mode', whereas the +;; second link opens it in `notmuch-search-mode'. Note that queries are ;; performed at the time the link is opened, and the result may be ;; different from when the link was stored. diff --git a/lisp/org-appear/org-appear-pkg.el b/lisp/org-appear/org-appear-pkg.el index c9dcd38c..1f9ef0b5 100644 --- a/lisp/org-appear/org-appear-pkg.el +++ b/lisp/org-appear/org-appear-pkg.el @@ -1,7 +1,7 @@ -(define-package "org-appear" "20220617.2355" "Auto-toggle Org elements" - '((emacs "25.1") +(define-package "org-appear" "20240716.1413" "Auto-toggle Org elements" + '((emacs "29.1") (org "9.3")) - :commit "60ba267c5da336e75e603f8c7ab3f44e6f4e4dac" :authors + :commit "32ee50f8fdfa449bbc235617549c1bccb503cb09" :authors '(("Alice Istleyeva" . "awth13@gmail.com")) :maintainers '(("Alice Istleyeva" . "awth13@gmail.com")) diff --git a/lisp/org-appear/org-appear.el b/lisp/org-appear/org-appear.el index 236a6d73..ad0d2340 100644 --- a/lisp/org-appear/org-appear.el +++ b/lisp/org-appear/org-appear.el @@ -4,10 +4,10 @@ ;; org-fragtog Copyright (C) 2020 Benjamin Levy - MIT/X11 License ;; org-appear Copyright (C) 2021 Alice Istleyeva - MIT License ;; Author: Alice Istleyeva -;; Version: 0.3.0 +;; Version: 0.3.1 ;; Description: Toggle Org mode element visibility upon entering and leaving ;; Homepage: https://github.com/awth13/org-appear -;; Package-Requires: ((emacs "25.1") (org "9.3")) +;; Package-Requires: ((emacs "29.1") (org "9.3")) ;; Permission is hereby granted, free of charge, to any person obtaining a copy ;; of this software and associated documentation files (the "Software"), to deal @@ -272,8 +272,8 @@ Return nil if element is not supported by `org-appear-mode'." (link-ignore-p (and (eq elem-type 'link) (or (string-match-p "[Cc]ite" (org-element-property :type elem)) - (eq 'plain - (org-element-property :format elem))))) + (memq (org-element-property :format elem) + '(plain angle))))) (key-ignore-p (and (eq elem-type 'keyword) (not (memq (intern (downcase (org-element-property :key elem))) @@ -358,7 +358,8 @@ Return nil if element cannot be parsed." ((eq elem-type 'keyword) (remove-text-properties start end '(invisible org-link))) ((and (featurep 'org-fold) - (eq elem-type 'link)) + (eq elem-type 'link) + (eq org-fold-core-style 'text-properties)) (remove-text-properties start visible-start (list (org-fold-core--property-symbol-get-create 'org-link) nil)) @@ -405,7 +406,8 @@ When RENEW is non-nil, obtain element at point instead." ((memq elem-type '(keyword latex-fragment latex-environment)) (font-lock-flush start end)) ((and (featurep 'org-fold) - (eq elem-type 'link)) + (eq elem-type 'link) + (eq org-fold-core-style 'text-properties)) (put-text-property start visible-start (org-fold-core--property-symbol-get-create 'org-link) diff --git a/lisp/org-ref/contrib.el b/lisp/org-ref/contrib.el index 4e811deb..f726f755 100644 --- a/lisp/org-ref/contrib.el +++ b/lisp/org-ref/contrib.el @@ -1,9 +1,16 @@ -;;; contrib.el --- Code contributed by users +;;; contrib.el --- Code contributed by users -*- lexical-binding: t; -*- ;;; Commentary: ;; ;;; Code: +(defvar org-ref-cite-types) +(declare-function org-element-context "org-element") +(declare-function org-element-type "org-element") +(declare-function org-element-property "org-element") +(declare-function bibtex-completion-apa-format-reference "bibtex-completion") +(declare-function org-ref-parse-cite-path "org-ref-citation-links") + ;; * Add messages in minibuffer ;; Contributed in https://github.com/jkitchin/org-ref/issues/938 by @DiogoFerrari @@ -17,7 +24,7 @@ If not on a key, but on a cite, prompt for key." key ;; point is not on a key, but may still be on a cite link (let ((el (org-element-context)) - data + data text keys) (cond ;; on a cite-link type @@ -33,7 +40,7 @@ If not on a key, but on a cite, prompt for key." (dolist (key keys) (search-forward key) (goto-char (match-beginning 0)) - (get-text-property (point) 'cite-key) + ;; (get-text-property (point) 'cite-key) ;; (message (bibtex-completion-apa-format-reference key)) (setq text (concat text "\n" (bibtex-completion-apa-format-reference key)))))))) (message (string-trim-left text))) @@ -45,7 +52,8 @@ If not on a key, but on a cite, prompt for key." (defcustom org-ref-message-interval 0.5 "Time in seconds to wait for the idle timer that displays the cite message." - :group 'org-ref) + :group 'org-ref + :type 'float) (defun org-ref-link-message () diff --git a/lisp/org-ref/doi-utils.el b/lisp/org-ref/doi-utils.el index 34965514..9775fe6c 100644 --- a/lisp/org-ref/doi-utils.el +++ b/lisp/org-ref/doi-utils.el @@ -43,6 +43,10 @@ (declare-function org-bibtex-yank "org-bibtex") (declare-function org-ref-possible-bibfiles "org-ref-core") +(declare-function f-ext? "f") +(declare-function f-entries "f") +(declare-function s-match "s") + (eval-when-compile (require 'cl-lib)) (require 'bibtex) @@ -1006,7 +1010,9 @@ Opening %s" json-data url)) (url (plist-get results :URL)) (booktitle (plist-get results :container-title)) (school (or (plist-get results :school) - (plist-get (plist-get results :institution) :name))))) + (plist-get (plist-get results :institution) :name))) + ;; I am not sure how general this is. This gets the first name. + (institution (plist-get (car (plist-get results :institution)) :name)))) ;; Next, we need to define the different bibtex types. Each type has a bibtex ;; type (for output) and the type as provided in the doi record. Finally, we @@ -1066,13 +1072,17 @@ MATCHING-TYPES." (doi-utils-def-bibtex-type inproceedings ("proceedings-article" "paper-conference") author title booktitle year month pages doi url) -(doi-utils-def-bibtex-type book ("book") +(doi-utils-def-bibtex-type book ("book" "edited-book") author title series publisher year pages doi url) (doi-utils-def-bibtex-type inbook ("chapter" "book-chapter" "reference-entry") author title booktitle series publisher year pages doi url) + (doi-utils-def-bibtex-type phdthesis ("phdthesis" "thesis" "dissertation") - author title school publisher year) + author title school publisher year) + +(doi-utils-def-bibtex-type techreport ("report") + institution author title publisher year doi url) ;; this is what preprints in chemrxiv look like for now (doi-utils-def-bibtex-type misc ("posted-content") diff --git a/lisp/org-ref/nist-webbook.el b/lisp/org-ref/nist-webbook.el index 57764dd1..35b16088 100644 --- a/lisp/org-ref/nist-webbook.el +++ b/lisp/org-ref/nist-webbook.el @@ -1,4 +1,4 @@ -;;; nist-webbook.el --- Integration of Emacs with NIST Webbook +;;; nist-webbook.el --- Integration of Emacs with NIST Webbook -*- lexical-binding: t; -*- ;; Integration of Emacs with NIST webbook ;;; Commentary: diff --git a/lisp/org-ref/openalex.el b/lisp/org-ref/openalex.el index 256e58c8..78bcd796 100644 --- a/lisp/org-ref/openalex.el +++ b/lisp/org-ref/openalex.el @@ -1,16 +1,51 @@ -;;; openalex.el --- Org-ref interface to OpenAlex +;;; openalex.el --- Org-ref interface to OpenAlex ;;; Commentary: ;; This is an elisp interface to OpenAlex (https://docs.openalex.org/) for org-ref. ;; -;; This provides functionality for the Work and Author API +;; This provides functionality for the OpenAlex APIs. ;; -;; See -;; https://docs.openalex.org/how-to-use-the-api/rate-limits-and-authentication#the-polite-pool -;; for why we add email to the request. +;; `oa-query' provides a general interface to all the endpoints with a filter. +;; It is not interactive though. +;; +;; `oa-author' provides an interactive way to search for an author and then see +;; a Google Scholar like org buffer with information about the author. +;; +;; `oa-fulltext-search' provides an interactive full text search of Works in +;; OpenAlex. You get an org-buffer of results, with links to subsequent pages of +;; results. +;; +;; `oa-coa' is an interactive command to generate the NSF COA form data for +;; coauthors. +;; +;; `oa-get-bibtex-entries' is an interactive command to download all bibtex +;; entries from headings in the current buffer with a DOI property. +;; +;; if you have an OpenAlex API you can set `oa-api-key' to use it. The +;; `user-mail-address' value will be added to the queries if it exists so you +;; will get the polite pool. +;; +;; This library extends the `org-ref-citation-hydra' and adds keys to get to +;; cited by, references and related documents in OpenAlex. (require 'dash) +(require 's) (require 'request) +(require 'doi-utils) +(require 'org-ref-citation-links) + +(declare-function org-ref-possible-bibfiles "org-ref-core") +(declare-function org-ref-find-bibliography "org-ref-core") +(declare-function org-ref-get-bibtex-key-and-file "org-ref-core") +(declare-function bibtex-completion-show-entry "bibtex-completion") +(declare-function bibtex-completion-apa-format-reference "bibtex-completion") +(declare-function ivy-read "ivy") + +(defcustom oa-api-key + nil + "Your API key if you have one." + :group 'openalex + :type 'string) ;;; Code: @@ -24,6 +59,207 @@ (json-read))) +(defun oa-get (data query &optional iterable) + "Get fields from DATA with QUERY. +QUERY is a dot notation string. +key1.key2.key3 represents a nested item. +key1.key2[].key3 represents key3 on all items in key1.key2. + +Tested with up to two [] in the query. + +Assumes data is in plist form." + (let* ((fields (and query (split-string query "\\."))) + (current-field (and fields (pop fields)))) + + (cond + ;; return condition + ((null query) + data) + + ;; query[] means get query then turn iteration on + ((and (s-ends-with-p "[]" current-field) (null iterable)) + (setq current-field (substring current-field 0 -2)) + (oa-get (plist-get data (intern-soft (concat ":" current-field))) + (when fields + (string-join fields ".")) + t)) + + ;; this means another level of iteration. You already have a collection. we + ;; have to iterate over each one I think. + ((and (s-ends-with-p "[]" current-field) iterable) + (setq current-field (substring current-field 0 -2)) + (cl-loop for item in data collect + (oa-get (plist-get item (intern-soft (concat ":" current-field))) + (when fields + (string-join fields ".")) + t))) + + ;; single keyword, iterate over collection + (iterable + (oa-get (cl-loop for item in data collect + (plist-get item (intern-soft (concat ":" current-field)))) + (when fields + (string-join fields ".")) + t)) + + ;; single keyword + (t + (oa-get (plist-get data (intern-soft (concat ":" current-field))) + (when fields + (string-join fields "."))))))) + + +;; * General query +(defun oa--query-all-data (endpoint &rest filter) + (let* ((page 1) + (url (concat "https://api.openalex.org/" endpoint)) + (filter-string (string-join (cl-loop for key in (plist-get-keys filter) collect + (concat (substring (symbol-name key) 1) + ":" + (url-hexify-string + (plist-get filter key)))) + ",")) + (params `(("mailto" . ,user-mail-address) + ("api_key" . ,oa-api-key) + ("filter" . ,filter-string) + ("page" . ,page))) + + (req (request url :sync t :parser 'oa--response-parser :params params)) + (data (request-response-data req)) + (meta (plist-get data :meta)) + (count (plist-get meta :count)) + (per-page (plist-get meta :per_page)) + (pages (ceiling (/ (float count) per-page))) + (results (plist-get data :results))) + (cl-loop for i from 2 to pages do + (setf (cdr (assoc "page" params)) i) + (setq req (request purl :sync t :parser 'oa--response-parser :params params) + data (request-response-data req) + results (append results (plist-get data :results)))) + results)) + + +(defun oa-query (endpoint &rest filter) + "Run a query at ENDPOINT with FILTER. +ENDPOINT can be works, authors, sources, institutions, concepts, +publishers, or funders. + +FILTER is a plist (:field value) where :field is a valid filter +field (see +https://docs.openalex.org/how-to-use-the-api/get-lists-of-entities/filter-entity-lists), +and value is what you want to filter on. The following logic is supported: + +!value is negation +value is greater than +value1+value2 is and within a field +value1|value2 is or within a field + +Your email address will be added if `user-mail-address' is +non-nil, and `oa-api-key' if it is non-nil to the API url." + (let* ((page (if (plist-get filter :page) + (prog1 + (string-to-number (plist-get filter :page)) + (setq filter (org-plist-delete filter :page))) + 1)) + (base-url "https://api.openalex.org") + (url (concat base-url "/" endpoint "?filter=")) + (filter-string (string-join + (cl-loop for key in (plist-get-keys filter) collect + (concat (substring (symbol-name key) 1) + ":" + (url-hexify-string + (plist-get filter key)))) + ",")) + + (req (request url :sync t :parser 'oa--response-parser + :params `(("mailto" . ,user-mail-address) + ("api_key" . ,oa-api-key) + ("filter" . ,filter-string) + ("page" . ,page)))) + (data (request-response-data req)) + (meta (plist-get data :meta)) + (count (plist-get meta :count)) + (per-page (plist-get meta :per_page)) + (pages (ceiling (/ (float count) per-page))) + (results (plist-get data :results)) + (next-page (format "[[elisp:(oa-query \"%s\" %s :page \"%s\")][Next page: %s]]" + endpoint + (string-join (cl-loop for x in filter + collect + (if (keywordp x) + (format "%s" x) + (format "%S" x))) + " ") + (+ page 1) + (+ page 1))) + (buf (generate-new-buffer "*OpenAlex - Query*"))) + + (with-current-buffer buf + (erase-buffer) + (org-mode) + (insert (concat + (format "#+title: %s +** Results +:PROPERTIES: +:FILTER: %s +:COUNT: %s +:END: + +%s +\n\n" + filter-string + filter-string + count + next-page) + (cond + ((string= endpoint "works") + (string-join + (cl-loop for wrk in results collect + (s-format "*** ${title} +:PROPERTIES: +:HOST: ${primary_location.source.display_name} +:YEAR: ${publication_year} +:CITED_BY_COUNT: ${cited_by_count} +:AUTHOR: ${authors} +:DOI: ${doi} +:OPENALEX: ${id} +:CREATED_DATE: ${created_date} +:END: + + +${get-bibtex} + +- ${oa-refs} +- ${oa-related} +- ${oa-cited} + +${abstract} + +" + (lambda (key data) + (or (cdr (assoc key data)) "")) + `(("title" . ,(oa--title wrk)) + ("primary_location.source.display_name" . ,(oa-get wrk "primary_location.source.display_name")) + ("publication_year" . ,(oa-get wrk "publication_year")) + ("cited_by_count" . ,(oa-get wrk "cited_by_count")) + ("authors" . ,(oa--authors wrk)) + ("doi" . ,(oa-get wrk "doi")) + ("id" . ,(oa-get wrk "id")) + ("created_date" . ,(oa-get wrk "created_date")) + ("get-bibtex" . ,(oa--elisp-get-bibtex wrk)) + ("oa-refs" . ,(oa--elisp-get-oa-refs wrk)) + ("oa-related" . ,(oa--elisp-get-oa-related wrk)) + ("oa-cited" . ,(oa--elisp-get-oa-cited-by wrk)) + ("abstract" . ,(oa--abstract wrk))))) + "\n")) + (t + (format "%s" results) + ))))) + (pop-to-buffer buf) + (goto-char (point-min)))) + + ;; * Work object (defun oa--work (entity-id &optional filter) @@ -36,42 +272,62 @@ If FILTER is non-nil it should be a string like \"filter=openalex:\" https://docs.openalex.org/api-entities/works" - (let* ((url (concat "https://api.openalex.org/works" - (if filter - (concat "?" filter entity-id) - (concat "/" entity-id)) - (if user-mail-address - (concat "?mailto=" user-mail-address) - ""))) - (req (request url :sync t :parser 'oa--response-parser)) + (let* ((url (concat "https://api.openalex.org/works" + ;; This is hackier than I prefer, but sometimes entity-id + ;; is nil, or starts with ? for a filter, and I couldn't + ;; see a cleaner way to solve this. this function is used + ;; in a lot of places. + (cond + ((string-prefix-p "?" entity-id) + entity-id) + (t + (format "/%s" entity-id))))) + (req (request url :sync t :parser 'oa--response-parser + :params `(("mailto" . ,user-mail-address) + ("api_key" . ,oa-api-key) + ("filter" . ,filter)))) (data (request-response-data req))) - ;; this is for convenience to inspect data in a browser. + ;; this is for convenience to inspect data in a browser, e.g. you can click + ;; on the url in Emacs and it opens in a browser. (plist-put data :oa-url url) data)) +;; * autocomplete works + +(defun oa--works-candidates (query) + "Retrieve autocomplete works from OpenAlex." + (or + (ivy-more-chars) + (let* ((url "https://api.openalex.org/autocomplete/works") + (req (request url :sync t :parser 'oa--response-parser + :params `(("mailto" . ,user-mail-address) + ("api_key" . ,oa-api-key) + ("q" . ,query)))) + (data (request-response-data req)) + (results (plist-get data :results))) + (cl-loop for work in results collect + (propertize + (format "%s, %s" + (plist-get work :display_name) + (plist-get work :hint)) + 'oaid (plist-get work :id)))))) + + +(defun oa-works () + "Autocomplete works. +This doesn't seem as useful as it could be." + (interactive) + + (ivy-read "Work: " #'oa--works-candidates + :dynamic-collection t + :action + '(1 + ("o" (lambda (candidate) + (browse-url (get-text-property 0 'oaid candidate))) + "Open in browser")))) + ;; * Viewing works -;; -;; This section provides a replacer and helper function to format org-entries -;; from the results returned in OpenAlex. - -(defun oa--replacer (query object) - "Replacer function for `s-format'. -QUERY is a string that is either a sexp for a function to -evaluate or a dot notation path to data in OBJECT. If QUERY is a -sexp, it is read and evaluated. Otherwise, the path is split, and -looked up sequentially in object. - -OBJECT is a plist, usually from a Work request." - (if (s-starts-with? "(" query) - ;; this is a function - (eval (read query)) - ;; just get data - (let ((fields (s-split "\\." query)) - result) - (while fields - (setq object (plist-get object (intern-soft (concat ":" (pop fields)))))) - (or (string-replace "\\n" "" (format "%s" object)) "Not found")))) ;; ** help functions for complex data @@ -84,7 +340,7 @@ OBJECT is a plist, usually from a Work request." The string is a comma-separated list of links to author pages in OpenAlex." (s-join ", " (cl-loop for author in (plist-get wrk :authorships) collect - (format "[[elisp:(oa-author \"%s\")][%s]]" + (format "[[elisp:(oa--author-org \"%s\")][%s]]" (plist-get (plist-get author :author) :id) @@ -93,6 +349,11 @@ The string is a comma-separated list of links to author pages in OpenAlex." :display_name))))) +(defun oa--title (wrk) + "Return a title from WRK with linebreaks removed." + (string-replace "\n" " " (plist-get wrk :title))) + + ;; I want some links if they can be made so the buffer is interactive. It might ;; be nice to integrate M-, navigation. (defun oa--elisp-get-bibtex (wrk) @@ -104,21 +365,21 @@ The string is a comma-separated list of links to author pages in OpenAlex." (defun oa--elisp-get-oa-related (wrk) "Return a elisp link to get related works for WRK." - (format "[[elisp:(progn (xref--push-markers) (oa--related-works \"%s\"))][Get related work (%s)]]" + (format "[[elisp:(progn (xref--push-markers (current-buffer) (point)) (oa--related-works \"%s\"))][Get related work (%s)]]" (plist-get wrk :id) (length (plist-get wrk :related_works)))) (defun oa--elisp-get-oa-refs (wrk) "Return a elisp link to get references for WRK." - (format "[[elisp:(progn (xref--push-markers) (oa--referenced-works \"%s\"))][Get references (%s)]]" + (format "[[elisp:(progn (xref--push-markers (current-buffer) (point)) (oa--referenced-works \"%s\"))][Get references (%s)]]" (plist-get wrk :id) (length (plist-get wrk :referenced_works)))) (defun oa--elisp-get-oa-cited-by (wrk) "Return a elisp link to get works that cite WRK." - (format "[[elisp:(progn (xref--push-markers) (oa--cited-by-works \"%s\"))][Get cited by (%s)]]" + (format "[[elisp:(progn (xref--push-markers (current-buffer) (point)) (oa--cited-by-works \"%s\"))][Get cited by (%s)]]" (plist-get wrk :id) (plist-get wrk :cited_by_count))) @@ -130,23 +391,35 @@ WORKS is a list of results from OpenAlex." collect (s-format "** ${title} :PROPERTIES: -:HOST: ${host_venue.display_name} +:HOST: ${primary_location.source.display_name} :YEAR: ${publication_year} :CITED_BY_COUNT: ${cited_by_count} -:AUTHOR: ${(oa--authors wrk)} +:AUTHOR: ${authors} :DOI: ${doi} :OPENALEX: ${id} :END: -${(oa--elisp-get-bibtex wrk)} +${get-bibtex} -- ${(oa--elisp-get-oa-refs wrk)} -- ${(oa--elisp-get-oa-related wrk)} -- ${(oa--elisp-get-oa-cited-by wrk)} +- ${oa-refs} +- ${oa-related} +- ${oa-cited} " - 'oa--replacer wrk))) + (lambda (key data) + (or (cdr (assoc key data)) "")) + `(("title" . ,(oa-get wrk "title")) + ("primary_location.source.display_name" . ,(oa-get wrk "primary_location.source.display_name")) + ("publication_year" . ,(oa-get wrk "publication_year")) + ("cited_by_count" . ,(oa-get wrk "cited_by_count")) + ("authors" . ,(oa--authors wrk)) + ("doi" . ,(oa-get wrk "doi")) + ("id" . ,(oa-get wrk "id")) + ("get-bibtex" . ,(oa--elisp-get-bibtex wrk)) + ("oa-refs" . ,(oa--elisp-get-oa-refs wrk)) + ("oa-related" . ,(oa--elisp-get-oa-related wrk)) + ("oa-cited" . ,(oa--elisp-get-oa-cited-by wrk)))))) (defun oa--works-buffer (bufname header entries) @@ -176,10 +449,6 @@ elisp:org-columns elisp:org-columns-quit (pop-to-buffer buf))) -;; There is something funny about pages here, maybe 25 results per page? -;; https://docs.openalex.org/how-to-use-the-api/get-lists-of-entities/paging I -;; am not sure how to do pages in this approach, so I am just getting these 25 -;; at a time. (defun oa--related-works (entity-id) "Show the Related works buffer for ENTITY-ID." (let* ((wrk (oa--work entity-id)) @@ -193,8 +462,7 @@ elisp:org-columns elisp:org-columns-quit ;; split is what we process now (setq entries (append entries (oa--works-entries - (oa--work (s-join "|" (nth 0 split)) - "filter=openalex:"))))) + (oa--work (format "?filter=openalex:%s" (s-join "|" (nth 0 split)))))))) (oa--works-buffer "*OpenAlex - Related works*" @@ -204,12 +472,24 @@ elisp:org-columns elisp:org-columns-quit (plist-get wrk :oa-url) (s-format ":PROPERTIES: :TITLE: ${title} -:HOST: ${host_venue.display_name} -:AUTHOR: ${(oa--authors wrk)} +:HOST: ${primary_location.source.display_name} +:AUTHOR: ${authors} :DOI: ${doi} :YEAR: ${publication_year} :OPENALEX: ${id} -:END:" 'oa--replacer wrk)) +:END: + +Found ${nentries} results. +" + (lambda (key data) + (or (cdr (assoc key data)) "")) + `(("title" . ,(oa-get wrk "title")) + ("primary_location.source.display_name" . ,(oa-get wrk "primary_location.source.display_name")) + ("authors" . ,(oa--authors wrk)) + ("doi" . ,(oa-get wrk "doi")) + ("publication_year" . ,(oa-get wrk "publication_year")) + ("id" . ,(oa-get wrk "id")) + ("nentries" . ,(length entries))))) entries))) @@ -225,8 +505,8 @@ elisp:org-columns elisp:org-columns-quit ;; split is what we process now (setq entries (append entries (oa--works-entries - (oa--work (s-join "|" (nth 0 split)) - "filter=openalex:"))))) + (oa--work (format "?filter=openalex:%s" + (s-join "|" (nth 0 split)))))))) (oa--works-buffer "*OpenAlex - References*" (format "* OpenAlex - References from %s ([[%s][json]]) @@ -235,12 +515,24 @@ elisp:org-columns elisp:org-columns-quit (plist-get wrk :oa-url) (s-format ":PROPERTIES: :TITLE: ${title} -:HOST: ${host_venue.display_name} -:AUTHOR: ${(oa--authors wrk)} +:HOST: ${primary_location.source.display_name} +:AUTHOR: ${authors} :DOI: ${doi} :YEAR: ${publication_year} :OPENALEX: ${id} -:END:" 'oa--replacer wrk)) +:END: + +Found ${nentries} results. +" + (lambda (key data) + (or (cdr (assoc key data)) "")) + `(("title" . ,(oa-get wrk "title")) + ("primary_location.source.display_name" . ,(oa-get wrk "primary_location.source.display_name")) + ("authors" . ,(oa--authors wrk)) + ("doi" . ,(oa-get wrk "doi")) + ("publication_year" . ,(oa-get wrk "publication_year")) + ("id" . ,(oa-get wrk "id")) + ("nentries" . ,(length entries))))) entries))) @@ -253,7 +545,9 @@ elisp:org-columns elisp:org-columns-quit (cited-by-works (request-response-data (request url :sync t - :parser 'oa--response-parser))) + :parser 'oa--response-parser + :params `(("mailto" . ,user-mail-address) + ("api_key" . ,oa-api-key))))) (count (plist-get (plist-get cited-by-works :meta) :count)) (per-page (plist-get (plist-get cited-by-works :meta) :per_page)) (entries '()) @@ -262,9 +556,12 @@ elisp:org-columns elisp:org-columns-quit (setq entries (oa--works-entries cited-by-works)) (while (> count (* per-page (- page 1))) (setq cited-by-works (request-response-data - (request (format "%s&page=%s" url page) + (request url :sync t - :parser 'oa--response-parser))) + :parser 'oa--response-parser + :params `(("mailto" . ,user-mail-address) + ("api_key" . ,oa-api-key) + ("page" . ,page))))) (setq entries (append entries (oa--works-entries cited-by-works))) (cl-incf page)) @@ -276,12 +573,25 @@ elisp:org-columns elisp:org-columns-quit url (s-format ":PROPERTIES: :TITLE: ${title} -:HOST: ${host_venue.display_name} -:AUTHOR: ${(oa--authors wrk)} +:HOST: ${primary_location.source.display_name} +:AUTHOR: ${authors} :DOI: ${doi} :YEAR: ${publication_year} :OPENALEX: ${id} -:END:\n\n" 'oa--replacer wrk)) +:END: + +Found ${nentries} results. + +" + (lambda (key data) + (or (cdr (assoc key data)) "")) + `(("title" . ,(oa-get wrk "title")) + ("primary_location.source.display_name" . ,(oa-get wrk "primary_location.source.display_name")) + ("authors" . ,(oa--authors wrk)) + ("doi" . ,(oa-get wrk "doi")) + ("publication_year" . ,(oa-get wrk "publication_year")) + ("id" . ,(oa-get wrk "id")) + ("nentries" . ,(length entries))))) entries))) @@ -299,11 +609,12 @@ With prefix arg ASCENDING, sort in ascending order (old to new)" (org-sort-entries nil ?f (lambda () (string-to-number (or (org-entry-get (point) "YEAR") "0"))) (lambda (y1 y2) - (> y1 y2))))) + (> y1 y2)))) + (org-fold-show-all)) (defun oa-buffer-sort-cited-by-count (&optional ascending) - "Sort orgheadings by cited by count in descending order high to low. + "Sort org headings by cited by count in descending order high to low. With prefix arg ASCENDING sort from low to high." (interactive "P") (if ascending @@ -319,7 +630,8 @@ With prefix arg ASCENDING sort from low to high." (or (org-entry-get (point) "CITED_BY_COUNT") "0"))) - #'>))) + #'>)) + (org-fold-show-all)) ;; * Interactive versions for org-ref citations @@ -327,7 +639,7 @@ With prefix arg ASCENDING sort from low to high." (defun oa-related-works () "Open the side window for Related works on cite at point." (interactive) - (oa--related-works (concat "doi:" (org-ref-get-doi-at-point)))) + (oa--related-works (concat "https://doi.org/" (org-ref-get-doi-at-point)))) (defun oa-referenced-works () @@ -342,40 +654,43 @@ With prefix arg ASCENDING sort from low to high." (oa--cited-by-works (concat "doi:" (org-ref-get-doi-at-point)))) -(defhydra+ org-ref-citation-hydra () ("ar" oa-related-works "Related documents" :column "OpenAlex")) -(defhydra+ org-ref-citation-hydra () ("ac" oa-cited-by-works "Cited by documents" :column "OpenAlex")) -(defhydra+ org-ref-citation-hydra () ("af" oa-referenced-works "References from" :column "OpenAlex")) - - -;; * utilities - -(defun oa-kill-buffers () - "Kill OpenAlex buffers." +(defun oa-open () + "Open the cite at point in OpenAlex." (interactive) - (cl-loop for buf in (buffer-list) - do - (when (s-starts-with? "*OpenAlex" (buffer-name buf)) - (kill-buffer buf)))) + (let* ((url (concat + "https://api.openalex.org/works/https://doi.org/" + (org-ref-get-doi-at-point))) + (req (request url :sync t :parser 'oa--response-parser)) + (data (request-response-data req))) + (browse-url (plist-get data :id)))) + + +(defhydra+ org-ref-citation-hydra () + "Add open from action to `org-ref-citation-hydra'." + ("xa" oa-open "Open in OpenAlex" :column "OpenAlex") + ("xr" oa-related-works "Related documents" :column "OpenAlex") + ("xc" oa-cited-by-works "Cited by documents" :column "OpenAlex") + ("xf" oa-referenced-works "References from" :column "OpenAlex")) + ;; * Author object (defun oa--author (entity-id &optional filter) - "Get an Author object for entity-id" + "Get an Author object for ENTITY-ID. +FILTER is an optional string to add to the URL." (let* ((url (concat "https://api.openalex.org/authors" - (if filter - (concat "?" filter entity-id) - (concat "/" entity-id)) - (if user-mail-address - (concat "?mailto=" user-mail-address) - ""))) - (req (request url :sync t :parser 'oa--response-parser)) + entity-id)) + (req (request url :sync t :parser 'oa--response-parser + :params `(("mailto" . ,user-mail-address) + ("api_key" . ,oa-api-key) + ("filter" . ,filter)))) (data (request-response-data req))) ;; this is for convenience to inspect data in a browser. (plist-put data :oa-url url) data)) -(defun oa-author-entries (works-data url) +(defun oa--author-entries (works-data url) "Get entries from WORKS-DATA." (let* ((meta (plist-get works-data :meta)) (per-page (plist-get meta :per_page)) @@ -389,48 +704,167 @@ With prefix arg ASCENDING sort from low to high." ;; Now we have to loop through the pages (cl-loop for i from 1 to pages do - (setq purl (concat url (format "&page=%s" i)) - works-data (request-response-data - (request purl + (setq works-data (request-response-data + (request url :sync t - :parser 'oa--response-parser)) + :parser 'oa--response-parser + :params `(("mailto" . ,user-mail-address) + ("api_key" . ,oa-api-key) + ("page" . ,i)))) entries (append entries (cl-loop for result in (plist-get works-data :results) collect - (s-format "** ${title} + (s-format "*** ${title} :PROPERTIES: :ID: ${id} :DOI: ${ids.doi} +:PDF: ${primary_location.pdf_url} +:LANDING_PAGE: ${primary_location.landing_page_url} :YEAR: ${publication_year} -:HOST_VENUE: ${host_venue.display_name} -:AUTHORS: ${(oa--authors result)} +:HOST_VENUE: ${primary_location.source.display_name} +:AUTHORS: ${authors} :CITED_BY_COUNT: ${cited_by_count} :END: -${(oa--elisp-get-bibtex result)} +${get-bibtex} -- ${(oa--elisp-get-oa-refs result)} -- ${(oa--elisp-get-oa-related result)} -- ${(oa--elisp-get-oa-cited-by result)} +- ${oa-refs} +- ${oa-related} +- ${oa-cited} - " 'oa--replacer result))))) +${abstract} + + " (lambda (key data) + (or (cdr (assoc key data)) "")) + `(("title" . ,(oa--title result)) + ("id" . ,(oa-get result "id")) + ("ids.doi" . ,(oa-get result "ids.doi")) + ("publication_year" . ,(oa-get result "publication_year")) + ("primary_location.pdf_url" . ,(oa-get result "primary_location.pdf_url")) + ("primary_location.landing_page_url" . ,(oa-get result "primary_location.landing_page_url")) + ("primary_location.source.display_name" . ,(oa-get result "primary_location.source.display_name")) + ("authors" . ,(oa--authors result)) + ("cited_by_count" . ,(oa-get result "cited_by_count")) + ("get-bibtex" . ,(oa--elisp-get-bibtex result)) + ("oa-refs" . ,(oa--elisp-get-oa-refs result)) + ("oa-related" . ,(oa--elisp-get-oa-related result)) + ("oa-cited" . ,(oa--elisp-get-oa-cited-by result)) + ("abstract" . ,(oa--abstract result)))))))) entries)) -(defun oa-author (entity-id) - "View Author for ENTITY-ID in an org-buffer." +(defun oa--abstract (wrk) + "Construct an abstract from a WRK." + (let* ((aii (plist-get wrk :abstract_inverted_index)) + (word_index '()) + sorted) + + (cl-loop for (k v) on aii by 'cddr + do + (cl-loop for index in v + do + (push (list k index) word_index))) + + (setq sorted (sort + word_index + (lambda (a b) + (< + (nth 1 a) + (nth 1 b))))) + + (string-join (mapcar + (lambda (x) + (substring + (symbol-name (car x)) + 1)) + sorted) + " "))) + + +(defun oa--author-candidates (query) + "Retrieve autocomplete authors from OpenAlex." + (or + (ivy-more-chars) + (let* ((url "https://api.openalex.org/autocomplete/authors") + (req (request url :sync t :parser 'oa--response-parser + :params `(("mailto" . ,user-mail-address) + ("api_key" . ,oa-api-key) + ("q" . ,query)))) + (data (request-response-data req)) + (results (plist-get data :results))) + (cl-loop for author in results collect + (propertize + (format "%s - %s" + (plist-get author :display_name) + (plist-get + author :hint)) + 'oaid (plist-get author :id)))))) + + +(defun oa--counts-by-year (data) + "Get citation counts by year and make a graph. +DATA is an author from OpenAlex. +Requires gnuplot. Generates a temporary file." + (if (executable-find "gnuplot") + (let* ((pngfile (make-temp-file "oa-" nil ".png")) + (counts (sort + (cl-loop for i from 1 for item in (plist-get data :counts_by_year) + collect + (list + (plist-get item :year) + (plist-get item :cited_by_count) + (plist-get item :works_count))) + (lambda (a b) + (< (nth 0 a) + (nth 0 b))))) + (count-string (cl-loop for i from 1 for (year cites works) in counts + concat + (format "%s \"%s\" %s %s\n" + i year cites works))) + (gnuplot (format "set terminal \"png\" size 800,400 +set output \"%s\" +$counts << EOD +%s +EOD +set boxwidth 0.5 +set style fill solid noborder +set style line 1 lc rgb \"grey\" +set ylabel \"Citation count\" +set y2label \"Document count\" +set y2tics nomirror +set key left top +plot $counts using 1:3:xtic(2) with boxes lc rgb \"grey\" title \"Citations per year\", \"\" using 1:4 axes x1y2 with lines title \"Document count\" +" + pngfile + count-string)) + (cmdfile (make-temp-file "gnuplot-cmds-" nil ".gpl")) + (shellcmd (format "gnuplot --persist -c \"%s\"" cmdfile))) + (with-temp-file cmdfile + (insert gnuplot)) + (shell-command shellcmd) + (delete-file cmdfile) + (format "[[%s]]" pngfile)) + "Gnuplot required to see citation graph. Please install it.")) + + +(defun oa--author-org (entity-id) + "Generate an org-buffer for an author with ENTITY-ID." (let* ((buf (get-buffer-create "*OpenAlex - Author*")) (data (oa--author entity-id)) + (citations-image (oa--counts-by-year data)) (works-count (plist-get data :works_count)) (works-url (plist-get data :works_api_url)) (works-data (request-response-data (request works-url :sync t - :parser 'oa--response-parser)))) + :parser 'oa--response-parser + :params `(("mailto" . ,user-mail-address) + ("api_key" . ,oa-api-key)))))) (with-current-buffer buf (erase-buffer) (insert (s-format "* ${display_name} ([[${oa-url}][json]]) :PROPERTIES: +:OPENALEX: ${id} :ORCID: ${orcid} :SCOPUS: ${ids.scopus} :WORKS_COUNT: ${works_count} @@ -441,19 +875,305 @@ ${(oa--elisp-get-bibtex result)} #+COLUMNS: %25ITEM %YEAR %CITED_BY_COUNT elisp:org-columns elisp:org-columns-quit +${citations-image} + +** Articles + #+caption: Sort | year | [[elisp:(oa-buffer-sort-year t)][old first]] | [[elisp:(oa-buffer-sort-year)][new first]] | | cited by | [[elisp:(oa-buffer-sort-cited-by-count t)][low first]] | [[elisp:(oa-buffer-sort-cited-by-count)][high first]] | " - 'oa--replacer data)) - (insert (s-join "\n" (oa-author-entries works-data works-url))) + (lambda (key data) + (or (cdr (assoc key data)) "")) + `(("display_name" . ,(oa-get data "display_name")) + ("oa-url" . ,(oa-get data "oa-url")) + ("id" . ,(oa-get data "id")) + ("orcid" . ,(oa-get data "orcid")) + ("ids.scopus" . ,(oa-get data "ids.scopus")) + ("works_count" . ,(oa-get data "works_count")) + ("last_known_institution.display_name" . ,(oa-get data "last_known_institution.display_name")) + ("last_known_institution.country_code" . ,(oa-get data "last_known_institution.country_code")) + ("citations-image" . ,citations-image)))) + (insert (s-join "\n" (oa--author-entries works-data works-url))) + (org-mode) (goto-char (point-min)) (org-next-visible-heading 1)) (pop-to-buffer buf))) +(defun oa-author () + "Get data and act on it for an author." + (interactive) + + (ivy-read "Author: " #'oa--author-candidates + :dynamic-collection t + :action + '(1 + ("o" (lambda (candidate) + (oa--author-org (get-text-property 0 'oaid candidate))) + "Open org file") + ("l" (lambda (candidate) + (insert (format "[[%s][%s]]" + (get-text-property 0 'oaid candidate) + candidate)))) + ("u" (lambda (candidate) + (browse-url (get-text-property 0 'oaid candidate))) + "Open in browser")))) + + +;; * Full text search + + +(defun oa-fulltext-search (query &optional page) + "Perform a fulltext search on QUERY. +PAGE is optional, and loads that page of results. Defaults to 1." + (interactive (list (read-string "Query: ") + nil)) + (when (null page) (setq page 1)) + (let* ((url "https://api.openalex.org/works") + (req (request url + :sync t + :parser #'oa--response-parser + :params `(("mailto" . ,user-mail-address) + ("api_key" . ,oa-api-key) + ("page" . ,page) + ("filter" . ,(format "fulltext.search:%s" query))))) + (data (request-response-data req)) + (metadata (plist-get data :meta)) + (count (plist-get metadata :count)) + (per-page (plist-get metadata :per_page)) + (npages (+ (/ count per-page) (if (= 0 (mod count per-page)) 0 1))) + (results (plist-get data :results)) + (next-page (format "[[elisp:(oa-fulltext-search \"%s\" %s)][Next page: %s of %s]]" + query + (+ page 1) + (+ page 1) + npages)) + (buf (get-buffer-create "*OpenAlex Full-text search*"))) + + (with-current-buffer buf + (erase-buffer) + (org-mode) + (insert (s-format "#+title: Full-text search: ${query} + +[[elisp:(oa-fulltext-search \"${query}\" ${page})]]" + 'aget + `(("query" . ,query) + ("page" . ,page)))) + (insert (s-format + " +${meta.count} results: Page ${meta.page} of ${s1} ${s2} +\n\n" + (lambda (key data) + (or (cdr (assoc key data)) "")) + `(("meta.page" . ,(oa-get data "meta.page")) + ("s1" . ,(format "%s" npages)) + ("s2" . ,(format "%s" next-page))))) + + (insert + (cl-loop for result in results concat + (s-format "* ${title} +:PROPERTIES: +:JOURNAL: ${primary_location.source.display_name} +:AUTHOR: ${authors} +:YEAR: ${publication_year} +:OPENALEX: ${id} +:DOI: ${ids.doi} +:END: + +${get-bibtex} + +- ${oa-refs} +- ${oa-related} +- ${oa-cited} + +" (lambda (key data) + (or (cdr (assoc key data)) "")) + +`(("title" . ,(oa--title result)) + ("primary_location.source.display_name" . ,(oa-get result "primary_location.source.display_name")) + ("authors" . ,(oa--authors result)) + ("publication_year" . ,(oa-get result "publication_year")) + ("id" . ,(oa-get result "id")) + ("ids.doi" . ,(oa-get result "ids.doi")) + ("get-bibtex" . ,(oa--elisp-get-bibtex result)) + ("oa-refs" . ,(oa--elisp-get-oa-refs result)) + ("oa-related" . ,(oa--elisp-get-oa-related result)) + ("oa-cited" . ,(oa--elisp-get-oa-cited-by result)))))) + + (insert next-page) + + (goto-char (point-min))) + (pop-to-buffer buf))) + + +;; * NSF Collaborators and Other Affiliations +(defun oa-coa (entity-id &optional COA-file) + "Get a list of collaborators for the past 5 years in tab-delimited form. +This is for Table 4 in the COA_template at +https://www.nsf.gov/bfa/dias/policy/coa/coa_template.xlsx. + +ENTITY-ID is an identifier that OpenAlex can use. Used +interactively you can query and select an author. + +If COA-FILE is non-nil write results to that file, otherwise save +to the clipboard. You should be able to paste the results +directly into Excel. + +Results are sorted in alphaphabetical order by last name. + +Caveats: OpenAlex provides the name in Firstname Initial Lastname +form. I assume this can be split on spaces, and the last word is +the last name. That is not always correct, so some manual name +fixing may be required. + +The Institutions are not always reliable. I use the most recent +institution if an author is listed multiple times. Sometimes this +is empty, and sometimes an author has multiple institutions +listed. + +There may be duplicates for people who have different names in +OpenAlex, e.g. missing initials, differences in spelling, +abbreviations, including having a period or not. + +Your name will be included, you will need to delete this manually +in the Excel sheet. + +This only gets the coauthors in publications known to OpenAlex. +Recently published papers are probably missing. +" + (interactive (list + (get-text-property 0 'oaid + (ivy-read "Author: " #'oa--author-candidates + :dynamic-collection t)) + (when (y-or-n-p "Save to file?") + (read-file-name "File: ")))) + + (let* ((data (oa--author entity-id)) + (works-url (plist-get data :works_api_url)) + (works-data (request-response-data + (request works-url + :sync t + :parser 'oa--response-parser + :params `(("mailto" . ,user-mail-address) + ("api_key" . ,oa-api-key))))) + (meta (plist-get works-data :meta)) + (count (plist-get meta :count)) + (per-page (plist-get meta :per_page)) + (pages (/ count per-page)) + (results (plist-get works-data :results)) + (current-year (string-to-number (format-time-string "%Y" (current-time)))) + (current-authors '()) + purl) + + ;; Now we need to accumulate the rest of the results from other pages + (when (> (mod count per-page) 0) (cl-incf pages)) + + (cl-loop for i from 2 to pages + do + (setq works-data (request-response-data + (request works-url + :sync t + :parser 'oa--response-parser + :params `(("mailto" . ,user-mail-address) + ("api_key" . ,oa-api-key) + ("page" . ,i)))) + results (append results (plist-get works-data :results)))) + + ;; Now results is a list of your publications. We need to iterate over each + ;; one, and accumulate author information + (cl-loop for result in results do + (let ((year (plist-get result :publication_year))) + (when (> year (- current-year 5)) + (cl-loop for authorship in (plist-get result :authorships) do + (let* ((author (plist-get authorship :author)) + (name (plist-get author :display_name)) + (name-parts (mapcar #'capitalize (split-string name))) + (name-string (concat (car (last name-parts)) ", " + (string-join (butlast name-parts) " "))) + + (institutions (plist-get authorship :institutions)) + (institution (plist-get (car institutions) :display_name))) + ;; name, institution, contact info, last-active + ;; we won't have contact info from openalex. + (push (list name-string institution "" year + (plist-get result :publication_date)) + current-authors)))))) + + (setq current-authors (sort current-authors + (lambda (a b) + "Sort first on name, then on year in descending order" + (if (string= (nth 0 a) (nth 0 b)) + (> (nth 3 a) (nth 3 b)) + (string< (car a) (car b)))))) + + ;; now filter for unique authors + (setq current-authors (cl-loop for group in (seq-group-by (lambda (x) + (car x)) + current-authors) + collect (cadr group))) + + ;; Finally lets fix the year so Excel reads it correctly. I use the publication date + (setq current-authors (cl-loop for row in current-authors + collect + (list "A:" + (nth 0 row) + (nth 1 row) + (nth 2 row) + (nth 4 row)))) + + (if COA-file + (with-temp-file COA-file + (cl-loop for row in current-authors do + (insert (string-join (mapcar (lambda (x) + (format "%s" (or x ""))) + row) + "\t") + "\n"))) + + + (kill-new (mapconcat (lambda (row) + (concat (string-join (mapcar (lambda (x) + (format "%s" (or x ""))) + row) + "\t") + "\n")) + current-authors)) + (message "COA data on the clipboard.")))) + + + +;; * utilities + +(defun oa-kill-buffers () + "Kill OpenAlex buffers." + (interactive) + (cl-loop for buf in (buffer-list) + do + (when (s-starts-with? "*OpenAlex" (buffer-name buf)) + (kill-buffer buf)))) + + +(defun oa-get-bibtex-entries () + "Download all the bibtex entries in the buffer. +Operates on headings with a DOI property." + (interactive) + (let ((bibfile (completing-read "Bibfile: " (org-ref-possible-bibfiles)))) + (org-map-entries + (lambda () + (kill-new (org-entry-get (point) "DOI")) + (doi-utils-add-bibtex-entry-from-doi + (doi-utils-maybe-doi-from-region-or-current-kill) + bibfile)) + "DOI<>\"\""))) + + (provide 'openalex) ;;; openalex.el ends here + +;; Local Variables: +;; byte-compile-warnings: (not docstrings-wide) +;; End: diff --git a/lisp/org-ref/org-ref-arxiv.el b/lisp/org-ref/org-ref-arxiv.el index 31572c55..035e4b1e 100644 --- a/lisp/org-ref/org-ref-arxiv.el +++ b/lisp/org-ref/org-ref-arxiv.el @@ -1,6 +1,6 @@ ;;; org-ref-arxiv.el --- arxiv utilities for org-mode -*- lexical-binding: t; -*- -;; Copyright (C) 2015-2021 John Kitchin +;; Copyright (C) 2015-2024 John Kitchin ;; Author: John Kitchin ;; Keywords: @@ -137,9 +137,9 @@ Returns a formatted BibTeX entry." (org-ref-replace-nonascii) (bibtex-generate-autokey))) (doi (assq 'doi entry))) - (if doi - (doi-utils-doi-to-bibtex-string (nth 2 doi)) - ;; no doi, so we fall back to the simple template + (unless (and doi + (ignore-errors (doi-utils-doi-to-bibtex-string (nth 2 doi)))) + ;; no doi or inactive doi, so we fall back to the simple template (format arxiv-entry-format-string key title names year arxiv-number category abstract url))))) @@ -223,15 +223,7 @@ Returns a formatted BibTeX entry." (arxiv-maybe-arxiv-id-from-current-kill)) (read-string "PDF: "))) - (let ((pdf-url (with-current-buffer - (url-retrieve-synchronously - (concat - "http://arxiv.org/abs/" arxiv-number)) - ;; - (goto-char (point-min)) - (search-forward-regexp - "name=\\\"citation_pdf_url\\\" content=\\\"\\(.*\\)\\\"") - (match-string 1)))) + (let ((pdf-url (format "https://arxiv.org/pdf/%s" arxiv-number))) (url-copy-file pdf-url pdf) ;; now check if we got a pdf (unless (org-ref-pdf-p pdf) @@ -296,8 +288,13 @@ key." (when (file-exists-p (concat pdfdir key ".pdf")) (bibtex-end-of-entry) (backward-char) - (insert (format " file = {%s}\n " (concat pdfdir key ".pdf"))))))) + (insert (format " file = {%s}\n " (concat pdfdir key ".pdf"))))) + (save-buffer))) (provide 'org-ref-arxiv) ;;; org-ref-arxiv.el ends here + +;; Local Variables: +;; byte-compile-warnings: (not docstrings) +;; End: diff --git a/lisp/org-ref/org-ref-bibliography-links.el b/lisp/org-ref/org-ref-bibliography-links.el index 332ec56a..6deb0b1b 100644 --- a/lisp/org-ref/org-ref-bibliography-links.el +++ b/lisp/org-ref/org-ref-bibliography-links.el @@ -1,6 +1,6 @@ -;;; org-ref-bibliography-links.el --- Bibliography and bibliographystyle links +;;; org-ref-bibliography-links.el --- Bibliography and bibliographystyle links -*- lexical-binding: t; -*- ;; -;; Copyright (C) 2021 John Kitchin +;; Copyright (C) 2024 John Kitchin ;; Author: John Kitchin ;; Keywords: convenience @@ -310,3 +310,7 @@ Optional argument BACKEND is the export backend." (provide 'org-ref-bibliography-links) ;;; org-ref-bibliography-links.el ends here + +;; Local Variables: +;; byte-compile-warnings: (not docstrings) +;; End: diff --git a/lisp/org-ref/org-ref-bibtex.el b/lisp/org-ref/org-ref-bibtex.el index 8912ab12..74b43d06 100644 --- a/lisp/org-ref/org-ref-bibtex.el +++ b/lisp/org-ref/org-ref-bibtex.el @@ -1,6 +1,6 @@ -;;; org-ref-bibtex.el -- org-ref-bibtex utilities +;;; org-ref-bibtex.el -- org-ref-bibtex utilities -*- lexical-binding: t; -*- -;; Copyright(C) 2014-2021 John Kitchin +;; Copyright(C) 2014-2024 John Kitchin ;; Author: John Kitchin ;; URL: https://github.com/jkitchin/org-ref @@ -67,8 +67,10 @@ (require 's) (require 'doi-utils) (require 'avy) +(require 'sgml-mode) (defvar bibtex-completion-bibliography) +(defvar bibtex-completion-library-path) (declare-function bibtex-completion-show-entry "bibtex-completion") (declare-function org-ref-find-bibliography "org-ref-core") (declare-function org-element-property "org-element") @@ -1171,7 +1173,7 @@ will clobber the file." (format "%s = %s,\n" f v)))) (-uniq other-fields) "\n") "\n}")) - (bibtex-find-entry key) + (bibtex-search-entry key) (bibtex-fill-entry) (bibtex-clean-entry)))) @@ -1201,7 +1203,7 @@ will clobber the file." (cdr (assoc field entry)))) entry-fields "\n") "\n}\n\n")) - (bibtex-find-entry key) + (bibtex-search-entry key) (bibtex-fill-entry) (bibtex-clean-entry))) @@ -1460,3 +1462,7 @@ See functions in `org-ref-clean-bibtex-entry-hook'." (provide 'org-ref-bibtex) ;;; org-ref-bibtex.el ends here + +;; Local Variables: +;; byte-compile-warnings: (not docstrings-wide) +;; End: diff --git a/lisp/org-ref/org-ref-citation-links.el b/lisp/org-ref/org-ref-citation-links.el index 7f039ec5..d030746e 100644 --- a/lisp/org-ref/org-ref-citation-links.el +++ b/lisp/org-ref/org-ref-citation-links.el @@ -1,6 +1,6 @@ ;;; org-ref-citation-links.el --- citation links for org-ref -*- lexical-binding: t; -*- ;; -;; Copyright (C) 2021 John Kitchin +;; Copyright (C) 2024 John Kitchin ;; Author: John Kitchin ;; Keywords: convenience @@ -47,11 +47,15 @@ ;; natmove like preprocessing is provided with `org-ref-cite-natmove'. ;; ;;; Code: - +(require 'org-keys) (require 'hydra) (require 'xref) (eval-when-compile (require 'subr-x)) +(defvar bibtex-completion-cache) +(declare-function bibtex-completion-format-citation-cite "bibtex-completion") +(declare-function bibtex-completion-show-entry "bibtex-completion") + (defgroup org-ref-faces nil "A group for faces in `org-ref'." :group 'org-ref-faces) @@ -592,13 +596,13 @@ PATH has the citations in it." "Get a tooltip for the cite at POSITION." (let ((key (get-text-property position 'cite-key))) (when key - (let ((bibtex-completion-bibliography (org-ref-find-bibliography)) - (has-pdf (when (bibtex-completion-find-pdf key) bibtex-completion-pdf-symbol)) - (has-notes (when (cl-some #'identity - (mapcar (lambda (fn) - (funcall fn key)) - bibtex-completion-find-note-functions)) - bibtex-completion-notes-symbol))) + (let* ((bibtex-completion-bibliography (org-ref-find-bibliography)) + (has-pdf (when (bibtex-completion-find-pdf key) bibtex-completion-pdf-symbol)) + (has-notes (when (cl-some #'identity + (mapcar (lambda (fn) + (funcall fn key)) + bibtex-completion-find-note-functions)) + bibtex-completion-notes-symbol))) (format "%s%s %s" (or has-pdf "") (or has-notes "") (bibtex-completion-apa-format-reference key)))))) @@ -1048,21 +1052,17 @@ If not on a key, but on a cite, prompt for key." (t (let ((el (org-element-context)) - (cp (point)) - (org-ref-activate-cite-links t) ;; temporary - data - keys - ) - (and - (eq (org-element-type el) 'link) - (assoc (org-element-property :type el) org-ref-cite-types)) - (save-excursion - ;; We activate just this one link - (org-ref-cite-activate - (org-element-property :begin el) - (org-element-property :end el) - (org-element-property :path el) - nil)) + (org-ref-activate-cite-links t)) ;; temporary + (when (and + (eq (org-element-type el) 'link) + (assoc (org-element-property :type el) org-ref-cite-types)) + (save-excursion + ;; We activate just this one link + (org-ref-cite-activate + (org-element-property :begin el) + (org-element-property :end el) + (org-element-property :path el) + nil))) ;; Now we have to handle some cases. (cond ;; on a key, return a key @@ -1423,3 +1423,7 @@ Here is an example use: (provide 'org-ref-citation-links) ;;; org-ref-citation-links.el ends here + +;; Local Variables: +;; byte-compile-warnings: (not docstrings docstrings-wide) +;; End: diff --git a/lisp/org-ref/org-ref-compat.el b/lisp/org-ref/org-ref-compat.el index 1e9beaf1..da287aa0 100644 --- a/lisp/org-ref/org-ref-compat.el +++ b/lisp/org-ref/org-ref-compat.el @@ -1,4 +1,4 @@ -;;; org-ref-compat.el --- Compatibility functions for org-cite +;;; org-ref-compat.el --- Compatibility functions for org-cite -*- lexical-binding: t; -*- ;;; Commentary: ;; @@ -35,14 +35,14 @@ There is no way to get them all though, there are conflicting translations with some biblatex and some natbib commands. This list maps the natbib commands. I have also opted to use the full names rather than the short names." - :group 'org-ref) + :group 'org-ref + :type '(list (cons string string))) (defun org-ref-to-org-cite () (interactive) (let ((ref-cites (reverse (org-ref-get-cite-links))) - ref-type - path + type path beg end) ;; This takes care of the cite links (cl-loop for rc in ref-cites do diff --git a/lisp/org-ref/org-ref-core.el b/lisp/org-ref/org-ref-core.el index 1c2d6d8b..c7b34ded 100644 --- a/lisp/org-ref/org-ref-core.el +++ b/lisp/org-ref/org-ref-core.el @@ -1,6 +1,6 @@ ;;; org-ref-core.el --- citations, cross-references and bibliographies in org-mode -*- lexical-binding: t; -*- -;; Copyright(C) 2014-2021 John Kitchin +;; Copyright(C) 2014-2024 John Kitchin ;; This file is not currently part of GNU Emacs. @@ -53,6 +53,7 @@ (require 'org-ref-utils) (require 'org-ref-bibtex) (require 'org-ref-glossary) +(require 'openalex) ;;* Custom variables @@ -337,3 +338,7 @@ provide their own version." (provide 'org-ref-core) ;;; org-ref-core.el ends here + +;; Local Variables: +;; byte-compile-warnings: (not docstrings docstrings-wide) +;; End: diff --git a/lisp/org-ref/org-ref-export.el b/lisp/org-ref/org-ref-export.el index 9902f480..983d47ec 100644 --- a/lisp/org-ref/org-ref-export.el +++ b/lisp/org-ref/org-ref-export.el @@ -1,6 +1,6 @@ ;;; org-ref-export.el --- org-ref-export library -*- lexical-binding: t; -*- ;; -;; Copyright (C) 2021 John Kitchin +;; Copyright (C) 2024 John Kitchin ;; Author: John Kitchin ;; Keywords: convenience @@ -52,6 +52,8 @@ (require 'citeproc) +(defvar org-cite-csl-styles-dir) + (defcustom org-ref-backend-csl-formats '((html . html) (latex . latex) @@ -66,11 +68,14 @@ (defcustom org-ref-cite-internal-links 'auto - "Should be one of -- 'bib-links :: link cites to bibliography entries -- 'no-links :: do not link cites to bibliography entries -- nil or 'auto :: add links based on the style." - :type '(choice bib-links no-links auto nil) + "Should be one of these symbols (quoted) +- bib-links :: link cites to bibliography entries +- no-links :: do not link cites to bibliography entries +- nil or auto :: add links based on the style." + :type '(choice symbol (sexp :tag bib-links) + symbol (sexp :tag no-links) + symbol (sexp :tag auto-links) + symbol (sexp :tag nil)) :group 'org-ref) @@ -212,17 +217,16 @@ REF is a plist data structure returned from `org-ref-parse-cite-path'." (suffix . ,suffix) (locator . ,locator) (label . ,(when label (org-ref-dealias-label (string-trim label)))) - ;; TODO: proof of concept and not complete. I did not go through all the - ;; types to see what else should be in here. - (suppress-author . ,(not (null (member type - '("citenum" - "citeyear" - "citeyear*" - "citedate" - "citedate*" - "citetitle" - "citetitle*" - "citeurl")))))))) + ;; [2024-01-29 Mon] see + ;; https://github.com/jkitchin/org-ref/issues/1103#issuecomment-1915028374 + ;; and related comments at + ;; https://github.com/andras-simonyi/citeproc-el/issues/151. It seems I + ;; should not be adding this. TODO: proof of concept and not complete. I + ;; did not go through all the types to see what else should be in here. + ;; (suppress-author . ,(not (null (member type '("citenum" "citeyear" + ;; "citeyear*" "citedate" "citedate*" "citetitle" "citetitle*" + ;; "citeurl"))))) + ))) (declare-function org-ref-find-bibliography "org-ref-core") @@ -513,9 +517,9 @@ VISIBLE-ONLY BODY-ONLY and INFO." "Export the buffer to PDF via LaTeX and open. See `org-export-as' for the meaning of ASYNC SUBTREEP VISIBLE-ONLY BODY-ONLY and INFO." - (let ((org-export-before-parsing-hook (append - org-export-before-parsing-hook - '(org-ref-csl-preprocess-buffer)))) + (let ((org-export-before-parsing-functions (append + org-export-before-parsing-functions + '(org-ref-csl-preprocess-buffer)))) (org-open-file (org-latex-export-to-pdf async subtreep visible-only body-only info)))) @@ -595,8 +599,8 @@ VISIBLE-ONLY BODY-ONLY and INFO." (?e "to email" org-ref-export-to-message) (?w "to docx" org-ref-export-to-docx)))) -;; An alternative to this exporter is to use an `org-export-before-parsing-hook' -;; (add-hook 'org-export-before-parsing-hook 'org-ref-csl-preprocess-buffer) +;; An alternative to this exporter is to use an `org-export-before-parsing-functions' +;; (add-hook 'org-export-before-parsing-functions 'org-ref-csl-preprocess-buffer) (defun org-ref-csl-preprocess-buffer (backend) "Preprocess the buffer in BACKEND export. @@ -627,27 +631,27 @@ I am not positive on this though." (when (and org-ref/citeproc org-ref/bblproc) (error "You cannot use CSL and BBL at the same time.")) - (let ((org-export-before-parsing-hook org-export-before-parsing-hook)) + (let ((org-export-before-parsing-functions org-export-before-parsing-functions)) (when org-ref/citeproc - (cl-pushnew 'org-ref-csl-preprocess-buffer org-export-before-parsing-hook)) + (cl-pushnew 'org-ref-csl-preprocess-buffer org-export-before-parsing-functions)) (when org-ref/refproc - (cl-pushnew 'org-ref-refproc org-export-before-parsing-hook)) + (cl-pushnew 'org-ref-refproc org-export-before-parsing-functions)) (when org-ref/acrossproc - (cl-pushnew 'org-ref-acrossproc org-export-before-parsing-hook)) + (cl-pushnew 'org-ref-acrossproc org-export-before-parsing-functions)) (when org-ref/idxproc - (cl-pushnew 'org-ref-idxproc org-export-before-parsing-hook)) + (cl-pushnew 'org-ref-idxproc org-export-before-parsing-functions)) (when org-ref/bblproc (unless (featurep 'org-ref-natbib-bbl-citeproc) (require 'org-ref-natbib-bbl-citeproc)) - (cl-pushnew 'org-ref-bbl-preprocess org-export-before-parsing-hook)) + (cl-pushnew 'org-ref-bbl-preprocess org-export-before-parsing-functions)) ;; this goes last since it moves cites before they might get replaced. (when org-ref/natmove - (cl-pushnew 'org-ref-cite-natmove org-export-before-parsing-hook)) + (cl-pushnew 'org-ref-cite-natmove org-export-before-parsing-functions)) (org-export-dispatch arg))) diff --git a/lisp/org-ref/org-ref-glossary.el b/lisp/org-ref/org-ref-glossary.el index fc6ec4a1..aea320a3 100644 --- a/lisp/org-ref/org-ref-glossary.el +++ b/lisp/org-ref/org-ref-glossary.el @@ -1,6 +1,6 @@ ;;; org-ref-glossary.el --- glossary support in org-ref -*- lexical-binding: t; -*- -;; Copyright (C) 2016-2021 John Kitchin +;; Copyright (C) 2016-2024 John Kitchin ;; Author: John Kitchin ;; Keywords: @@ -45,7 +45,7 @@ ;; #+name: acronyms ;; | key | abbreviation | full form | ;; |------+--------------+--------------------------------| -;; | mimo | | multiple-input multiple output | +;; | mimo | mimo | multiple-input multiple output | ;; | qos | QoS | quality-of-service | ;; | bb | BB | branch and bound | ;; @@ -102,7 +102,7 @@ This is not always fast, so we provide a way to disable it." :group 'org-ref-glossary) -(defvar org-ref-glsentries '() +(defcustom org-ref-glsentries '() "Variable to hold locations of glsentries load files.") @@ -152,7 +152,7 @@ changes." ;; We don't have a cache, or an entry in it, so we find it. ;; No cache? we make one (unless org-ref-glossary-cache - (setq-local org-ref-glossary-cache (make-hash-table))) + (setq-local org-ref-glossary-cache (make-hash-table :test 'equal))) ;; Now we search to get the data (save-excursion @@ -171,13 +171,14 @@ changes." external)))) org-ref-glsentries) (cdr (assoc external org-ref-glsentries)))))) - key value p1 p2) + key value p1 p2 position) (setq data (catch 'data ;; look inside first for latex-headers (goto-char (point-min)) (when (re-search-forward (format "\\newglossaryentry{%s}" entry) nil t) + (setq position (match-beginning 0)) (re-search-forward "{") (save-excursion (backward-char) @@ -206,7 +207,8 @@ changes." (setq data (append data (list :label entry) (list (intern (format ":%s" key))) - (list value)))) + (list value) + (list :position position)))) (throw 'data data)) ;; check for a glossary table @@ -218,11 +220,15 @@ changes." (lambda (el) (when (string= "glossary" (org-element-property :name el)) (goto-char (org-element-property :contents-begin el)) + (setq position (point)) (throw 'found (nthcdr 2 (org-babel-read-table))))))))) (result (assoc entry entries))) (when result - (throw 'data (list :label entry :name (cl-second result) :description (cl-third result))))) + (throw 'data (list :label entry + :name (cl-second result) + :description (cl-third result) + :position position)))) ;; then external (when (and glsentries @@ -231,7 +237,7 @@ changes." (with-current-buffer (find-file-noselect glsentries) (goto-char (point-min)) (when (re-search-forward - (format "\\newglossaryentry{%s}" entry) nil t) + (format "\\newglossaryentry{%s}" entry) nil t) (re-search-forward "{") (save-excursion (backward-char) @@ -255,65 +261,57 @@ changes." (setq data (append data (list :label entry) (list (intern (format ":%s" key))) - (list value)))) + (list value) + (list :position nil)))) (throw 'data data)))))) (puthash entry data org-ref-glossary-cache) data)))) -;;;###autoload -(defun org-ref-add-glossary-entry (label name description) - "Insert a new glossary entry. -LABEL is how you refer to it with links. -NAME is the name of the entry to be defined. -DESCRIPTION is the definition of the entry. -Entry gets added after the last #+latex_header line. - -This is not a preferred way to add entries. It is preferred to -manually add them to the glossary table." - (interactive "sLabel: \nsName: \nsDescription: ") - (save-excursion - (goto-char (point-max)) - ;; get to the last latex_header line - (re-search-backward "#\\+latex_header" nil t) - (forward-line) - (when (not (looking-at "^$")) - (beginning-of-line) - (insert "\n") - (forward-line -1)) - (insert (format "#+latex_header_extra: \\newglossaryentry{%s}{name={%s},description={%s}}\n" - label name description)))) - - -(defun org-ref-glossary-face-fn (label) - "Return a face for a glossary link." - (if org-ref-activate-glossary-links - (save-match-data - (cond - ((or-parse-glossary-entry label) - 'org-ref-glossary-face) - (t - 'font-lock-warning-face))) - 'org-ref-glossary-face)) - ;;** Glossary links + +(defun or-activate-glossary (start end path bracketp) + "Activate function for a glossary link. +set data on text with properties +Set face property, and help-echo." + (let ((data (or (or-parse-glossary-entry path) + (or-parse-acronym-entry path)))) + (add-text-properties + start end + (list 'or-glossary data + 'face (if data + 'org-ref-glossary-face + 'font-lock-warning-face))))) + +(defface org-ref-glossary-face + `((t (:inherit org-link :foreground "Mediumpurple3"))) + "Face for glossary links.") + + (defun or-follow-glossary (entry) "Goto beginning of the glossary ENTRY." (org-mark-ring-push) - - (cond - ;; Try finding in the table - ((progn (goto-char (point-min)) - (and (re-search-forward "#\\+name: glossary" nil t) - (re-search-forward entry nil t))) - nil) + (goto-char (plist-get (get-text-property (point) 'or-glossary) :position))) - ((progn (goto-char (point-min)) (re-search-forward (format "\\newglossaryentry{%s}" entry) nil t)) - (goto-char (match-beginning 0))) - (t - (message "no entry found for %s" entry)))) +(defun or-glossary-tooltip (_window buffer position) + "Return tooltip for the glossary entry. +The entry is in WINDOW and OBJECT at POSITION. +Used in fontification." + (with-current-buffer buffer + (let* ((data (get-text-property position 'or-glossary)) + (name (or (plist-get data :name) + (plist-get data :abbrv))) + (description (or (plist-get data :description) + (plist-get data :full)))) + (format + "%s: %s" + name + (with-temp-buffer + (insert (concat description ".")) + (fill-paragraph) + (buffer-string)))))) (defvar org-ref-glossary-gls-commands @@ -330,7 +328,7 @@ manually add them to the glossary table." (dolist (command org-ref-glossary-gls-commands) (org-link-set-parameters (cl-first command) :follow #'or-follow-glossary - :face 'org-ref-glossary-face-fn + :activate-func #'or-activate-glossary :help-echo 'or-glossary-tooltip :export (lambda (path _ format) (cond @@ -342,6 +340,7 @@ manually add them to the glossary table." (org-link-set-parameters "glslink" :follow #'or-follow-glossary + :activate-func #'or-activate-glossary :face 'org-ref-glossary-face-fn :help-echo 'or-glossary-tooltip :export (lambda (path desc format) @@ -351,33 +350,8 @@ manually add them to the glossary table." (t (format "%s" path))))) -;;** Tooltips on glossary entries -(defface org-ref-glossary-face - `((t (:inherit org-link :foreground "Mediumpurple3"))) - "Face for glossary links.") -(defun or-glossary-tooltip (_window _object position) - "Return tooltip for the glossary entry. -The entry is in WINDOW and OBJECT at POSITION. -Used in fontification." - (save-excursion - (goto-char position) - (let* ((label (org-element-property :path (org-element-context))) - (data (or (or-parse-glossary-entry label) - (or-parse-acronym-entry label))) - (name (or (plist-get data :name) - (plist-get data :abbrv))) - (description (or (plist-get data :description) - (plist-get data :full)))) - (format - "%s: %s" - name - (with-temp-buffer - (insert (concat description ".")) - (fill-paragraph) - (buffer-string)))))) - ;; ** printglossaries links ;; There is a printglossary command in LaTeX, but I am not supporting it for now. @@ -440,26 +414,6 @@ This is intended to be run in `org-export-before-parsing-hook'." ;;* Acronyms -;;;###autoload -(defun org-ref-add-acronym-entry (label abbrv full) - "Add an acronym entry with LABEL. - ABBRV is the abbreviated form. - FULL is the expanded acronym. - -This is not the preferred way to add acronyms, you should add -them manually to the acronyms table." - (interactive "sLabel: \nsAcronym: \nsFull name: ") - (save-excursion - (re-search-backward "#\\+latex_header" nil t) - (forward-line) - (when (not (looking-at "^$")) - (beginning-of-line) - (insert "\n") - (forward-line -1)) - (insert (format "#+latex_header_extra: \\newacronym{%s}{%s}{%s}\n" - label abbrv full)))) - - (defun or-parse-acronym-entry (label) "Parse an acronym entry LABEL to a plist. Returns (:abbrv abbrv :full full :label label) @@ -470,7 +424,7 @@ The plist maps to \newacronym{