update packages
This commit is contained in:
@@ -83,6 +83,7 @@ Contributors
|
||||
- Bob Uhl <buhl@zvelo.com>
|
||||
- Bradley Wright <brad@intranation.com>
|
||||
- Brandon W Maister <quodlibetor@gmail.com>
|
||||
- Brian Leung <leungbk@mailfence.com>
|
||||
- Brian Warner <warner@lothar.com>
|
||||
- Bryan Shell <bryan.shell@orbitz.com>
|
||||
- Buster Copley <buster@buster.me.uk>
|
||||
@@ -103,6 +104,7 @@ Contributors
|
||||
- Craig Andera <candera@wangdera.com>
|
||||
- Dale Hagglund <dale.hagglund@gmail.com>
|
||||
- Damien Cassou <damien@cassou.me>
|
||||
- Dan Davison <dandavison7@gmail.com>
|
||||
- Dan Erikson <derikson3@gmail.com>
|
||||
- Daniel Brockman <daniel@gointeractive.se>
|
||||
- Daniel Farina <drfarina@acm.org>
|
||||
@@ -128,6 +130,7 @@ Contributors
|
||||
- Duianto Vebotci <vebotci@openmailbox.org>
|
||||
- Eli Barzilay <eli@barzilay.org>
|
||||
- Eric Davis <ed@npri.org>
|
||||
- Eric <e.a.gebhart@gmail.com>
|
||||
- Eric Prud'hommeaux <eric@w3.org>
|
||||
- Eric Schulte <schulte.eric@gmail.com>
|
||||
- Erik Anderson <erikbpanderson@gmail.com>
|
||||
@@ -147,12 +150,14 @@ Contributors
|
||||
- Graham Dobbins <gdobbins@protonmail.com>
|
||||
- Greg A. Woods <woods@planix.com>
|
||||
- Greg Lucas <greg@glucas.net>
|
||||
- Gregory Heytings <ghe@sdf.org>
|
||||
- Greg Sexton <gregsexton@gmail.com>
|
||||
- Guillaume Martres <smarter@ubuntu.com>
|
||||
- Hannu Koivisto <azure@iki.fi>
|
||||
- Hans-Peter Deifel <hpdeifel@gmx.de>
|
||||
- Hussein Ait-Lahcen <hussein.ait-lahcen@fretlink.com>
|
||||
- Ian Eure <ian.eure@gmail.com>
|
||||
- Ian Milligan <ianmllgn@gmail.com>
|
||||
- Ingo Lohmar <i.lohmar@gmail.com>
|
||||
- Ioan-Adrian Ratiu <adi@adirat.com>
|
||||
- Ivan Brennan <ivan.brennan@gmail.com>
|
||||
@@ -165,12 +170,14 @@ Contributors
|
||||
- Jim Blandy <jimb@red-bean.com>
|
||||
- Joakim Jalap <JOJA@stoneridge.com>
|
||||
- Johannes Altmanninger <aclopte@gmail.com>
|
||||
- Johann Klähn <kljohann@gmail.com>
|
||||
- Johann Klähn <johann@jklaehn.de>
|
||||
- John Mastro <john.b.mastro@gmail.com>
|
||||
- John Morris <john@zultron.com>
|
||||
- John Wiegley <johnw@newartisans.com>
|
||||
- Jonas Bernoulli <jonas@bernoul.li>
|
||||
- Jonas Galvão Xavier <jonas.agx@gmail.com>
|
||||
- Jonathan Arnett <jonathan@scriptdrop.co>
|
||||
- Jonathan del Strother <me@delstrother.com>
|
||||
- Jonathan Leech-Pepin <jonathan.leechpepin@gmail.com>
|
||||
- Jonathan Roes <jroes@jroes.net>
|
||||
- Jon Vanderwijk <jonathn@github.com>
|
||||
@@ -198,6 +205,7 @@ Contributors
|
||||
- Lele Gaifax <lele@metapensiero.it>
|
||||
- Leo Liu <sdl.web@gmail.com>
|
||||
- Leonardo Etcheverry <leo@kalio.net>
|
||||
- Leo Vivier <leo.vivier+dev@gmail.com>
|
||||
- Lingchao Xin <douglarek@users.noreply.github.com>
|
||||
- Li-Yun Chang <michael142536@gmail.com>
|
||||
- Lluís Vilanova <vilanova@ac.upc.edu>
|
||||
@@ -221,8 +229,10 @@ Contributors
|
||||
- Mark Karpov <markkarpov@opmbx.org>
|
||||
- Mark Oteiza <mvoteiza@udel.edu>
|
||||
- Matthew Fluet <matthew.fluet@gmail.com>
|
||||
- Matthew Kraai <kraai@ftbfs.org>
|
||||
- Matthieu Hauglustaine <matt.hauglustaine@gmail.com>
|
||||
- Matus Goljer <dota.keys@gmail.com>
|
||||
- Maxim Cournoyer <maxim.cournoyer@gmail.com>
|
||||
- Michael Fogleman <michaelwfogleman@gmail.com>
|
||||
- Michael Griffiths <mikey@cich.li>
|
||||
- Michael Heerdegen <michael_heerdegen@web.de>
|
||||
@@ -258,6 +268,7 @@ Contributors
|
||||
- Peter J. Weisberg <pj@irregularexpressions.net>
|
||||
- Peter Vasil <mail@petervasil.net>
|
||||
- Philippe Vaucher <philippe.vaucher@gmail.com>
|
||||
- Philipp Fehre <pfehre@twitter.com>
|
||||
- Philipp Haselwarter <philipp@haselwarter.org>
|
||||
- Philipp Stephani <phst@google.com>
|
||||
- Philip Weaver <philip.weaver@gmail.com>
|
||||
@@ -298,6 +309,7 @@ Contributors
|
||||
- Sergey Vinokurov <serg.foo@gmail.com>
|
||||
- Servilio Afre Puentes <afrepues@mcmaster.ca>
|
||||
- Silent Sphere <silentsphere110@gmail.com>
|
||||
- Simon Pintarelli <simon.pintarelli@cscs.ch>
|
||||
- Štěpán Němec <stepnem@gmail.com>
|
||||
- Steven Chow <steve@myfreestuffapp.com>
|
||||
- Steven E. Harris <seh@panix.com>
|
||||
@@ -307,11 +319,12 @@ Contributors
|
||||
- Suhail Shergill <suhailshergill@gmail.com>
|
||||
- Sylvain Rousseau <thisirs@gmail.com>
|
||||
- Syohei Yoshida <syohex@gmail.com>
|
||||
- Szunti <Szunti@users.noreply.github.com>
|
||||
- Takafumi Arakaki <aka.tkf@gmail.com>
|
||||
- Tassilo Horn <tsdh@gnu.org>
|
||||
- Teemu Likonen <tlikonen@iki.fi>
|
||||
- Teruki Shigitani <teruki.shigitani@gmail.com>
|
||||
- Thierry Volpiatto <thierry.volpiatto@gmail.com>
|
||||
- Thierry Volpiatto <thievol@posteo.net>
|
||||
- Thomas A Caswell <tcaswell@gmail.com>
|
||||
- Thomas Fini Hansen <xen@xen.dk>
|
||||
- Thomas Frössman <thomasf@jossystem.se>
|
||||
@@ -330,12 +343,15 @@ Contributors
|
||||
- Vineet Naik <vineet@helpshift.com>
|
||||
- Vitaly Ostashov <hotosho@yandex-team.ru>
|
||||
- Vladimir Panteleev <git@thecybershadow.net>
|
||||
- Vladimir Sedach <vas@oneofus.la>
|
||||
- Wei Huang <weih@opera.com>
|
||||
- Wilfred Hughes <me@wilfred.me.uk>
|
||||
- Win Treese <treese@acm.org>
|
||||
- Wojciech Siewierski <wojciech@siewierski.eu>
|
||||
- Wouter Bolsterlee <wouter@bolsterl.ee>
|
||||
- Xavier Noria <fxn@hashref.com>
|
||||
- Xu Chunyang <mail@xuchunyang.me>
|
||||
- Yann Herklotz <git@yannherklotz.com>
|
||||
- Yann Hodique <yann.hodique@gmail.com>
|
||||
- Ynilu <ynilu.chang@gmail.com>
|
||||
- York Zhao <gtdplatform@gmail.com>
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; git-rebase.el --- Edit Git rebase files -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2010-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2010-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -223,27 +223,32 @@
|
||||
;;; Commands
|
||||
|
||||
(defun git-rebase-pick ()
|
||||
"Use commit on current line."
|
||||
"Use commit on current line.
|
||||
If the region is active, act on all lines touched by the region."
|
||||
(interactive)
|
||||
(git-rebase-set-action "pick"))
|
||||
|
||||
(defun git-rebase-reword ()
|
||||
"Edit message of commit on current line."
|
||||
"Edit message of commit on current line.
|
||||
If the region is active, act on all lines touched by the region."
|
||||
(interactive)
|
||||
(git-rebase-set-action "reword"))
|
||||
|
||||
(defun git-rebase-edit ()
|
||||
"Stop at the commit on the current line."
|
||||
"Stop at the commit on the current line.
|
||||
If the region is active, act on all lines touched by the region."
|
||||
(interactive)
|
||||
(git-rebase-set-action "edit"))
|
||||
|
||||
(defun git-rebase-squash ()
|
||||
"Meld commit on current line into previous commit, edit message."
|
||||
"Meld commit on current line into previous commit, edit message.
|
||||
If the region is active, act on all lines touched by the region."
|
||||
(interactive)
|
||||
(git-rebase-set-action "squash"))
|
||||
|
||||
(defun git-rebase-fixup ()
|
||||
"Meld commit on current line into previous commit, discard its message."
|
||||
"Meld commit on current line into previous commit, discard its message.
|
||||
If the region is active, act on all lines touched by the region."
|
||||
(interactive)
|
||||
(git-rebase-set-action "fixup"))
|
||||
|
||||
@@ -309,11 +314,11 @@ instance with all nil values is returned."
|
||||
(goto-char (line-beginning-position))
|
||||
(if-let ((re-start (concat "^\\(?5:" (regexp-quote comment-start)
|
||||
"\\)? *"))
|
||||
(type (-some (lambda (arg)
|
||||
(let ((case-fold-search nil))
|
||||
(and (looking-at (concat re-start (cdr arg)))
|
||||
(car arg))))
|
||||
git-rebase-line-regexps)))
|
||||
(type (seq-some (lambda (arg)
|
||||
(let ((case-fold-search nil))
|
||||
(and (looking-at (concat re-start (cdr arg)))
|
||||
(car arg))))
|
||||
git-rebase-line-regexps)))
|
||||
(git-rebase-action
|
||||
:action-type type
|
||||
:action (when-let ((action (match-string-no-properties 1)))
|
||||
@@ -327,16 +332,40 @@ instance with all nil values is returned."
|
||||
(git-rebase-action))))
|
||||
|
||||
(defun git-rebase-set-action (action)
|
||||
(goto-char (line-beginning-position))
|
||||
(with-slots (action-type target trailer)
|
||||
(git-rebase-current-line)
|
||||
(if (eq action-type 'commit)
|
||||
(let ((inhibit-read-only t))
|
||||
(magit-delete-line)
|
||||
(insert (concat action " " target " " trailer "\n"))
|
||||
(unless git-rebase-auto-advance
|
||||
(forward-line -1)))
|
||||
(ding))))
|
||||
"Set action of commit line to ACTION.
|
||||
If the region is active, operate on all lines that it touches.
|
||||
Otherwise, operate on the current line. As a special case, an
|
||||
ACTION of nil comments the rebase line, regardless of its action
|
||||
type."
|
||||
(pcase (git-rebase-region-bounds t)
|
||||
(`(,beg ,end)
|
||||
(let ((end-marker (copy-marker end))
|
||||
(pt-below-p (and mark-active (< (mark) (point)))))
|
||||
(set-marker-insertion-type end-marker t)
|
||||
(goto-char beg)
|
||||
(while (< (point) end-marker)
|
||||
(with-slots (action-type target trailer comment-p)
|
||||
(git-rebase-current-line)
|
||||
(cond
|
||||
((and action (eq action-type 'commit))
|
||||
(let ((inhibit-read-only t))
|
||||
(magit-delete-line)
|
||||
(insert (concat action " " target " " trailer "\n"))))
|
||||
((and action-type (not (or action comment-p)))
|
||||
(let ((inhibit-read-only t))
|
||||
(insert comment-start " "))
|
||||
(forward-line))
|
||||
(t
|
||||
;; In the case of --rebase-merges, commit lines may have
|
||||
;; other lines with other action types, empty lines, and
|
||||
;; "Branch" comments interspersed. Move along.
|
||||
(forward-line)))))
|
||||
(goto-char
|
||||
(if git-rebase-auto-advance
|
||||
end-marker
|
||||
(if pt-below-p (1- end-marker) beg)))
|
||||
(goto-char (line-beginning-position))))
|
||||
(_ (ding))))
|
||||
|
||||
(defun git-rebase-line-p (&optional pos)
|
||||
(save-excursion
|
||||
@@ -344,15 +373,24 @@ instance with all nil values is returned."
|
||||
(and (oref (git-rebase-current-line) action-type)
|
||||
t)))
|
||||
|
||||
(defun git-rebase-region-bounds ()
|
||||
(when (use-region-p)
|
||||
(defun git-rebase-region-bounds (&optional fallback)
|
||||
"Return region bounds if both ends touch rebase lines.
|
||||
Each bound is extended to include the entire line touched by the
|
||||
point or mark. If the region isn't active and FALLBACK is
|
||||
non-nil, return the beginning and end of the current rebase line,
|
||||
if any."
|
||||
(cond
|
||||
((use-region-p)
|
||||
(let ((beg (save-excursion (goto-char (region-beginning))
|
||||
(line-beginning-position)))
|
||||
(end (save-excursion (goto-char (region-end))
|
||||
(line-end-position))))
|
||||
(when (and (git-rebase-line-p beg)
|
||||
(git-rebase-line-p end))
|
||||
(list beg (1+ end))))))
|
||||
(list beg (1+ end)))))
|
||||
((and fallback (git-rebase-line-p))
|
||||
(list (line-beginning-position)
|
||||
(1+ (line-end-position))))))
|
||||
|
||||
(defun git-rebase-move-line-down (n)
|
||||
"Move the current commit (or command) N lines down.
|
||||
@@ -423,16 +461,10 @@ current line."
|
||||
(funcall (default-value 'redisplay-unhighlight-region-function) rol))
|
||||
|
||||
(defun git-rebase-kill-line ()
|
||||
"Kill the current action line."
|
||||
"Kill the current action line.
|
||||
If the region is active, act on all lines touched by the region."
|
||||
(interactive)
|
||||
(goto-char (line-beginning-position))
|
||||
(unless (oref (git-rebase-current-line) comment-p)
|
||||
(let ((inhibit-read-only t))
|
||||
(insert comment-start)
|
||||
(insert " "))
|
||||
(goto-char (line-beginning-position))
|
||||
(when git-rebase-auto-advance
|
||||
(forward-line))))
|
||||
(git-rebase-set-action nil))
|
||||
|
||||
(defun git-rebase-insert (rev)
|
||||
"Read an arbitrary commit and insert it below current line."
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-apply.el --- apply Git diffs -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2010-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2010-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -53,6 +53,7 @@
|
||||
(path &optional prefer-short))
|
||||
(declare-function borg--maybe-absorb-gitdir "borg" (pkg))
|
||||
(declare-function borg--sort-submodule-sections "borg" (file))
|
||||
(declare-function borg-assimilate "borg" (package url &optional partially))
|
||||
(defvar borg-user-emacs-directory)
|
||||
|
||||
;;; Options
|
||||
@@ -362,28 +363,24 @@ ignored) files."
|
||||
`((file . ,repo) (untracked) (status)))
|
||||
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 (bound-and-true-p borg-user-emacs-directory)
|
||||
topdir)
|
||||
(file-name-nondirectory (directory-file-name repo)))))
|
||||
(magit-submodule-add-1
|
||||
(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)))
|
||||
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 (y-or-n-p
|
||||
(format "Also build and activate `%s' drone?" package))
|
||||
(fboundp 'borg-build)
|
||||
(fboundp 'borg-activate))
|
||||
(borg-build package)
|
||||
(borg-activate package))))))
|
||||
(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")))
|
||||
|
||||
;;;; Unstage
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-autorevert.el --- revert buffers when files in repository change -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2010-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2010-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-bisect.el --- bisect support for Magit -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2011-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2011-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -58,25 +58,48 @@
|
||||
(transient-define-prefix magit-bisect ()
|
||||
"Narrow in on the commit that introduced a bug."
|
||||
:man-page "git-bisect"
|
||||
["Actions"
|
||||
[:class transient-subgroups
|
||||
:if-not magit-bisect-in-progress-p
|
||||
("B" "Start" magit-bisect-start)
|
||||
("s" "Start script" magit-bisect-run)]
|
||||
["Arguments"
|
||||
("-n" "Don't checkout commits" "--no-checkout")
|
||||
("-p" "Follow only first parent of a merge" "--first-parent"
|
||||
:if (lambda () (version<= "2.29" (magit-git-version))))
|
||||
(6 magit-bisect:--term-old
|
||||
:if (lambda () (version<= "2.7" (magit-git-version))))
|
||||
(6 magit-bisect:--term-new
|
||||
:if (lambda () (version<= "2.7" (magit-git-version))))]
|
||||
["Actions"
|
||||
("B" "Start" magit-bisect-start)
|
||||
("s" "Start script" magit-bisect-run)]]
|
||||
["Actions"
|
||||
:if magit-bisect-in-progress-p
|
||||
("B" "Bad" magit-bisect-bad)
|
||||
("g" "Good" magit-bisect-good)
|
||||
(6 "m" "Mark" magit-bisect-mark
|
||||
:if (lambda () (version<= "2.7" (magit-git-version))))
|
||||
("k" "Skip" magit-bisect-skip)
|
||||
("r" "Reset" magit-bisect-reset)
|
||||
("s" "Run script" magit-bisect-run)])
|
||||
|
||||
(transient-define-argument magit-bisect:--term-old ()
|
||||
:description "Old/good term"
|
||||
:class 'transient-option
|
||||
:key "=o"
|
||||
:argument "--term-old=")
|
||||
|
||||
(transient-define-argument magit-bisect:--term-new ()
|
||||
:description "New/bad term"
|
||||
:class 'transient-option
|
||||
:key "=n"
|
||||
:argument "--term-new=")
|
||||
|
||||
;;;###autoload
|
||||
(defun magit-bisect-start (bad good)
|
||||
(defun magit-bisect-start (bad good args)
|
||||
"Start a bisect session.
|
||||
|
||||
Bisecting a bug means to find the commit that introduced it.
|
||||
This command starts such a bisect session by asking for a know
|
||||
good and a bad commit. To move the session forward use the
|
||||
This command starts such a bisect session by asking for a known
|
||||
good and a known bad commit. To move the session forward use the
|
||||
other actions from the bisect transient command (\
|
||||
\\<magit-status-mode-map>\\[magit-bisect])."
|
||||
(interactive (if (magit-bisect-in-progress-p)
|
||||
@@ -84,15 +107,27 @@ other actions from the bisect transient command (\
|
||||
(magit-bisect-start-read-args)))
|
||||
(unless (magit-rev-ancestor-p good bad)
|
||||
(user-error
|
||||
"The good revision (%s) has to be an ancestor of the bad one (%s)"
|
||||
good bad))
|
||||
"The %s revision (%s) has to be an ancestor of the %s one (%s)"
|
||||
(or (transient-arg-value "--term-old=" args) "good")
|
||||
good
|
||||
(or (transient-arg-value "--term-new=" args) "bad")
|
||||
bad))
|
||||
(when (magit-anything-modified-p)
|
||||
(user-error "Cannot bisect with uncommitted changes"))
|
||||
(magit-git-bisect "start" (list bad good) t))
|
||||
(magit-git-bisect "start" (list args bad good) t))
|
||||
|
||||
(defun magit-bisect-start-read-args ()
|
||||
(let ((b (magit-read-branch-or-commit "Start bisect with bad revision")))
|
||||
(list b (magit-read-other-branch-or-commit "Good revision" b))))
|
||||
(let* ((args (transient-args 'magit-bisect))
|
||||
(bad (magit-read-branch-or-commit
|
||||
(format "Start bisect with %s revision"
|
||||
(or (transient-arg-value "--term-new=" args)
|
||||
"bad")))))
|
||||
(list bad
|
||||
(magit-read-other-branch-or-commit
|
||||
(format "%s revision" (or (transient-arg-value "--term-old=" args)
|
||||
"Good"))
|
||||
bad)
|
||||
args)))
|
||||
|
||||
;;;###autoload
|
||||
(defun magit-bisect-reset ()
|
||||
@@ -108,7 +143,8 @@ other actions from the bisect transient command (\
|
||||
Use this after you have asserted that the commit does not contain
|
||||
the bug in question."
|
||||
(interactive)
|
||||
(magit-git-bisect "good"))
|
||||
(magit-git-bisect (or (cadr (magit-bisect-terms))
|
||||
(user-error "Not bisecting"))))
|
||||
|
||||
;;;###autoload
|
||||
(defun magit-bisect-bad ()
|
||||
@@ -116,7 +152,28 @@ the bug in question."
|
||||
Use this after you have asserted that the commit does contain the
|
||||
bug in question."
|
||||
(interactive)
|
||||
(magit-git-bisect "bad"))
|
||||
(magit-git-bisect (or (car (magit-bisect-terms))
|
||||
(user-error "Not bisecting"))))
|
||||
|
||||
;;;###autoload
|
||||
(defun magit-bisect-mark ()
|
||||
"While bisecting, mark the current commit with a bisect term.
|
||||
During a bisect using alternate terms, commits can still be
|
||||
marked with `magit-bisect-good' and `magit-bisect-bad', as those
|
||||
commands map to the correct term (\"good\" to --term-old's value
|
||||
and \"bad\" to --term-new's). However, in some cases, it can be
|
||||
difficult to keep that mapping straight in your head; this
|
||||
command provides an interface that exposes the underlying terms."
|
||||
(interactive)
|
||||
(magit-git-bisect
|
||||
(pcase-let ((`(,term-new ,term-old) (or (magit-bisect-terms)
|
||||
(user-error "Not bisecting"))))
|
||||
(pcase (read-char-choice
|
||||
(format "Mark HEAD as %s ([n]ew) or %s ([o]ld)"
|
||||
term-new term-old)
|
||||
(list ?n ?o))
|
||||
(?n term-new)
|
||||
(?o term-old)))))
|
||||
|
||||
;;;###autoload
|
||||
(defun magit-bisect-skip ()
|
||||
@@ -127,7 +184,7 @@ to test. This command lets Git choose a different one."
|
||||
(magit-git-bisect "skip"))
|
||||
|
||||
;;;###autoload
|
||||
(defun magit-bisect-run (cmdline &optional bad good)
|
||||
(defun magit-bisect-run (cmdline &optional bad good args)
|
||||
"Bisect automatically by running commands after each step.
|
||||
|
||||
Unlike `git bisect run' this can be used before bisecting has
|
||||
@@ -137,7 +194,7 @@ bisect run'."
|
||||
(magit-bisect-start-read-args))))
|
||||
(cons (read-shell-command "Bisect shell command: ") args)))
|
||||
(when (and bad good)
|
||||
(magit-bisect-start bad good))
|
||||
(magit-bisect-start bad good args))
|
||||
(magit-git-bisect "run" (list shell-file-name shell-command-switch cmdline)))
|
||||
|
||||
(defun magit-git-bisect (subcommand &optional args no-assert)
|
||||
@@ -170,6 +227,9 @@ bisect run'."
|
||||
(defun magit-bisect-in-progress-p ()
|
||||
(file-exists-p (magit-git-dir "BISECT_LOG")))
|
||||
|
||||
(defun magit-bisect-terms ()
|
||||
(magit-file-lines (magit-git-dir "BISECT_TERMS")))
|
||||
|
||||
(defun magit-insert-bisect-output ()
|
||||
"While bisecting, insert section with output from `git bisect'."
|
||||
(when (magit-bisect-in-progress-p)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-blame.el --- blame support for Magit -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2012-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2012-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -475,7 +475,9 @@ modes is toggled, then this mode also gets toggled automatically.
|
||||
|
||||
(defun magit-blame--parse-chunk (type)
|
||||
(let (chunk revinfo)
|
||||
(looking-at "^\\(.\\{40\\}\\) \\([0-9]+\\) \\([0-9]+\\) \\([0-9]+\\)")
|
||||
(unless (looking-at "^\\(.\\{40\\}\\) \\([0-9]+\\) \\([0-9]+\\) \\([0-9]+\\)")
|
||||
(error "Blaming failed due to unexpected output: %s"
|
||||
(buffer-substring-no-properties (point) (line-end-position))))
|
||||
(with-slots (orig-rev orig-file prev-rev prev-file)
|
||||
(setq chunk (magit-blame-chunk
|
||||
:orig-rev (match-string 1)
|
||||
@@ -674,9 +676,10 @@ modes is toggled, then this mode also gets toggled automatically.
|
||||
(propertize
|
||||
(concat (propertize "\s" 'display '(space :height (2)))
|
||||
(propertize "\n" 'line-height t))
|
||||
'font-lock-face (list :background
|
||||
(face-attribute 'magit-blame-heading
|
||||
:background nil t))))
|
||||
'font-lock-face `(:background
|
||||
,(face-attribute 'magit-blame-heading
|
||||
:background nil t)
|
||||
,@(and (>= emacs-major-version 27) '(:extend t)))))
|
||||
|
||||
(defun magit-blame--format-time-string (time tz)
|
||||
(let* ((time-format (or (magit-blame--style-get 'time-format)
|
||||
@@ -903,7 +906,7 @@ instead of the hash, like `kill-ring-save' would."
|
||||
("q" "Quit blaming" magit-blame-quit)]
|
||||
["Refresh"
|
||||
:if-non-nil magit-blame-mode
|
||||
("c" "Cycle style" magit-blame-cycle-style)])
|
||||
("c" "Cycle style" magit-blame-cycle-style :transient t)])
|
||||
|
||||
(defun magit-blame-arguments ()
|
||||
(transient-args 'magit-blame))
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-bookmark.el --- bookmark support for Magit -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2010-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2010-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-branch.el --- branch support -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2010-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2010-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-clone.el --- clone a repository -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2008-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2008-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -192,30 +192,44 @@ Then show the status buffer for the new repository."
|
||||
(magit-clone-internal repository directory (cons "--mirror" args)))
|
||||
|
||||
(defun magit-clone-internal (repository directory args)
|
||||
(run-hooks 'magit-credential-hook)
|
||||
(setq directory (file-name-as-directory (expand-file-name directory)))
|
||||
(magit-run-git-async "clone" args "--" repository
|
||||
(magit-convert-filename-for-git directory))
|
||||
;; Don't refresh the buffer we're calling from.
|
||||
(process-put magit-this-process 'inhibit-refresh t)
|
||||
(set-process-sentinel
|
||||
magit-this-process
|
||||
(lambda (process event)
|
||||
(when (memq (process-status process) '(exit signal))
|
||||
(let ((magit-process-raise-error t))
|
||||
(magit-process-sentinel process event)))
|
||||
(when (and (eq (process-status process) 'exit)
|
||||
(= (process-exit-status process) 0))
|
||||
(unless (memq (car args) '("--bare" "--mirror"))
|
||||
(let ((default-directory directory))
|
||||
(when (or (eq magit-clone-set-remote.pushDefault t)
|
||||
(and magit-clone-set-remote.pushDefault
|
||||
(y-or-n-p "Set `remote.pushDefault' to \"origin\"? ")))
|
||||
(setf (magit-get "remote.pushDefault") "origin"))
|
||||
(unless magit-clone-set-remote-head
|
||||
(magit-remote-unset-head "origin"))))
|
||||
(with-current-buffer (process-get process 'command-buf)
|
||||
(magit-status-setup-buffer directory))))))
|
||||
(let* ((checkout (not (memq (car args) '("--bare" "--mirror"))))
|
||||
(set-push-default
|
||||
(and checkout
|
||||
(or (eq magit-clone-set-remote.pushDefault t)
|
||||
(and magit-clone-set-remote.pushDefault
|
||||
(y-or-n-p "Set `remote.pushDefault' to \"origin\"? "))))))
|
||||
(run-hooks 'magit-credential-hook)
|
||||
(setq directory (file-name-as-directory (expand-file-name directory)))
|
||||
(when (file-exists-p directory)
|
||||
(if (file-directory-p directory)
|
||||
(when (> (length (directory-files directory)) 2)
|
||||
(let ((name (magit-clone--url-to-name repository)))
|
||||
(unless (and name
|
||||
(setq directory (file-name-as-directory
|
||||
(expand-file-name name directory)))
|
||||
(not (file-exists-p directory)))
|
||||
(user-error "%s already exists" directory))))
|
||||
(user-error "%s already exists and is not a directory" directory)))
|
||||
(magit-run-git-async "clone" args "--" repository
|
||||
(magit-convert-filename-for-git directory))
|
||||
;; Don't refresh the buffer we're calling from.
|
||||
(process-put magit-this-process 'inhibit-refresh t)
|
||||
(set-process-sentinel
|
||||
magit-this-process
|
||||
(lambda (process event)
|
||||
(when (memq (process-status process) '(exit signal))
|
||||
(let ((magit-process-raise-error t))
|
||||
(magit-process-sentinel process event)))
|
||||
(when (and (eq (process-status process) 'exit)
|
||||
(= (process-exit-status process) 0))
|
||||
(when checkout
|
||||
(let ((default-directory directory))
|
||||
(when set-push-default
|
||||
(setf (magit-get "remote.pushDefault") "origin"))
|
||||
(unless magit-clone-set-remote-head
|
||||
(magit-remote-unset-head "origin"))))
|
||||
(with-current-buffer (process-get process 'command-buf)
|
||||
(magit-status-setup-buffer directory)))))))
|
||||
|
||||
(defun magit-clone-read-args ()
|
||||
(let ((repo (magit-clone-read-repository)))
|
||||
@@ -226,8 +240,7 @@ Then show the status buffer for the new repository."
|
||||
(funcall magit-clone-default-directory repo)
|
||||
magit-clone-default-directory)
|
||||
nil nil
|
||||
(and (string-match "\\([^/:]+?\\)\\(/?\\.git\\)?$" repo)
|
||||
(match-string 1 repo)))
|
||||
(magit-clone--url-to-name repo))
|
||||
(transient-args 'magit-clone))))
|
||||
|
||||
(defun magit-clone-read-repository ()
|
||||
@@ -242,8 +255,12 @@ Then show the status buffer for the new repository."
|
||||
(?l "or [l]ocal url"
|
||||
(concat "file://" (read-directory-name "Clone repository: file://")))))
|
||||
|
||||
(defun magit-clone--url-to-name (url)
|
||||
(and (string-match "\\([^/:]+?\\)\\(/?\\.git\\)?$" url)
|
||||
(match-string 1 url)))
|
||||
|
||||
(defun magit-clone--name-to-url (name)
|
||||
(or (-some
|
||||
(or (seq-some
|
||||
(pcase-lambda (`(,re ,host ,user))
|
||||
(and (string-match re name)
|
||||
(let ((repo (match-string 1 name)))
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-commit.el --- create Git commits -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2008-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2008-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -39,7 +39,7 @@
|
||||
;;; Options
|
||||
|
||||
(defcustom magit-commit-ask-to-stage 'verbose
|
||||
"Whether to ask to stage all unstaged changes when committing and nothing is staged."
|
||||
"Whether to ask to stage everything when committing and nothing is staged."
|
||||
:package-version '(magit . "2.3.0")
|
||||
:group 'magit-commands
|
||||
:type '(choice (const :tag "Ask" t)
|
||||
@@ -126,7 +126,8 @@ Also see `git-commit-post-finish-hook'."
|
||||
("f" "Fixup" magit-commit-fixup)
|
||||
("s" "Squash" magit-commit-squash)
|
||||
("A" "Augment" magit-commit-augment)
|
||||
(6 "x" "Absorb changes" magit-commit-autofixup)]
|
||||
(6 "x" "Absorb changes" magit-commit-autofixup)
|
||||
(6 "X" "Absorb modules" magit-commit-absorb-modules)]
|
||||
[""
|
||||
("F" "Instant fixup" magit-commit-instant-fixup)
|
||||
("S" "Instant squash" magit-commit-instant-squash)]]
|
||||
@@ -217,7 +218,7 @@ to inverse the meaning of the prefix argument. \n(git commit
|
||||
(if current-prefix-arg
|
||||
(not magit-commit-extend-override-date)
|
||||
magit-commit-extend-override-date)))
|
||||
(when (setq args (magit-commit-assert args (not override-date)))
|
||||
(when (setq args (magit-commit-assert args))
|
||||
(magit-commit-amend-assert)
|
||||
(let ((process-environment process-environment))
|
||||
(unless override-date
|
||||
@@ -357,7 +358,11 @@ depending on the value of option `magit-commit-squash-confirm'."
|
||||
(and (not strict)
|
||||
;; ^ For amend variants that don't make sense otherwise.
|
||||
(or (member "--amend" args)
|
||||
(member "--allow-empty" args))))
|
||||
(member "--allow-empty" args)
|
||||
(member "--reset-author" args)
|
||||
(member "--author" args)
|
||||
(member "--signoff" args)
|
||||
(cl-find-if (lambda (a) (string-match-p "\\`--date=" a)) args))))
|
||||
(or args (list "--")))
|
||||
((and (magit-rebase-in-progress-p)
|
||||
(not (magit-anything-unstaged-p))
|
||||
@@ -410,6 +415,30 @@ history element."
|
||||
(and (magit-rev-author-p "HEAD")
|
||||
(concat "--date=" date)))))
|
||||
|
||||
;;;###autoload
|
||||
(defun magit-commit-absorb-modules (phase commit)
|
||||
"Spread modified modules across recent commits."
|
||||
(interactive (list 'select (magit-get-upstream-branch)))
|
||||
(let ((modules (magit-list-modified-modules)))
|
||||
(unless modules
|
||||
(user-error "There are no modified modules that could be absorbed"))
|
||||
(when commit
|
||||
(setq commit (magit-rebase-interactive-assert commit t)))
|
||||
(if (and commit (eq phase 'run))
|
||||
(progn
|
||||
(dolist (module modules)
|
||||
(when-let ((msg (magit-git-string
|
||||
"log" "-1" "--format=%s"
|
||||
(concat commit "..") "--" module)))
|
||||
(magit-git "commit" "-m" (concat "fixup! " msg)
|
||||
"--only" "--" module)))
|
||||
(magit-refresh)
|
||||
t)
|
||||
(magit-log-select
|
||||
(lambda (commit)
|
||||
(magit-commit-absorb-modules 'run commit))
|
||||
nil nil nil nil commit))))
|
||||
|
||||
;;;###autoload (autoload 'magit-commit-absorb "magit-commit" nil t)
|
||||
(transient-define-prefix magit-commit-absorb (phase commit args)
|
||||
"Spread staged changes across recent commits.
|
||||
@@ -451,10 +480,14 @@ See `magit-commit-autofixup' for an alternative implementation."
|
||||
|
||||
;;;###autoload (autoload 'magit-commit-autofixup "magit-commit" nil t)
|
||||
(transient-define-prefix magit-commit-autofixup (phase commit args)
|
||||
"Spread unstaged changes across recent commits.
|
||||
With a prefix argument use a transient command to select infix
|
||||
arguments. This command requires the git-autofixup script, which
|
||||
is available from https://github.com/torbiak/git-autofixup.
|
||||
"Spread staged or unstaged changes across recent commits.
|
||||
|
||||
If there are any staged then spread only those, otherwise
|
||||
spread all unstaged changes. With a prefix argument use a
|
||||
transient command to select infix arguments.
|
||||
|
||||
This command requires the git-autofixup script, which is
|
||||
available from https://github.com/torbiak/git-autofixup.
|
||||
See `magit-commit-absorb' for an alternative implementation."
|
||||
["Arguments"
|
||||
(magit-autofixup:--context)
|
||||
@@ -471,10 +504,8 @@ See `magit-commit-absorb' for an alternative implementation."
|
||||
(unless (executable-find "git-autofixup")
|
||||
(user-error "This command requires the git-autofixup script, which %s"
|
||||
"is available from https://github.com/torbiak/git-autofixup"))
|
||||
(when (magit-anything-staged-p)
|
||||
(user-error "Cannot absorb when there are staged changes"))
|
||||
(unless (magit-anything-unstaged-p)
|
||||
(user-error "There are no unstaged changes that could be absorbed"))
|
||||
(unless (magit-anything-modified-p)
|
||||
(user-error "There are no changes that could be absorbed"))
|
||||
(when commit
|
||||
(setq commit (magit-rebase-interactive-assert commit t)))
|
||||
(if (and commit (eq phase 'run))
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-core.el --- core functionality -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2010-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2010-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-diff.el --- inspect Git diffs -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2010-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2010-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -75,6 +75,7 @@
|
||||
(defgroup magit-diff nil
|
||||
"Inspect and manipulate Git diffs."
|
||||
:link '(info-link "(magit)Diffing")
|
||||
:group 'magit-commands
|
||||
:group 'magit-modes)
|
||||
|
||||
(defcustom magit-diff-mode-hook nil
|
||||
@@ -298,11 +299,14 @@ that many spaces. Otherwise, highlight neither."
|
||||
:link '(info-link "(magit)Revision Buffer")
|
||||
:group 'magit-modes)
|
||||
|
||||
(defcustom magit-revision-mode-hook '(bug-reference-mode)
|
||||
(defcustom magit-revision-mode-hook
|
||||
'(bug-reference-mode
|
||||
goto-address-mode)
|
||||
"Hook run after entering Magit-Revision mode."
|
||||
:group 'magit-revision
|
||||
:type 'hook
|
||||
:options '(bug-reference-mode))
|
||||
:options '(bug-reference-mode
|
||||
goto-address-mode))
|
||||
|
||||
(defcustom magit-revision-sections-hook
|
||||
'(magit-insert-revision-tag
|
||||
@@ -817,14 +821,16 @@ and `:slant'."
|
||||
;;; Section Classes
|
||||
|
||||
(defclass magit-file-section (magit-section)
|
||||
((source :initform nil)
|
||||
(header :initform nil)))
|
||||
((keymap :initform magit-file-section-map)
|
||||
(source :initform nil)
|
||||
(header :initform nil)))
|
||||
|
||||
(defclass magit-module-section (magit-file-section)
|
||||
())
|
||||
((keymap :initform magit-hunk-section-map)))
|
||||
|
||||
(defclass magit-hunk-section (magit-section)
|
||||
((refined :initform nil)
|
||||
((keymap :initform magit-hunk-section-map)
|
||||
(refined :initform nil)
|
||||
(combined :initform nil)
|
||||
(from-range :initform nil)
|
||||
(from-ranges :initform nil)
|
||||
@@ -939,7 +945,7 @@ and `:slant'."
|
||||
:description "Context lines"
|
||||
:class 'transient-option
|
||||
:argument "-U"
|
||||
:reader 'transient-read-number-N+)
|
||||
:reader 'transient-read-number-N0)
|
||||
|
||||
(transient-define-argument magit-diff:-M ()
|
||||
:description "Detect renames"
|
||||
@@ -1059,13 +1065,13 @@ If no DWIM context is found, nil is returned."
|
||||
(cons 'commit
|
||||
(magit-section-case
|
||||
(commit (oref it value))
|
||||
(file (-> it
|
||||
(oref parent)
|
||||
(oref value)))
|
||||
(hunk (-> it
|
||||
(oref parent)
|
||||
(oref parent)
|
||||
(oref value))))))
|
||||
(file (thread-first it
|
||||
(oref parent)
|
||||
(oref value)))
|
||||
(hunk (thread-first it
|
||||
(oref parent)
|
||||
(oref parent)
|
||||
(oref value))))))
|
||||
((derived-mode-p 'magit-revision-mode)
|
||||
(cons 'commit magit-buffer-revision))
|
||||
((derived-mode-p 'magit-diff-mode)
|
||||
@@ -1332,9 +1338,6 @@ for a revision."
|
||||
(magit-section-update-highlight)
|
||||
t))
|
||||
|
||||
(cl-defmethod magit-buffer-value (&context (major-mode magit-revision-mode))
|
||||
(cons magit-buffer-range magit-buffer-diff-files))
|
||||
|
||||
;;;; Setting Commands
|
||||
|
||||
(defun magit-diff-switch-range-type ()
|
||||
@@ -1553,7 +1556,7 @@ Like `magit-diff-visit-worktree-file' but use
|
||||
(defun magit-diff-visit-file--internal (file force-worktree fn)
|
||||
"From a diff visit the appropriate version of FILE.
|
||||
If FORCE-WORKTREE is non-nil, then visit the worktree version of
|
||||
the file, even if the diff is about a committed change. USE FN
|
||||
the file, even if the diff is about a committed change. Use FN
|
||||
to display the buffer in some window."
|
||||
(if (magit-file-accessible-directory-p file)
|
||||
(magit-diff-visit-directory file force-worktree)
|
||||
@@ -1827,7 +1830,7 @@ commit or stash at point, then prompt for a commit."
|
||||
(cond ((and (--any-p (oref it hidden) children)
|
||||
(--any-p (oref it children) children))
|
||||
(mapc 'magit-section-show-headings sections))
|
||||
((-any-p 'magit-section-hidden-body children)
|
||||
((seq-some 'magit-section-hidden-body children)
|
||||
(mapc 'magit-section-show-children sections))
|
||||
(t
|
||||
(mapc 'magit-section-hide sections)))))))
|
||||
@@ -2557,7 +2560,7 @@ or a ref which is not a branch, then it inserts nothing."
|
||||
(eq magit-revision-insert-related-refs 'all))
|
||||
(magit--insert-related-refs
|
||||
magit-buffer-revision "--contains" "Contained"
|
||||
(eq magit-revision-insert-related-refs '(all mixed)))
|
||||
(memq magit-revision-insert-related-refs '(all mixed)))
|
||||
(when-let ((follows (magit-get-current-tag magit-buffer-revision t)))
|
||||
(let ((tag (car follows))
|
||||
(cnt (cadr follows)))
|
||||
@@ -2810,10 +2813,10 @@ Do not confuse this with `magit-diff-scope' (which see)."
|
||||
(if (memq type '(file module))
|
||||
(magit-diff-type parent)
|
||||
type)))
|
||||
(`hunk (-> it
|
||||
(oref parent)
|
||||
(oref parent)
|
||||
(oref type)))))))
|
||||
(`hunk (thread-first it
|
||||
(oref parent)
|
||||
(oref parent)
|
||||
(oref type)))))))
|
||||
((derived-mode-p 'magit-log-mode)
|
||||
(if (or (and (magit-section-match 'commit section)
|
||||
(oref section children))
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-ediff.el --- Ediff extension for Magit -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2010-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2010-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-extras.el --- additional functionality for Magit -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2008-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2008-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -30,9 +30,14 @@
|
||||
(require 'magit)
|
||||
|
||||
(declare-function dired-read-shell-command "dired-aux" (prompt arg files))
|
||||
;; For `magit-project-status'.
|
||||
(declare-function project-root "project" (project))
|
||||
(declare-function vc-git-command "vc-git" (buffer okstatus file-or-list &rest flags))
|
||||
|
||||
(defvar ido-exit)
|
||||
(defvar ido-fallback)
|
||||
(defvar project-prefix-map)
|
||||
(defvar project-switch-commands)
|
||||
|
||||
(defgroup magit-extras nil
|
||||
"Additional functionality for Magit."
|
||||
@@ -131,6 +136,20 @@ like pretty much every other keymap:
|
||||
(with-no-warnings (setq fallback 'magit-status)) ; for Emacs 25
|
||||
(exit-minibuffer))
|
||||
|
||||
;;;###autoload
|
||||
(defun magit-project-status ()
|
||||
"Run `magit-status' in the current project's root."
|
||||
(interactive)
|
||||
(magit-status-setup-buffer (project-root (project-current t))))
|
||||
|
||||
(with-eval-after-load 'project
|
||||
;; Only more recent versions of project.el have `project-prefix-map' and
|
||||
;; `project-switch-commands', though project.el is available in Emacs 25.
|
||||
(when (boundp 'project-prefix-map)
|
||||
(define-key project-prefix-map "m" #'magit-project-status))
|
||||
(when (boundp 'project-switch-commands)
|
||||
(add-to-list 'project-switch-commands '(?m "Magit" magit-status))))
|
||||
|
||||
;;;###autoload
|
||||
(defun magit-dired-jump (&optional other-window)
|
||||
"Visit file at point using Dired.
|
||||
@@ -250,6 +269,44 @@ with two prefix arguments remove ignored files only.
|
||||
|
||||
;;; ChangeLog
|
||||
|
||||
(defun magit-generate-changelog (&optional amending)
|
||||
"Insert ChangeLog entries into the current buffer.
|
||||
|
||||
The entries are generated from the diff being committed.
|
||||
If prefix argument, AMENDING, is non-nil, include changes
|
||||
in HEAD as well as staged changes in the diff to check."
|
||||
(interactive "P")
|
||||
(unless (magit-commit-message-buffer)
|
||||
(user-error "No commit in progress"))
|
||||
(require 'diff-mode) ; `diff-add-log-current-defuns'.
|
||||
(require 'vc-git) ; `vc-git-diff'.
|
||||
(require 'add-log) ; `change-log-insert-entries'.
|
||||
(unless (and (fboundp 'change-log-insert-entries)
|
||||
(fboundp 'diff-add-log-current-defuns))
|
||||
(user-error "`magit-generate-changelog' requires Emacs 27 or better"))
|
||||
(setq default-directory
|
||||
(if (and (file-regular-p "gitdir")
|
||||
(not (magit-git-true "rev-parse" "--is-inside-work-tree"))
|
||||
(magit-git-true "rev-parse" "--is-inside-git-dir"))
|
||||
(file-name-directory (magit-file-line "gitdir"))
|
||||
(magit-toplevel)))
|
||||
(let ((rev1 (if amending "HEAD^1" "HEAD"))
|
||||
(rev2 nil))
|
||||
;; Magit may have updated the files without notifying vc, but
|
||||
;; `diff-add-log-current-defuns' relies on vc being up-to-date.
|
||||
(mapc #'vc-file-clearprops (magit-staged-files))
|
||||
(change-log-insert-entries
|
||||
(with-temp-buffer
|
||||
(vc-git-command (current-buffer) 1 nil
|
||||
"diff-index" "--exit-code" "--patch"
|
||||
(and (magit-anything-staged-p) "--cached")
|
||||
rev1 "--")
|
||||
;; `diff-find-source-location' consults these vars.
|
||||
(defvar diff-vc-revisions)
|
||||
(setq-local diff-vc-revisions (list rev1 rev2))
|
||||
(setq-local diff-vc-backend 'Git)
|
||||
(diff-add-log-current-defuns)))))
|
||||
|
||||
;;;###autoload
|
||||
(defun magit-add-change-log-entry (&optional whoami file-name other-window)
|
||||
"Find change log file and add date entry and item for current change.
|
||||
@@ -565,7 +622,7 @@ the minibuffer too."
|
||||
(kbd "C-c C-w") 'magit-pop-revision-stack)
|
||||
|
||||
;;;###autoload
|
||||
(defun magit-copy-section-value ()
|
||||
(defun magit-copy-section-value (arg)
|
||||
"Save the value of the current section for later use.
|
||||
|
||||
Save the section value to the `kill-ring', and, provided that
|
||||
@@ -583,17 +640,23 @@ argument is used, then save the revision at its tip to the
|
||||
|
||||
When the region is active, then save that to the `kill-ring',
|
||||
like `kill-ring-save' would, instead of behaving as described
|
||||
above. If a prefix argument is used and the region is within a
|
||||
hunk, strip the outer diff marker column."
|
||||
(interactive)
|
||||
above. If a prefix argument is used and the region is within
|
||||
a hunk, then strip the diff marker column and keep only either
|
||||
the added or removed lines, depending on the sign of the prefix
|
||||
argument."
|
||||
(interactive "P")
|
||||
(cond
|
||||
((and current-prefix-arg
|
||||
((and arg
|
||||
(magit-section-internal-region-p)
|
||||
(magit-section-match 'hunk))
|
||||
(kill-new (replace-regexp-in-string
|
||||
"^[ \\+\\-]" ""
|
||||
(buffer-substring-no-properties
|
||||
(region-beginning) (region-end))))
|
||||
(kill-new
|
||||
(thread-last (buffer-substring-no-properties
|
||||
(region-beginning)
|
||||
(region-end))
|
||||
(replace-regexp-in-string
|
||||
(format "^\\%c.*\n?" (if (< (prefix-numeric-value arg) 0) ?+ ?-))
|
||||
"")
|
||||
(replace-regexp-in-string "^[ \\+\\-]" "")))
|
||||
(deactivate-mark))
|
||||
((use-region-p)
|
||||
(call-interactively #'copy-region-as-kill))
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-fetch.el --- download objects and refs -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2008-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2008-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -46,7 +46,8 @@ Ignored for Git versions before v2.8.0."
|
||||
:man-page "git-fetch"
|
||||
["Arguments"
|
||||
("-p" "Prune deleted branches" ("-p" "--prune"))
|
||||
("-t" "Fetch all tags" ("-t" "--tags"))]
|
||||
("-t" "Fetch all tags" ("-t" "--tags"))
|
||||
(7 "-u" "Fetch full history" "--unshallow")]
|
||||
["Fetch from"
|
||||
("p" magit-fetch-from-pushremote)
|
||||
("u" magit-fetch-from-upstream)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-files.el --- finding files -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2010-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2010-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -279,19 +279,13 @@ directory, while reading the FILENAME."
|
||||
(confirm-nonexistent-file-or-buffer))))
|
||||
(find-file-other-frame filename wildcards))
|
||||
|
||||
;;; File Mode
|
||||
|
||||
(defvar magit-file-mode-map
|
||||
(let ((map (make-sparse-keymap)))
|
||||
(define-key map "\C-xg" 'magit-status)
|
||||
(define-key map "\C-x\M-g" 'magit-dispatch)
|
||||
(define-key map "\C-c\M-g" 'magit-file-dispatch)
|
||||
map)
|
||||
"Keymap for `magit-file-mode'.")
|
||||
;;; File Dispatch
|
||||
|
||||
;;;###autoload (autoload 'magit-file-dispatch "magit" nil t)
|
||||
(transient-define-prefix magit-file-dispatch ()
|
||||
"Invoke a Magit command that acts on the visited file."
|
||||
"Invoke a Magit command that acts on the visited file.
|
||||
When invoked outside a file-visiting buffer, then fall back
|
||||
to `magit-dispatch'."
|
||||
:info-manual "(magit) Minor Mode for Buffers Visiting Files"
|
||||
["Actions"
|
||||
[("s" "Stage" magit-stage-file)
|
||||
@@ -317,39 +311,12 @@ directory, while reading the FILENAME."
|
||||
[(5 "C-c r" "Rename file" magit-file-rename)
|
||||
(5 "C-c d" "Delete file" magit-file-delete)
|
||||
(5 "C-c u" "Untrack file" magit-file-untrack)
|
||||
(5 "C-c c" "Checkout file" magit-file-checkout)]])
|
||||
|
||||
(defvar magit-file-mode-lighter "")
|
||||
|
||||
(define-minor-mode magit-file-mode
|
||||
"Enable some Magit features in a file-visiting buffer.
|
||||
|
||||
Currently this only adds the following key bindings.
|
||||
\n\\{magit-file-mode-map}"
|
||||
:package-version '(magit . "2.2.0")
|
||||
:lighter magit-file-mode-lighter
|
||||
:keymap magit-file-mode-map)
|
||||
|
||||
(defun magit-file-mode-turn-on ()
|
||||
(and buffer-file-name
|
||||
(magit-inside-worktree-p t)
|
||||
(magit-file-mode)))
|
||||
|
||||
;;;###autoload
|
||||
(define-globalized-minor-mode global-magit-file-mode
|
||||
magit-file-mode magit-file-mode-turn-on
|
||||
:package-version '(magit . "2.13.0")
|
||||
:link '(info-link "(magit)Minor Mode for Buffers Visiting Files")
|
||||
:group 'magit-essentials
|
||||
:group 'magit-modes
|
||||
:init-value t)
|
||||
;; Unfortunately `:init-value t' only sets the value of the mode
|
||||
;; variable but does not cause the mode function to be called, and we
|
||||
;; cannot use `:initialize' to call that explicitly because the option
|
||||
;; is defined before the functions, so we have to do it here.
|
||||
(cl-eval-when (load eval)
|
||||
(when global-magit-file-mode
|
||||
(global-magit-file-mode 1)))
|
||||
(5 "C-c c" "Checkout file" magit-file-checkout)]]
|
||||
(interactive)
|
||||
(transient-setup
|
||||
(if (or buffer-file-name magit-buffer-file-name)
|
||||
'magit-file-dispatch
|
||||
'magit-dispatch)))
|
||||
|
||||
;;; Blob Mode
|
||||
|
||||
@@ -430,20 +397,27 @@ the same location in the respective file in the working tree."
|
||||
;;; File Commands
|
||||
|
||||
(defun magit-file-rename (file newname)
|
||||
"Rename the FILE to NEWNAME.
|
||||
If FILE isn't tracked in Git, fallback to using `rename-file'."
|
||||
"Rename or move FILE to NEWNAME.
|
||||
NEWNAME may be a file or directory name. If FILE isn't tracked in
|
||||
Git, fallback to using `rename-file'."
|
||||
(interactive
|
||||
(let* ((file (magit-read-file "Rename file"))
|
||||
(dir (file-name-directory file))
|
||||
(newname (read-file-name (format "Rename %s to file: " file)
|
||||
(newname (read-file-name (format "Move %s to destination: " file)
|
||||
(and dir (expand-file-name dir)))))
|
||||
(list (expand-file-name file (magit-toplevel))
|
||||
(expand-file-name newname))))
|
||||
(let ((oldbuf (get-file-buffer file)))
|
||||
(let ((oldbuf (get-file-buffer file))
|
||||
(dstdir (file-name-directory newname))
|
||||
(dstfile (if (directory-name-p newname)
|
||||
(concat newname (file-name-nondirectory file))
|
||||
newname)))
|
||||
(when (and oldbuf (buffer-modified-p oldbuf))
|
||||
(user-error "Save %s before moving it" file))
|
||||
(when (file-exists-p newname)
|
||||
(user-error "%s already exists" newname))
|
||||
(when (file-exists-p dstfile)
|
||||
(user-error "%s already exists" dstfile))
|
||||
(unless (file-exists-p dstdir)
|
||||
(user-error "Destination directory %s does not exist" dstdir))
|
||||
(if (magit-file-tracked-p (magit-convert-filename-for-git file))
|
||||
(magit-call-git "mv"
|
||||
(magit-convert-filename-for-git file)
|
||||
@@ -452,7 +426,7 @@ If FILE isn't tracked in Git, fallback to using `rename-file'."
|
||||
(when oldbuf
|
||||
(with-current-buffer oldbuf
|
||||
(let ((buffer-read-only buffer-read-only))
|
||||
(set-visited-file-name newname nil t))
|
||||
(set-visited-file-name dstfile nil t))
|
||||
(if (fboundp 'vc-refresh-state)
|
||||
(vc-refresh-state)
|
||||
(with-no-warnings
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-git.el --- Git functionality -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2010-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2010-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -297,6 +297,19 @@ Also respect the value of `magit-with-editor-envvar'."
|
||||
(with-editor* magit-with-editor-envvar
|
||||
,@body)))
|
||||
|
||||
(defmacro magit--with-temp-process-buffer (&rest body)
|
||||
"Like `with-temp-buffer', but always propagate `process-environment'.
|
||||
When that var is buffer-local in the calling buffer, it is not
|
||||
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 process-environment))
|
||||
(with-temp-buffer
|
||||
(setq-local process-environment ,p)
|
||||
,@body))))
|
||||
|
||||
(defun magit-process-git-arguments (args)
|
||||
"Prepare ARGS for a function that invokes Git.
|
||||
|
||||
@@ -339,7 +352,7 @@ what you want, then use `magit-git-string-ng' instead.
|
||||
This is an experimental replacement for `magit-git-string', and
|
||||
still subject to major changes."
|
||||
(magit--with-refresh-cache (cons default-directory args)
|
||||
(with-temp-buffer
|
||||
(magit--with-temp-process-buffer
|
||||
(and (zerop (apply #'magit-process-file magit-git-executable nil t nil
|
||||
(magit-process-git-arguments args)))
|
||||
(not (bobp))
|
||||
@@ -359,7 +372,7 @@ This is an experimental replacement for `magit-git-string', and
|
||||
still subject to major changes. Also see `magit-git-string-p'."
|
||||
(magit--with-refresh-cache
|
||||
(list default-directory 'magit-git-string-ng args)
|
||||
(with-temp-buffer
|
||||
(magit--with-temp-process-buffer
|
||||
(let* ((args (magit-process-git-arguments args))
|
||||
(status (apply #'magit-process-file magit-git-executable
|
||||
nil t nil args)))
|
||||
@@ -387,7 +400,7 @@ newline, return an empty string. Like `magit-git-string' but
|
||||
ignore `magit-git-debug'."
|
||||
(setq args (-flatten args))
|
||||
(magit--with-refresh-cache (cons default-directory args)
|
||||
(with-temp-buffer
|
||||
(magit--with-temp-process-buffer
|
||||
(apply #'magit-process-file magit-git-executable nil (list t nil) nil
|
||||
(magit-process-git-arguments args))
|
||||
(unless (bobp)
|
||||
@@ -398,7 +411,7 @@ ignore `magit-git-debug'."
|
||||
"Execute Git with ARGS, returning its output."
|
||||
(setq args (-flatten args))
|
||||
(magit--with-refresh-cache (cons default-directory args)
|
||||
(with-temp-buffer
|
||||
(magit--with-temp-process-buffer
|
||||
(apply #'magit-process-file magit-git-executable nil (list t nil) nil
|
||||
(magit-process-git-arguments args))
|
||||
(buffer-substring-no-properties (point-min) (point-max)))))
|
||||
@@ -468,7 +481,7 @@ If there is no output, return nil. If the output begins with a
|
||||
newline, return an empty string."
|
||||
(setq args (-flatten args))
|
||||
(magit--with-refresh-cache (cons default-directory args)
|
||||
(with-temp-buffer
|
||||
(magit--with-temp-process-buffer
|
||||
(apply #'magit-git-insert args)
|
||||
(unless (bobp)
|
||||
(goto-char (point-min))
|
||||
@@ -480,7 +493,7 @@ Empty lines anywhere in the output are omitted.
|
||||
|
||||
If Git exits with a non-zero exit status, then report show a
|
||||
message and add a section in the respective process buffer."
|
||||
(with-temp-buffer
|
||||
(magit--with-temp-process-buffer
|
||||
(apply #'magit-git-insert args)
|
||||
(split-string (buffer-string) "\n" t)))
|
||||
|
||||
@@ -490,7 +503,7 @@ Empty items anywhere in the output are omitted.
|
||||
|
||||
If Git exits with a non-zero exit status, then report show a
|
||||
message and add a section in the respective process buffer."
|
||||
(with-temp-buffer
|
||||
(magit--with-temp-process-buffer
|
||||
(apply #'magit-git-insert args)
|
||||
(split-string (buffer-string) "\0" t)))
|
||||
|
||||
@@ -719,7 +732,8 @@ returning the truename."
|
||||
;; Git bug. See #2364.
|
||||
(not (equal wtree ".git")))
|
||||
;; Return the linked working tree.
|
||||
(file-name-directory wtree))
|
||||
(concat (file-remote-p default-directory)
|
||||
(file-name-directory wtree)))
|
||||
;; The working directory may not be the parent directory of
|
||||
;; .git if it was set up with `git init --separate-git-dir'.
|
||||
;; See #2955.
|
||||
@@ -893,7 +907,7 @@ range. Otherwise, it can be any revision or range accepted by
|
||||
revA revB))))
|
||||
|
||||
(defun magit-file-status (&rest args)
|
||||
(with-temp-buffer
|
||||
(magit--with-temp-process-buffer
|
||||
(save-excursion (magit-git-insert "status" "-z" args))
|
||||
(let ((pos (point)) status)
|
||||
(while (> (skip-chars-forward "[:print:]") 0)
|
||||
@@ -1372,12 +1386,13 @@ configured remote is an url, or the named branch does not exist,
|
||||
then return nil. I.e. return the name of an existing local or
|
||||
remote-tracking branch. The returned string is colorized
|
||||
according to the branch type."
|
||||
(when-let ((branch (or branch (magit-get-current-branch)))
|
||||
(upstream (magit-ref-abbrev (concat branch "@{upstream}"))))
|
||||
(magit--propertize-face
|
||||
upstream (if (equal (magit-get "branch" branch "remote") ".")
|
||||
'magit-branch-local
|
||||
'magit-branch-remote))))
|
||||
(magit--with-refresh-cache (list 'magit-get-upstream-branch branch)
|
||||
(when-let ((branch (or branch (magit-get-current-branch)))
|
||||
(upstream (magit-ref-abbrev (concat branch "@{upstream}"))))
|
||||
(magit--propertize-face
|
||||
upstream (if (equal (magit-get "branch" branch "remote") ".")
|
||||
'magit-branch-local
|
||||
'magit-branch-remote)))))
|
||||
|
||||
(defun magit-get-indirect-upstream-branch (branch &optional force)
|
||||
(let ((remote (magit-get "branch" branch "remote")))
|
||||
@@ -1441,12 +1456,13 @@ according to the branch type."
|
||||
(magit--propertize-face remote 'magit-branch-remote)))
|
||||
|
||||
(defun magit-get-push-branch (&optional branch verify)
|
||||
(when-let ((branch (or branch (setq branch (magit-get-current-branch))))
|
||||
(remote (magit-get-push-remote branch))
|
||||
(target (concat remote "/" branch)))
|
||||
(and (or (not verify)
|
||||
(magit-rev-verify target))
|
||||
(magit--propertize-face target 'magit-branch-remote))))
|
||||
(magit--with-refresh-cache (list 'magit-get-push-branch branch verify)
|
||||
(when-let ((branch (or branch (setq branch (magit-get-current-branch))))
|
||||
(remote (magit-get-push-remote branch))
|
||||
(target (concat remote "/" branch)))
|
||||
(and (or (not verify)
|
||||
(magit-rev-verify target))
|
||||
(magit--propertize-face target 'magit-branch-remote)))))
|
||||
|
||||
(defun magit-get-@{push}-branch (&optional branch)
|
||||
(let ((ref (magit-rev-parse "--symbolic-full-name"
|
||||
@@ -1495,30 +1511,31 @@ The returned value has the form (REMOTE . REF), where REMOTE is
|
||||
the name of a remote and REF is the ref local to the remote."
|
||||
(when-let ((ref (magit-ref-fullname refname)))
|
||||
(save-match-data
|
||||
(-some (lambda (line)
|
||||
(and (string-match "\
|
||||
(seq-some (lambda (line)
|
||||
(and (string-match "\
|
||||
\\`remote\\.\\([^.]+\\)\\.fetch=\\+?\\([^:]+\\):\\(.+\\)" line)
|
||||
(let ((rmt (match-string 1 line))
|
||||
(src (match-string 2 line))
|
||||
(dst (match-string 3 line)))
|
||||
(and (string-match (format "\\`%s\\'"
|
||||
(replace-regexp-in-string
|
||||
"*" "\\(.+\\)" dst t t))
|
||||
ref)
|
||||
(cons rmt (replace-regexp-in-string
|
||||
"*" (match-string 1 ref) src))))))
|
||||
(magit-git-lines "config" "--local" "--list")))))
|
||||
(let ((rmt (match-string 1 line))
|
||||
(src (match-string 2 line))
|
||||
(dst (match-string 3 line)))
|
||||
(and (string-match (format "\\`%s\\'"
|
||||
(replace-regexp-in-string
|
||||
"*" "\\(.+\\)" dst t t))
|
||||
ref)
|
||||
(cons rmt (replace-regexp-in-string
|
||||
"*" (match-string 1 ref) src))))))
|
||||
(magit-git-lines "config" "--local" "--list")))))
|
||||
|
||||
(defun magit-split-branch-name (branch)
|
||||
(cond ((member branch (magit-list-local-branch-names))
|
||||
(cons "." branch))
|
||||
((string-match "/" branch)
|
||||
(or (-some (lambda (remote)
|
||||
(and (string-match (format "\\`\\(%s\\)/\\(.+\\)\\'" remote)
|
||||
branch)
|
||||
(cons (match-string 1 branch)
|
||||
(match-string 2 branch))))
|
||||
(magit-list-remotes))
|
||||
(or (seq-some (lambda (remote)
|
||||
(and (string-match
|
||||
(format "\\`\\(%s\\)/\\(.+\\)\\'" remote)
|
||||
branch)
|
||||
(cons (match-string 1 branch)
|
||||
(match-string 2 branch))))
|
||||
(magit-list-remotes))
|
||||
(error "Invalid branch name %s" branch)))))
|
||||
|
||||
(defun magit-get-current-tag (&optional rev with-distance)
|
||||
@@ -1696,22 +1713,23 @@ SORTBY is a key or list of keys to pass to the `--sort' flag of
|
||||
(substring it 41))
|
||||
(magit-git-lines "ls-remote" remote)))
|
||||
|
||||
(defun magit-list-modified-modules ()
|
||||
(--keep (and (string-match "\\`\\+\\([^ ]+\\) \\(.+\\) (.+)\\'" it)
|
||||
(match-string 2 it))
|
||||
(magit-git-lines "submodule" "status")))
|
||||
|
||||
(defun magit-list-module-paths ()
|
||||
(--mapcat (and (string-match "^160000 [0-9a-z]\\{40\\} 0\t\\(.+\\)$" it)
|
||||
(list (match-string 1 it)))
|
||||
(magit-git-items "ls-files" "-z" "--stage")))
|
||||
|
||||
(defun magit-list-module-names ()
|
||||
(mapcar #'magit-get-submodule-name (magit-list-module-paths)))
|
||||
|
||||
(defun magit-get-submodule-name (path)
|
||||
"Return the name of the submodule at PATH.
|
||||
PATH has to be relative to the super-repository."
|
||||
(cadr (split-string
|
||||
(car (or (magit-git-items
|
||||
"config" "-z"
|
||||
"-f" (expand-file-name ".gitmodules" (magit-toplevel))
|
||||
"--get-regexp" "^submodule\\..*\\.path$"
|
||||
(concat "^" (regexp-quote (directory-file-name path)) "$"))
|
||||
(error "No such submodule `%s'" path)))
|
||||
"\n")))
|
||||
(magit-git-string "submodule--helper" "name" path))
|
||||
|
||||
(defun magit-list-worktrees ()
|
||||
(let (worktrees worktree)
|
||||
@@ -1819,7 +1837,7 @@ Return a list of two integers: (A>B B>A)."
|
||||
(cdr (split-string it))))
|
||||
|
||||
(defun magit-patch-id (rev)
|
||||
(with-temp-buffer
|
||||
(magit--with-temp-process-buffer
|
||||
(magit-process-file
|
||||
shell-file-name nil '(t nil) nil shell-command-switch
|
||||
(let ((exec (shell-quote-argument magit-git-executable)))
|
||||
@@ -1970,7 +1988,7 @@ and this option only controls what face is used.")
|
||||
(defmacro magit-with-blob (commit file &rest body)
|
||||
(declare (indent 2)
|
||||
(debug (form form body)))
|
||||
`(with-temp-buffer
|
||||
`(magit--with-temp-process-buffer
|
||||
(let ((buffer-file-name ,file))
|
||||
(save-excursion
|
||||
(magit-git-insert "cat-file" "-p"
|
||||
@@ -2266,10 +2284,21 @@ out. Only existing branches can be selected."
|
||||
(magit-tag-at-point)))
|
||||
|
||||
(defun magit-read-stash (prompt)
|
||||
(let ((stashes (magit-list-stashes)))
|
||||
(magit-completing-read prompt stashes nil t nil nil
|
||||
(magit-stash-at-point)
|
||||
(car stashes))))
|
||||
(let* ((atpoint (magit-stash-at-point))
|
||||
(default (and atpoint
|
||||
(concat atpoint (magit-rev-format " %s" atpoint))))
|
||||
(choices (mapcar (lambda (c)
|
||||
(pcase-let ((`(,rev ,msg) (split-string c "\0")))
|
||||
(concat (propertize rev 'face 'magit-hash)
|
||||
" " msg)))
|
||||
(magit-list-stashes "%gd%x00%s")))
|
||||
(choice (magit-completing-read prompt choices
|
||||
nil t nil nil
|
||||
default
|
||||
(car choices))))
|
||||
(and choice
|
||||
(string-match "^\\([^ ]+\\) \\(.+\\)" choice)
|
||||
(substring-no-properties (match-string 1 choice)))))
|
||||
|
||||
(defun magit-read-remote (prompt &optional default use-only)
|
||||
(let ((remotes (magit-list-remotes)))
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-gitignore.el --- intentionally untracked files -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2008-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2008-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-imenu.el --- Integrate Imenu in magit major modes -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2010-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2010-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-log.el --- inspect Git history -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2010-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2010-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -62,6 +62,7 @@
|
||||
(defgroup magit-log nil
|
||||
"Inspect and manipulate Git history."
|
||||
:link '(info-link "(magit)Logging")
|
||||
:group 'magit-commands
|
||||
:group 'magit-modes)
|
||||
|
||||
(defcustom magit-log-mode-hook nil
|
||||
@@ -450,10 +451,14 @@ the upstream isn't ahead of the current branch) show."
|
||||
("r" "current" magit-reflog-current)
|
||||
("O" "other" magit-reflog-other)
|
||||
("H" "HEAD" magit-reflog-head)]
|
||||
[:if magit--any-wip-mode-enabled-p
|
||||
[:if (lambda ()
|
||||
(require 'magit-wip)
|
||||
(magit--any-wip-mode-enabled-p))
|
||||
:description "Wiplog"
|
||||
("i" "index" magit-wip-log-index)
|
||||
("w" "worktree" magit-wip-log-worktree)]])
|
||||
("w" "worktree" magit-wip-log-worktree)]
|
||||
["Other"
|
||||
(5 "s" "shortlog" magit-shortlog)]])
|
||||
|
||||
;;;###autoload (autoload 'magit-log-refresh "magit-log" nil t)
|
||||
(transient-define-prefix magit-log-refresh ()
|
||||
@@ -871,6 +876,48 @@ is displayed in the current frame."
|
||||
"\\[magit-log-double-commit-limit] first"))))
|
||||
(user-error "Parent %s does not exist" parent-rev))))))
|
||||
|
||||
;;;; Shortlog Commands
|
||||
|
||||
;;;###autoload (autoload 'magit-shortlog "magit-log" nil t)
|
||||
(transient-define-prefix magit-shortlog ()
|
||||
"Show a history summary."
|
||||
:man-page "git-shortlog"
|
||||
:value '("--numbered" "--summary")
|
||||
["Arguments"
|
||||
("-n" "Sort by number of commits" ("-n" "--numbered"))
|
||||
("-s" "Show commit count summary only" ("-s" "--summary"))
|
||||
("-e" "Show email addresses" ("-e" "--email"))
|
||||
("-g" "Group commits by" "--group="
|
||||
:choices ("author" "committer" "trailer:"))
|
||||
(7 "-f" "Format string" "--format=")
|
||||
(7 "-w" "Linewrap" "-w" :class transient-option)]
|
||||
["Shortlog"
|
||||
("s" "since" magit-shortlog-since)
|
||||
("r" "range" magit-shortlog-range)])
|
||||
|
||||
(defun magit-git-shortlog (rev args)
|
||||
(with-current-buffer (get-buffer-create "*magit-shortlog*")
|
||||
(erase-buffer)
|
||||
(save-excursion
|
||||
(magit-git-insert "shortlog" args rev))
|
||||
(switch-to-buffer-other-window (current-buffer))))
|
||||
|
||||
;;;###autoload
|
||||
(defun magit-shortlog-since (rev args)
|
||||
"Show a history summary for commits since REV."
|
||||
(interactive
|
||||
(list (magit-read-branch-or-commit "Shortlog since" (magit-get-current-tag))
|
||||
(transient-args 'magit-shortlog)))
|
||||
(magit-git-shortlog (concat rev "..") args))
|
||||
|
||||
;;;###autoload
|
||||
(defun magit-shortlog-range (rev-or-range args)
|
||||
"Show a history summary for commit or range REV-OR-RANGE."
|
||||
(interactive
|
||||
(list (magit-read-range-or-commit "Shortlog for revision or range")
|
||||
(transient-args 'magit-shortlog)))
|
||||
(magit-git-shortlog rev-or-range args))
|
||||
|
||||
;;; Log Mode
|
||||
|
||||
(defvar magit-log-disable-graph-hack-args
|
||||
@@ -1074,7 +1121,7 @@ Do not add this to a hook variable."
|
||||
|
||||
(defconst magit-log-bisect-log-re
|
||||
(concat "^# "
|
||||
"\\(?3:bad:\\|skip:\\|good:\\) " ; "refs"
|
||||
"\\(?3:[^: \n]+:\\) " ; "refs"
|
||||
"\\[\\(?1:[^]\n]+\\)\\] " ; sha1
|
||||
"\\(?2:.*\\)$")) ; msg
|
||||
|
||||
@@ -1659,12 +1706,7 @@ Type \\[magit-cherry-pick] to apply the commit at point.
|
||||
(defun magit-insert-unpulled-from-pushremote ()
|
||||
"Insert commits that haven't been pulled from the push-remote yet."
|
||||
(--when-let (magit-get-push-branch)
|
||||
(unless (and (equal (magit-rev-name it)
|
||||
(magit-rev-name "@{upstream}"))
|
||||
(or (memq 'magit-insert-unpulled-from-upstream
|
||||
magit-status-sections-hook)
|
||||
(memq 'magit-insert-unpulled-from-upstream-or-recent
|
||||
magit-status-sections-hook)))
|
||||
(when (magit--insert-pushremote-log-p)
|
||||
(magit-insert-section (unpulled (concat ".." it) t)
|
||||
(magit-insert-heading
|
||||
(format (propertize "Unpulled from %s."
|
||||
@@ -1728,12 +1770,7 @@ Show the last `magit-log-section-commit-count' commits."
|
||||
(defun magit-insert-unpushed-to-pushremote ()
|
||||
"Insert commits that haven't been pushed to the push-remote yet."
|
||||
(--when-let (magit-get-push-branch)
|
||||
(unless (and (equal (magit-rev-name it)
|
||||
(magit-rev-name "@{upstream}"))
|
||||
(or (memq 'magit-insert-unpushed-to-upstream
|
||||
magit-status-sections-hook)
|
||||
(memq 'magit-insert-unpushed-to-upstream-or-recent
|
||||
magit-status-sections-hook)))
|
||||
(when (magit--insert-pushremote-log-p)
|
||||
(magit-insert-section (unpushed (concat it "..") t)
|
||||
(magit-insert-heading
|
||||
(format (propertize "Unpushed to %s."
|
||||
@@ -1742,6 +1779,15 @@ Show the last `magit-log-section-commit-count' commits."
|
||||
(magit-insert-log (concat it "..") magit-buffer-log-args)
|
||||
(magit-log-insert-child-count)))))
|
||||
|
||||
(defun magit--insert-pushremote-log-p ()
|
||||
(magit--with-refresh-cache 'magit--insert-pushremote-log-p
|
||||
(not (and (equal (magit-get-push-branch)
|
||||
(magit-get-upstream-branch))
|
||||
(or (memq 'magit-insert-unpulled-from-upstream
|
||||
magit-status-sections-hook)
|
||||
(memq 'magit-insert-unpulled-from-upstream-or-recent
|
||||
magit-status-sections-hook))))))
|
||||
|
||||
(defun magit-log-insert-child-count ()
|
||||
(when magit-section-show-child-count
|
||||
(let ((count (length (oref magit-insert-section--current children))))
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-margin.el --- margins in Magit buffers -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2010-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2010-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-merge.el --- merge functionality -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2010-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2010-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -47,7 +47,8 @@
|
||||
("-f" "Fast-forward only" "--ff-only")
|
||||
("-n" "No fast-forward" "--no-ff")
|
||||
(magit-merge:--strategy)
|
||||
(5 magit-diff:--diff-algorithm :argument "--Xdiff-algorithm=")
|
||||
(5 magit-merge:--strategy-option)
|
||||
(5 magit-diff:--diff-algorithm :argument "-Xdiff-algorithm=")
|
||||
(5 magit:--gpg-sign)]
|
||||
["Actions"
|
||||
:if-not magit-merge-in-progress-p
|
||||
@@ -78,6 +79,13 @@
|
||||
:argument "--strategy="
|
||||
:choices '("resolve" "recursive" "octopus" "ours" "subtree"))
|
||||
|
||||
(transient-define-argument magit-merge:--strategy-option ()
|
||||
:description "Strategy Option"
|
||||
:class 'transient-option
|
||||
:key "-X"
|
||||
:argument "--strategy-option="
|
||||
:choices '("ours" "theirs" "patience"))
|
||||
|
||||
;;;###autoload
|
||||
(defun magit-merge-plain (rev &optional args nocommit)
|
||||
"Merge commit REV into the current branch; using default message.
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-mode.el --- create and refresh Magit buffers -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2010-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2010-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -235,6 +235,8 @@ and Buffer Arguments'."
|
||||
:package-version '(magit . "3.0.0")
|
||||
:group 'magit-buffers
|
||||
:group 'magit-commands
|
||||
: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)
|
||||
@@ -266,6 +268,8 @@ and Buffer Arguments'."
|
||||
:package-version '(magit . "3.0.0")
|
||||
:group 'magit-buffers
|
||||
:group 'magit-commands
|
||||
: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)
|
||||
@@ -512,10 +516,10 @@ which visits the thing at point using `browse-url'."
|
||||
Magit is documented in info node `(magit)'."
|
||||
:group 'magit
|
||||
(hack-dir-local-variables-non-file-buffer)
|
||||
(face-remap-add-relative 'header-line 'magit-header-line)
|
||||
(setq mode-line-process (magit-repository-local-get 'mode-line-process))
|
||||
(setq-local bookmark-make-record-function 'magit--make-bookmark))
|
||||
|
||||
;;; Highlighting
|
||||
(setq-local bookmark-make-record-function 'magit--make-bookmark)
|
||||
(setq-local isearch-filter-predicate 'magit-section--open-temporarily))
|
||||
|
||||
;;; Local Variables
|
||||
|
||||
@@ -848,13 +852,13 @@ If a frame, then only consider buffers on that frame."
|
||||
(w (window)
|
||||
(b (window-buffer window)))
|
||||
(f (frame)
|
||||
(-some #'w (window-list frame 'no-minibuf))))
|
||||
(seq-some #'w (window-list frame 'no-minibuf))))
|
||||
(pcase-exhaustive frame
|
||||
(`nil (-some #'b (buffer-list)))
|
||||
(`all (-some #'f (frame-list)))
|
||||
(`visible (-some #'f (visible-frame-list)))
|
||||
((or `selected `t) (-some #'w (window-list (selected-frame))))
|
||||
((guard (framep frame)) (-some #'w (window-list frame)))))
|
||||
(`nil (seq-some #'b (buffer-list)))
|
||||
(`all (seq-some #'f (frame-list)))
|
||||
(`visible (seq-some #'f (visible-frame-list)))
|
||||
((or `selected `t) (seq-some #'w (window-list (selected-frame))))
|
||||
((guard (framep frame)) (seq-some #'w (window-list frame)))))
|
||||
(magit--not-inside-repository-error)))
|
||||
|
||||
(defun magit-mode-get-buffer (mode &optional create frame value)
|
||||
@@ -1033,11 +1037,11 @@ Run hooks `magit-pre-refresh-hook' and `magit-post-refresh-hook'."
|
||||
(magit-run-hook-with-benchmark 'magit-post-unstage-hook)))
|
||||
(magit-run-hook-with-benchmark 'magit-post-refresh-hook)
|
||||
(when magit-refresh-verbose
|
||||
(message "Refreshing magit...done (%.3fs, cached %s/%s)"
|
||||
(float-time (time-subtract (current-time) start))
|
||||
(caar magit--refresh-cache)
|
||||
(+ (caar magit--refresh-cache)
|
||||
(cdar magit--refresh-cache)))))
|
||||
(let* ((c (caar magit--refresh-cache))
|
||||
(a (+ c (cdar magit--refresh-cache))))
|
||||
(message "Refreshing magit...done (%.3fs, cached %s/%s (%.0f%%))"
|
||||
(float-time (time-subtract (current-time) start))
|
||||
c a (* (/ c (* a 1.0)) 100)))))
|
||||
(run-hooks 'magit-unwind-refresh-hook))))
|
||||
|
||||
(defun magit-refresh-all ()
|
||||
@@ -1344,15 +1348,15 @@ then the value is not cached, and we return nil."
|
||||
(defun magit-repository-local-exists-p (key &optional repository)
|
||||
"Non-nil when a repository-local value exists for KEY.
|
||||
|
||||
Returns a (KEY . value) cons cell.
|
||||
Return a (KEY . VALUE) cons cell.
|
||||
|
||||
The KEY is matched using `equal'.
|
||||
|
||||
Unless specified, REPOSITORY is the current buffer's repository."
|
||||
(let* ((repokey (or repository (magit-repository-local-repository)))
|
||||
(cache (assoc repokey magit-repository-local-cache)))
|
||||
(and cache
|
||||
(assoc key (cdr cache)))))
|
||||
(when-let ((cache (assoc (or repository
|
||||
(magit-repository-local-repository))
|
||||
magit-repository-local-cache)))
|
||||
(assoc key (cdr cache))))
|
||||
|
||||
(defun magit-repository-local-get (key &optional default repository)
|
||||
"Return the repository-local value for KEY.
|
||||
@@ -1362,21 +1366,30 @@ Return DEFAULT if no value for KEY exists.
|
||||
The KEY is matched using `equal'.
|
||||
|
||||
Unless specified, REPOSITORY is the current buffer's repository."
|
||||
(let ((keyvalue (magit-repository-local-exists-p key repository)))
|
||||
(if keyvalue
|
||||
(cdr keyvalue)
|
||||
default)))
|
||||
(if-let ((keyvalue (magit-repository-local-exists-p key repository)))
|
||||
(cdr keyvalue)
|
||||
default))
|
||||
|
||||
(defun magit-repository-local-delete (key &optional repository)
|
||||
"Delete the repository-local value for KEY.
|
||||
|
||||
Unless specified, REPOSITORY is the current buffer's repository."
|
||||
(let* ((repokey (or repository (magit-repository-local-repository)))
|
||||
(cache (assoc repokey magit-repository-local-cache)))
|
||||
(when cache
|
||||
;; There is no `assoc-delete-all'.
|
||||
(setf (cdr cache)
|
||||
(cl-delete key (cdr cache) :key #'car :test #'equal)))))
|
||||
(when-let ((cache (assoc (or repository
|
||||
(magit-repository-local-repository))
|
||||
magit-repository-local-cache)))
|
||||
;; There is no `assoc-delete-all'.
|
||||
(setf (cdr cache)
|
||||
(cl-delete key (cdr cache) :key #'car :test #'equal))))
|
||||
|
||||
(defmacro magit--with-repository-local-cache (key &rest body)
|
||||
(declare (indent 1) (debug (form body)))
|
||||
(let ((k (cl-gensym)))
|
||||
`(let ((,k ,key))
|
||||
(if-let ((kv (magit-repository-local-exists-p ,k)))
|
||||
(cdr kv)
|
||||
(let ((v ,(macroexp-progn body)))
|
||||
(magit-repository-local-set ,k v)
|
||||
v)))))
|
||||
|
||||
(defun magit-preserve-section-visibility-cache ()
|
||||
(when (derived-mode-p 'magit-status-mode 'magit-refs-mode)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-notes.el --- notes support -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2010-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2010-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-obsolete.el --- obsolete definitions -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2010-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2010-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-patch.el --- creating and applying patches -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2008-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2008-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -119,15 +119,13 @@ which creates patches for all commits that are reachable from
|
||||
(save-match-data
|
||||
(find-file
|
||||
(expand-file-name
|
||||
(concat (--some (and (string-match "\\`--reroll-count=\\(.+\\)" it)
|
||||
(format "v%s-" (match-string 1 it)))
|
||||
args)
|
||||
(concat (when-let ((v (transient-arg-value "--reroll-count=" args)))
|
||||
(format "v%s-" v))
|
||||
"0000-cover-letter.patch")
|
||||
(let ((topdir (magit-toplevel)))
|
||||
(or (--some (and (string-match "\\`--output-directory=\\(.+\\)" it)
|
||||
(expand-file-name (match-string 1 it) topdir))
|
||||
args)
|
||||
topdir))))))))
|
||||
(if-let ((dir (transient-arg-value "--output-directory=" args)))
|
||||
(expand-file-name dir topdir)
|
||||
topdir))))))))
|
||||
|
||||
(transient-define-argument magit-format-patch:--in-reply-to ()
|
||||
:description "In reply to"
|
||||
@@ -308,7 +306,7 @@ same differences as those shown in the buffer are always used."
|
||||
|
||||
;;;###autoload
|
||||
(defun magit-request-pull (url start end)
|
||||
"Request upstream to pull from you public repository.
|
||||
"Request upstream to pull from your public repository.
|
||||
|
||||
URL is the url of your publicly accessible repository.
|
||||
START is a commit that already is in the upstream repository.
|
||||
|
||||
@@ -1,12 +1,17 @@
|
||||
(define-package "magit" "20200627.806" "A Git porcelain inside Emacs."
|
||||
(define-package "magit" "20210105.1030" "A Git porcelain inside Emacs."
|
||||
'((emacs "25.1")
|
||||
(async "20200113")
|
||||
(dash "20200524")
|
||||
(git-commit "20200516")
|
||||
(transient "20200601")
|
||||
(with-editor "20200522"))
|
||||
:commit "9e35f9892ca3987d979a6212ff79b23ddbb42103" :keywords
|
||||
'("git" "tools" "vc"))
|
||||
:commit "25f432551347468ce97b8b03987e59092e91f8f0" :authors
|
||||
'(("Marius Vollmer" . "marius.vollmer@gmail.com"))
|
||||
:maintainer
|
||||
'("Jonas Bernoulli" . "jonas@bernoul.li")
|
||||
:keywords
|
||||
'("git" "tools" "vc")
|
||||
:url "https://github.com/magit/magit")
|
||||
;; Local Variables:
|
||||
;; no-byte-compile: t
|
||||
;; End:
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-process.el --- process functionality -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2010-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2010-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -99,6 +99,13 @@ When this is nil, no sections are ever removed."
|
||||
:group 'magit-process
|
||||
:type '(choice (const :tag "Never remove old sections" nil) integer))
|
||||
|
||||
(defvar magit-process-extreme-logging nil
|
||||
"Whether `magit-process-file' logs to *Messages* buffer.
|
||||
Only intended for temporary use when you try to figure out how
|
||||
Magit uses Git behind the scene. Output that normally goes to
|
||||
the magit-process buffer continues to go there. Not all output
|
||||
goes to either of these two buffers.")
|
||||
|
||||
(defcustom magit-process-error-tooltip-max-lines 20
|
||||
"The number of lines for `magit-process-error-lines' to return.
|
||||
|
||||
@@ -156,7 +163,7 @@ itself from the hook, to avoid further futile attempts."
|
||||
"\\([Nn]o?\\)"
|
||||
;; OpenSSH v8 prints this. See #3969.
|
||||
"\\(?:/\\[fingerprint\\]\\)?"
|
||||
"[\])] ?[?:] ?$")
|
||||
"[\])] ?[?:]? ?$")
|
||||
"Regexp matching Yes-or-No prompts of Git and its subprocesses."
|
||||
:package-version '(magit . "2.1.0")
|
||||
:group 'magit-process
|
||||
@@ -398,6 +405,9 @@ Process output goes into a new section in the buffer returned by
|
||||
Identical to `process-file' but temporarily enable Cygwin's
|
||||
\"noglob\" option during the call and ensure unix eol
|
||||
conversion."
|
||||
(when magit-process-extreme-logging
|
||||
(let ((inhibit-message t))
|
||||
(message "$ %s" (magit-process--format-arguments process args))))
|
||||
(let ((process-environment (magit-process-environment))
|
||||
(default-process-coding-system (magit--process-coding-system)))
|
||||
(apply #'process-file process infile buffer display args)))
|
||||
@@ -630,25 +640,7 @@ Magit status buffer."
|
||||
(unless (equal (expand-file-name pwd)
|
||||
(expand-file-name default-directory))
|
||||
(insert (file-relative-name pwd default-directory) ?\s))
|
||||
(cond
|
||||
((and args (equal program magit-git-executable))
|
||||
(setq args (-split-at (length magit-git-global-arguments) args))
|
||||
(insert (propertize (file-name-nondirectory program)
|
||||
'font-lock-face 'magit-section-heading) " ")
|
||||
(insert (propertize (char-to-string magit-ellipsis)
|
||||
'font-lock-face 'magit-section-heading
|
||||
'help-echo (mapconcat #'identity (car args) " ")))
|
||||
(insert " ")
|
||||
(insert (propertize (mapconcat #'shell-quote-argument (cadr args) " ")
|
||||
'font-lock-face 'magit-section-heading)))
|
||||
((and args (equal program shell-file-name))
|
||||
(insert (propertize (cadr args)
|
||||
'font-lock-face 'magit-section-heading)))
|
||||
(t
|
||||
(insert (propertize (file-name-nondirectory program)
|
||||
'font-lock-face 'magit-section-heading) " ")
|
||||
(insert (propertize (mapconcat #'shell-quote-argument args " ")
|
||||
'font-lock-face 'magit-section-heading))))
|
||||
(insert (magit-process--format-arguments program args))
|
||||
(magit-insert-heading)
|
||||
(when errlog
|
||||
(if (bufferp errlog)
|
||||
@@ -658,6 +650,29 @@ Magit status buffer."
|
||||
(goto-char (1- (point-max)))))
|
||||
(insert "\n"))))
|
||||
|
||||
(defun magit-process--format-arguments (program args)
|
||||
(cond
|
||||
((and args (equal program magit-git-executable))
|
||||
(setq args (-split-at (length magit-git-global-arguments) args))
|
||||
(concat (propertize (file-name-nondirectory program)
|
||||
'font-lock-face 'magit-section-heading)
|
||||
" "
|
||||
(propertize (char-to-string magit-ellipsis)
|
||||
'font-lock-face 'magit-section-heading
|
||||
'help-echo (mapconcat #'identity (car args) " "))
|
||||
" "
|
||||
(propertize (mapconcat #'shell-quote-argument (cadr args) " ")
|
||||
'font-lock-face 'magit-section-heading)))
|
||||
((and args (equal program shell-file-name))
|
||||
(propertize (cadr args)
|
||||
'font-lock-face 'magit-section-heading))
|
||||
(t
|
||||
(concat (propertize (file-name-nondirectory program)
|
||||
'font-lock-face 'magit-section-heading)
|
||||
" "
|
||||
(propertize (mapconcat #'shell-quote-argument args " ")
|
||||
'font-lock-face 'magit-section-heading)))))
|
||||
|
||||
(defun magit-process-truncate-log ()
|
||||
(let* ((head nil)
|
||||
(tail (oref magit-root-section children))
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-pull.el --- update local objects and refs -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2008-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2008-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-push.el --- update remote objects and refs -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2008-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2008-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -87,8 +87,12 @@ argument the push-remote can be changed before pushed to it."
|
||||
:if 'magit-get-current-branch
|
||||
:description 'magit-push--pushbranch-description
|
||||
(interactive (list (magit-push-arguments)))
|
||||
(pcase-let ((`(,branch ,remote)
|
||||
(pcase-let ((`(,branch ,remote ,changed)
|
||||
(magit--select-push-remote "push there")))
|
||||
(when changed
|
||||
(magit-confirm 'set-and-push
|
||||
(format "Really use \"%s\" as push-remote and push \"%s\" there"
|
||||
remote branch)))
|
||||
(run-hooks 'magit-credential-hook)
|
||||
(magit-run-git-async "push" "-v" args remote
|
||||
(format "refs/heads/%s:refs/heads/%s"
|
||||
@@ -136,16 +140,19 @@ the upstream."
|
||||
branches nil nil nil 'magit-revision-history
|
||||
(or (car (member (magit-remote-branch-at-point) branches))
|
||||
(car (member "origin/master" branches)))))
|
||||
(upstream (or (magit-get-tracked upstream)
|
||||
(magit-split-branch-name upstream))))
|
||||
(setq remote (car upstream))
|
||||
(setq merge (cdr upstream))
|
||||
(upstream* (or (magit-get-tracked upstream)
|
||||
(magit-split-branch-name upstream))))
|
||||
(setq remote (car upstream*))
|
||||
(setq merge (cdr upstream*))
|
||||
(unless (string-prefix-p "refs/" merge)
|
||||
;; User selected a non-existent remote-tracking branch.
|
||||
;; It is very likely, but not certain, that this is the
|
||||
;; correct thing to do. It is even more likely that it
|
||||
;; is what the user wants to happen.
|
||||
(setq merge (concat "refs/heads/" merge))))
|
||||
(setq merge (concat "refs/heads/" merge)))
|
||||
(magit-confirm 'set-and-push
|
||||
(format "Really use \"%s\" as upstream and push \"%s\" there"
|
||||
upstream branch)))
|
||||
(cl-pushnew "--set-upstream" args :test #'equal))
|
||||
(run-hooks 'magit-credential-hook)
|
||||
(magit-run-git-async "push" "-v" args remote (concat branch ":" merge))))
|
||||
@@ -262,8 +269,8 @@ branch as default."
|
||||
(run-hooks 'magit-credential-hook)
|
||||
(magit-run-git-async "push" remote ref args))
|
||||
|
||||
;;;###autoload
|
||||
(defun magit-push-implicitly (args)
|
||||
;;;###autoload (autoload 'magit-push-implicitly "magit-push" nil t)
|
||||
(transient-define-suffix magit-push-implicitly (args)
|
||||
"Push somewhere without using an explicit refspec.
|
||||
|
||||
This command simply runs \"git push -v [ARGS]\". ARGS are the
|
||||
@@ -273,9 +280,13 @@ these Git variables: `push.default', `remote.pushDefault',
|
||||
`branch.<branch>.pushRemote', `branch.<branch>.remote',
|
||||
`branch.<branch>.merge', and `remote.<remote>.push'.
|
||||
|
||||
The function `magit-push-implicitly--desc' attempts to predict
|
||||
what this command will do. The value it returns is displayed in
|
||||
the popup buffer."
|
||||
If you add this suffix to a transient prefix without explicitly
|
||||
specifying the description, then an attempt is made to predict
|
||||
what this command will do. For example:
|
||||
|
||||
(transient-insert-suffix 'magit-push \"p\"
|
||||
'(\"i\" magit-push-implicitly))"
|
||||
:description 'magit-push-implicitly--desc
|
||||
(interactive (list (magit-push-arguments)))
|
||||
(run-hooks 'magit-credential-hook)
|
||||
(magit-run-git-async "push" "-v" args))
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-reflog.el --- inspect ref history -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2010-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2010-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-refs.el --- listing references -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2010-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2010-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -334,12 +334,10 @@ Type \\[magit-reset] to reset `HEAD' to the commit at point.
|
||||
(magit-show-refs-arguments magit-prefix-use-buffer-arguments))
|
||||
["Arguments"
|
||||
(magit-for-each-ref:--contains)
|
||||
("=m" "Merged" "--merged=" magit-transient-read-revision)
|
||||
("-M" "Merged" "--merged=" magit-transient-read-revision)
|
||||
("-m" "Merged to HEAD" "--merged")
|
||||
("-M" "Merged to master" "--merged=master")
|
||||
("=n" "Not merged" "--no-merged=" magit-transient-read-revision)
|
||||
("-N" "Not merged" "--no-merged=" magit-transient-read-revision)
|
||||
("-n" "Not merged to HEAD" "--no-merged")
|
||||
("-N" "Not merged to master" "--no-merged=master")
|
||||
(magit-for-each-ref:--sort)]
|
||||
["Actions"
|
||||
("y" "Show refs, comparing them with HEAD" magit-show-refs-head)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-remote.el --- transfer Git commits -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2008-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2008-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -332,16 +332,18 @@ Delete the symbolic-ref \"refs/remotes/<remote>/HEAD\"."
|
||||
(defun magit--select-push-remote (prompt-suffix)
|
||||
(let* ((branch (or (magit-get-current-branch)
|
||||
(user-error "No branch is checked out")))
|
||||
(remote (magit-get-push-remote branch)))
|
||||
(remote (magit-get-push-remote branch))
|
||||
(changed nil))
|
||||
(when (or current-prefix-arg
|
||||
(not remote)
|
||||
(not (member remote (magit-list-remotes))))
|
||||
(setq changed t)
|
||||
(setq remote
|
||||
(magit-read-remote (format "Set %s and %s"
|
||||
(magit--push-remote-variable)
|
||||
prompt-suffix)))
|
||||
(setf (magit-get (magit--push-remote-variable branch)) remote))
|
||||
(list branch remote)))
|
||||
(list branch remote changed)))
|
||||
|
||||
;;; _
|
||||
(provide 'magit-remote)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-repos.el --- listing repositories -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2010-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2010-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -222,9 +222,9 @@ By default this indicates whether there are uncommitted changes.
|
||||
- U if there is at least one unstaged file.
|
||||
- S if there is at least one staged file.
|
||||
Only one letter is shown, the first that applies."
|
||||
(-some (pcase-lambda (`(,fun . ,flag))
|
||||
(and (funcall fun) flag))
|
||||
magit-repolist-column-flag-alist))
|
||||
(seq-some (pcase-lambda (`(,fun . ,flag))
|
||||
(and (funcall fun) flag))
|
||||
magit-repolist-column-flag-alist))
|
||||
|
||||
(defun magit-repolist-column-unpulled-from-upstream (_id)
|
||||
"Insert number of upstream commits not in the current branch."
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-reset.el --- reset fuctionality -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2010-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2010-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-section.el --- Sections for read-only buffers -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2010-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2010-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -684,7 +684,7 @@ hidden."
|
||||
(cond ((and (--any-p (oref it hidden) children)
|
||||
(--any-p (oref it children) children))
|
||||
(magit-section-show-headings section))
|
||||
((-any-p 'magit-section-hidden-body children)
|
||||
((seq-some 'magit-section-hidden-body children)
|
||||
(magit-section-show-children section))
|
||||
(t
|
||||
(magit-section-hide section))))))
|
||||
@@ -696,7 +696,7 @@ hidden."
|
||||
(cond ((and (--any-p (oref it hidden) children)
|
||||
(--any-p (oref it children) children))
|
||||
(magit-section-show-headings magit-root-section))
|
||||
((-any-p 'magit-section-hidden-body children)
|
||||
((seq-some 'magit-section-hidden-body children)
|
||||
(magit-section-show-children magit-root-section))
|
||||
(t
|
||||
(mapc 'magit-section-hide children)))))
|
||||
@@ -781,7 +781,7 @@ Sections at higher levels are hidden."
|
||||
With a prefix argument show the section identity instead of the
|
||||
section lineage. This command is intended for debugging purposes."
|
||||
(interactive (list (magit-current-section) current-prefix-arg))
|
||||
(let ((str (format "#<%s %S %S %s-%s>"
|
||||
(let ((str (format "#<%s %S %S %s-%s%s>"
|
||||
(eieio-object-class section)
|
||||
(let ((val (oref section value)))
|
||||
(cond ((stringp val)
|
||||
@@ -796,6 +796,9 @@ section lineage. This command is intended for debugging purposes."
|
||||
(apply #'vector (magit-section-lineage section)))
|
||||
(when-let ((m (oref section start)))
|
||||
(marker-position m))
|
||||
(if-let ((m (oref section content)))
|
||||
(format "[%s-]" (marker-position m))
|
||||
"")
|
||||
(when-let ((m (oref section end)))
|
||||
(marker-position m)))))
|
||||
(if (called-interactively-p 'any)
|
||||
@@ -971,9 +974,9 @@ at point."
|
||||
|
||||
(defun magit-section-match-assoc (section alist)
|
||||
"Return the value associated with SECTION's type or lineage in ALIST."
|
||||
(-some (pcase-lambda (`(,key . ,val))
|
||||
(and (magit-section-match-1 key section) val))
|
||||
alist))
|
||||
(seq-some (pcase-lambda (`(,key . ,val))
|
||||
(and (magit-section-match-1 key section) val))
|
||||
alist))
|
||||
|
||||
;;; Create
|
||||
|
||||
@@ -985,14 +988,23 @@ what you are doing and are sure there is no other way.")
|
||||
(defmacro magit-insert-section (&rest args)
|
||||
"Insert a section at point.
|
||||
|
||||
TYPE is the section type, a symbol which is prefixed with the
|
||||
name of the package. (For historic reasons the types used by
|
||||
Magit and Forge do not use a package prefix.) Many commands
|
||||
that act on the current section behave differently depending
|
||||
on its type.
|
||||
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 is evaluated at runtime and should return a
|
||||
subclass. In other places a sections class is oftern referred
|
||||
to as its \"type\".
|
||||
|
||||
Optional VALUE is the value of the section, usually a string
|
||||
that is required when acting on the section.
|
||||
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 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
|
||||
appropriate package prefix. This works due to some undocumented
|
||||
kludges, which are not available to other packages.
|
||||
|
||||
When optional HIDE is non-nil collapse the section body by
|
||||
default, i.e. when first creating the section, but not when
|
||||
@@ -1018,13 +1030,7 @@ of the partially inserted section. This can happen when creating
|
||||
a section by washing Git's output and Git didn't actually output
|
||||
anything this time around.
|
||||
|
||||
For historic reasons, if a variable `magit-TYPE-section-map'
|
||||
or `forge-TYPE-section-map' exists, then use that as the
|
||||
text-property `keymap' of all text belonging to the section (but
|
||||
this may be overwritten in subsections). TYPE can also have the
|
||||
form `(eval FORM)' in which case FORM is evaluated at runtime.
|
||||
|
||||
\(fn [NAME] (TYPE &optional VALUE HIDE) &rest BODY)"
|
||||
\(fn [NAME] (CLASS &optional VALUE HIDE) &rest BODY)"
|
||||
(declare (indent defun)
|
||||
(debug ([&optional symbolp]
|
||||
(&or [("eval" form) &optional form form]
|
||||
@@ -1043,30 +1049,31 @@ form `(eval FORM)' in which case FORM is evaluated at runtime.
|
||||
(or (cdr (assq ,tp magit--section-type-alist))
|
||||
'magit-section))
|
||||
:type
|
||||
(if (class-p ,tp)
|
||||
(or (car (rassq ,tp magit--section-type-alist))
|
||||
(error "BUG: No entry for %s in %s" ,tp
|
||||
'magit--section-type-alist))
|
||||
,tp)
|
||||
(or (and (class-p ,tp)
|
||||
(car (rassq ,tp magit--section-type-alist)))
|
||||
,tp)
|
||||
:value ,(nth 1 (car args))
|
||||
:start (point-marker)
|
||||
:parent magit-insert-section--parent)))
|
||||
(oset ,s hidden
|
||||
(if-let ((value (run-hook-with-args-until-success
|
||||
'magit-section-set-visibility-hook ,s)))
|
||||
(eq value 'hide)
|
||||
(if-let ((incarnation (and magit-insert-section--oldroot
|
||||
(magit-get-section
|
||||
(magit-section-ident ,s)
|
||||
magit-insert-section--oldroot))))
|
||||
(oref incarnation hidden)
|
||||
(if-let ((value (magit-section-match-assoc
|
||||
,s magit-section-initial-visibility-alist)))
|
||||
(progn
|
||||
(when (functionp value)
|
||||
(setq value (funcall value ,s)))
|
||||
(eq value 'hide))
|
||||
,(nth 2 (car args))))))
|
||||
(let ((value (run-hook-with-args-until-success
|
||||
'magit-section-set-visibility-hook ,s)))
|
||||
(if value
|
||||
(eq value 'hide)
|
||||
(let ((incarnation (and magit-insert-section--oldroot
|
||||
(magit-get-section
|
||||
(magit-section-ident ,s)
|
||||
magit-insert-section--oldroot))))
|
||||
(if incarnation
|
||||
(oref incarnation hidden)
|
||||
(let ((value (magit-section-match-assoc
|
||||
,s magit-section-initial-visibility-alist)))
|
||||
(if value
|
||||
(progn
|
||||
(when (functionp value)
|
||||
(setq value (funcall value ,s)))
|
||||
(eq value 'hide))
|
||||
,(nth 2 (car args)))))))))
|
||||
(let ((magit-insert-section--current ,s)
|
||||
(magit-insert-section--parent ,s)
|
||||
(magit-insert-section--oldroot
|
||||
@@ -1433,7 +1440,7 @@ invisible."
|
||||
(if (oref section hidden)
|
||||
(car magit-section-visibility-indicator)
|
||||
(cdr magit-section-visibility-indicator))
|
||||
(face-foreground 'fringe))))))
|
||||
'fringe)))))
|
||||
((stringp (car-safe magit-section-visibility-indicator))
|
||||
(let ((ov (magit--overlay-at (1- eoh) 'magit-vis-indicator 'eoh)))
|
||||
(cond ((oref section hidden)
|
||||
@@ -1492,6 +1499,39 @@ invisible."
|
||||
(when (overlay-get o 'magit-vis-indicator)
|
||||
(delete-overlay o)))))
|
||||
|
||||
(defvar-local magit-section--opened-sections nil)
|
||||
|
||||
(defun magit-section--open-temporarily (beg end)
|
||||
(save-excursion
|
||||
(goto-char beg)
|
||||
(let ((section (magit-current-section)))
|
||||
(while section
|
||||
(let ((content (oref section content)))
|
||||
(if (and (magit-section-invisible-p section)
|
||||
(<= (or content (oref section start))
|
||||
beg
|
||||
(oref section end)))
|
||||
(progn
|
||||
(when content
|
||||
(magit-section-show section)
|
||||
(push section magit-section--opened-sections))
|
||||
(setq section (oref section parent)))
|
||||
(setq section nil))))))
|
||||
(or (eq search-invisible t)
|
||||
(not (isearch-range-invisible beg end))))
|
||||
|
||||
(defun isearch-clean-overlays@magit-mode (fn)
|
||||
(if (derived-mode-p 'magit-mode)
|
||||
(let ((pos (point)))
|
||||
(dolist (section magit-section--opened-sections)
|
||||
(unless (<= (oref section content) pos (oref section end))
|
||||
(magit-section-hide section)))
|
||||
(setq magit-section--opened-sections nil))
|
||||
(funcall fn)))
|
||||
|
||||
(advice-add 'isearch-clean-overlays :around
|
||||
'isearch-clean-overlays@magit-mode)
|
||||
|
||||
;;; Utilities
|
||||
|
||||
(cl-defun magit-section-selected-p (section &optional (selection nil sselection))
|
||||
@@ -1714,8 +1754,11 @@ Configuration'."
|
||||
magit--current-section-hook)))
|
||||
(unless (memq entry magit-disabled-section-inserters)
|
||||
(if (bound-and-true-p magit-refresh-verbose)
|
||||
(message " %-50s %s" entry
|
||||
(benchmark-elapse (apply entry args)))
|
||||
(let ((time (benchmark-elapse (apply entry args))))
|
||||
(message " %-50s %s %s" entry time
|
||||
(cond ((> time 0.03) "!!")
|
||||
((> time 0.01) "!")
|
||||
(t ""))))
|
||||
(apply entry args)))))))
|
||||
|
||||
(cl-defun magit--overlay-at (pos prop &optional (val nil sval) testfn)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-sequence.el --- history manipulation in Magit -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2011-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2011-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -503,6 +503,8 @@ This discards all changes made since the sequence started."
|
||||
("-k" "Keep empty commits" "--keep-empty")
|
||||
("-p" "Preserve merges" ("-p" "--preserve-merges"))
|
||||
(7 magit-merge:--strategy)
|
||||
(7 magit-merge:--strategy-option)
|
||||
(7 "=X" magit-diff:--diff-algorithm :argument "-Xdiff-algorithm=")
|
||||
("-d" "Lie about committer date" "--committer-date-is-author-date")
|
||||
("-a" "Autosquash" "--autosquash")
|
||||
("-A" "Autostash" "--autostash")
|
||||
@@ -765,7 +767,7 @@ START has to be selected from a list of recent commits."
|
||||
commit
|
||||
(cl-case action
|
||||
(edit "edit")
|
||||
(remove "# pick")
|
||||
(remove "noop\n# pick")
|
||||
(reword "reword")
|
||||
(t (error "unknown action: %s" action)))
|
||||
commit)))
|
||||
@@ -900,8 +902,12 @@ If no such sequence is in progress, do nothing."
|
||||
(when (magit-rebase-in-progress-p)
|
||||
(let* ((interactive (file-directory-p (magit-git-dir "rebase-merge")))
|
||||
(dir (if interactive "rebase-merge/" "rebase-apply/"))
|
||||
(name (-> (concat dir "head-name") magit-git-dir magit-file-line))
|
||||
(onto (-> (concat dir "onto") magit-git-dir magit-file-line))
|
||||
(name (thread-first (concat dir "head-name")
|
||||
magit-git-dir
|
||||
magit-file-line))
|
||||
(onto (thread-first (concat dir "onto")
|
||||
magit-git-dir
|
||||
magit-file-line))
|
||||
(onto (or (magit-rev-name onto name)
|
||||
(magit-rev-name onto "refs/heads/*") onto))
|
||||
(name (or (magit-rev-name name "refs/heads/*") name)))
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-stash.el --- stash support for Magit -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2008-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2008-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -33,6 +33,9 @@
|
||||
(require 'magit)
|
||||
(require 'magit-reflog)
|
||||
|
||||
;; For `magit-stash-drop'.
|
||||
(defvar helm-comp-read-use-marked)
|
||||
|
||||
;;; Options
|
||||
|
||||
(defgroup magit-stash nil
|
||||
@@ -231,7 +234,8 @@ When the region is active offer to drop all contained stashes."
|
||||
(interactive
|
||||
(list (--if-let (magit-region-values 'stash)
|
||||
(magit-confirm 'drop-stashes nil "Drop %i stashes" nil it)
|
||||
(magit-read-stash "Drop stash"))))
|
||||
(let ((helm-comp-read-use-marked t))
|
||||
(magit-read-stash "Drop stash")))))
|
||||
(dolist (stash (if (listp stash)
|
||||
(nreverse (prog1 stash (setq stash (car stash))))
|
||||
(list stash)))
|
||||
@@ -375,11 +379,12 @@ instead of \"Stashes:\"."
|
||||
(let ((verified (magit-rev-verify ref))
|
||||
(autostash
|
||||
(and (magit-rebase-in-progress-p)
|
||||
(magit-file-line
|
||||
(magit-git-dir
|
||||
(-> (if (file-directory-p (magit-git-dir "rebase-merge"))
|
||||
"rebase-merge/autostash"
|
||||
"rebase-apply/autostash")))))))
|
||||
(thread-first
|
||||
(if (file-directory-p (magit-git-dir "rebase-merge"))
|
||||
"rebase-merge/autostash"
|
||||
"rebase-apply/autostash")
|
||||
magit-git-dir
|
||||
magit-file-line))))
|
||||
(when (or autostash verified)
|
||||
(magit-insert-section (stashes ref)
|
||||
(magit-insert-heading heading)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-status.el --- the grand overview -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2010-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2010-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -317,7 +317,7 @@ also contains other useful hints.")
|
||||
(if-let ((version (let ((default-directory directory))
|
||||
(magit-git-version))))
|
||||
(if (version<= magit--minimal-git version)
|
||||
(push version magit--remotes-using-recent-git)
|
||||
(push remote magit--remotes-using-recent-git)
|
||||
(display-warning 'magit (format "\
|
||||
Magit requires Git >= %s, but on %s the version is %s.
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-submodule.el --- submodule support for Magit -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2011-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2011-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-subtree.el --- subtree support for Magit -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2011-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2011-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-tag.el --- tag functionality -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2010-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2010-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -29,6 +29,9 @@
|
||||
|
||||
(require 'magit)
|
||||
|
||||
;; For `magit-tag-delete'.
|
||||
(defvar helm-comp-read-use-marked)
|
||||
|
||||
;;;###autoload (autoload 'magit-tag "magit" nil t)
|
||||
(transient-define-prefix magit-tag ()
|
||||
"Create or delete a tag."
|
||||
@@ -78,7 +81,8 @@ defaulting to the tag at point.
|
||||
\n(git tag -d TAGS)"
|
||||
(interactive (list (--if-let (magit-region-values 'tag)
|
||||
(magit-confirm t nil "Delete %i tags" nil it)
|
||||
(magit-read-tag "Delete tag" t))))
|
||||
(let ((helm-comp-read-use-marked t))
|
||||
(magit-read-tag "Delete tag" t)))))
|
||||
(magit-run-git "tag" "-d" tags))
|
||||
|
||||
;;;###autoload
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-transient.el --- support for transients -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2008-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2008-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-utils.el --- various utilities -*- lexical-binding: t; coding: utf-8 -*-
|
||||
|
||||
;; Copyright (C) 2010-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2010-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -100,10 +100,12 @@ alphabetical order, depending on your version of Ivy."
|
||||
(forge-browse-pullreq nil t)
|
||||
(forge-edit-topic-title nil t)
|
||||
(forge-edit-topic-state nil t)
|
||||
(forge-edit-topic-milestone nil t)
|
||||
(forge-edit-topic-labels nil t)
|
||||
(forge-edit-topic-marks nil t)
|
||||
(forge-edit-topic-assignees nil t)
|
||||
(forge-edit-topic-review-requests nil t)
|
||||
(forge-edit-topic-note nil t)
|
||||
(forge-pull-pullreq nil t)
|
||||
(forge-visit-issue nil t)
|
||||
(forge-visit-pullreq nil t))
|
||||
@@ -145,18 +147,33 @@ The value has the form ((COMMAND nil|PROMPT DEFAULT)...).
|
||||
(const :tag "use default without confirmation" t)))))
|
||||
|
||||
(defconst magit--confirm-actions
|
||||
'((const reverse) (const discard)
|
||||
(const rename) (const resurrect)
|
||||
(const untrack) (const trash)
|
||||
(const delete) (const abort-rebase)
|
||||
(const abort-merge) (const merge-dirty)
|
||||
(const drop-stashes) (const reset-bisect)
|
||||
(const kill-process) (const delete-unmerged-branch)
|
||||
(const delete-pr-branch) (const remove-modules)
|
||||
(const stage-all-changes) (const unstage-all-changes)
|
||||
'((const discard)
|
||||
(const reverse)
|
||||
(const stage-all-changes)
|
||||
(const unstage-all-changes)
|
||||
(const delete)
|
||||
(const trash)
|
||||
(const resurrect)
|
||||
(const untrack)
|
||||
(const rename)
|
||||
(const reset-bisect)
|
||||
(const abort-rebase)
|
||||
(const abort-merge)
|
||||
(const merge-dirty)
|
||||
(const delete-unmerged-branch)
|
||||
(const delete-pr-remote)
|
||||
(const drop-stashes)
|
||||
(const set-and-push)
|
||||
(const amend-published)
|
||||
(const rebase-published)
|
||||
(const edit-published)
|
||||
(const remove-modules)
|
||||
(const remove-dirty-modules)
|
||||
(const trash-module-gitdirs)
|
||||
(const kill-process)
|
||||
(const safe-with-wip)))
|
||||
|
||||
(defcustom magit-no-confirm nil
|
||||
(defcustom magit-no-confirm '(set-and-push)
|
||||
"A list of symbols for actions Magit should not confirm, or t.
|
||||
|
||||
Many potentially dangerous commands by default ask the user for
|
||||
@@ -239,6 +256,15 @@ References:
|
||||
This action only concerns the deletion of multiple stashes at
|
||||
once.
|
||||
|
||||
Publishing:
|
||||
|
||||
`set-and-push' When pushing to the upstream or the 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 configured to disallow fixing such mistakes, then
|
||||
that can be quite embarrassing and annoying.
|
||||
|
||||
Edit published history:
|
||||
|
||||
Without adding these symbols here, you will be warned before
|
||||
@@ -400,7 +426,9 @@ and delay of your graphical environment or operating system."
|
||||
;;; User Input
|
||||
|
||||
(defvar helm-completion-in-region-default-sort-fn)
|
||||
(defvar helm-crm-default-separator)
|
||||
(defvar ivy-sort-functions-alist)
|
||||
(defvar ivy-sort-matches-functions-alist)
|
||||
|
||||
(defvar magit-completing-read--silent-default nil)
|
||||
|
||||
@@ -474,7 +502,8 @@ acts similarly to `completing-read', except for the following:
|
||||
predicate
|
||||
require-match initial-input hist def)))
|
||||
(setq this-command command)
|
||||
(if (string= reply "")
|
||||
;; Note: Avoid `string=' to support `helm-comp-read-use-marked'.
|
||||
(if (equal reply "")
|
||||
(if require-match
|
||||
(user-error "Nothing selected")
|
||||
nil)
|
||||
@@ -521,6 +550,8 @@ into a list."
|
||||
(minibuffer-completion-table #'crm--collection-fn)
|
||||
(minibuffer-completion-confirm t)
|
||||
(helm-completion-in-region-default-sort-fn nil)
|
||||
(helm-crm-default-separator nil)
|
||||
(ivy-sort-matches-functions-alist nil)
|
||||
(input
|
||||
(cl-letf (((symbol-function 'completion-pcm--all-completions)
|
||||
#'magit-completion-pcm--all-completions))
|
||||
@@ -555,6 +586,7 @@ to nil."
|
||||
crm-local-must-match-map
|
||||
crm-local-completion-map))
|
||||
(helm-completion-in-region-default-sort-fn nil)
|
||||
(ivy-sort-matches-functions-alist nil)
|
||||
;; If the user enters empty input, `read-from-minibuffer'
|
||||
;; returns the empty string, not DEF.
|
||||
(input (read-from-minibuffer
|
||||
@@ -813,49 +845,36 @@ Unless optional argument KEEP-EMPTY-LINES is t, trim all empty lines."
|
||||
"Set the header-line using STRING.
|
||||
Propertize STRING with the `magit-header-line'. If the `face'
|
||||
property of any part of STRING is already set, then that takes
|
||||
precedence. Also pad the left and right sides of STRING so that
|
||||
it aligns with the text area."
|
||||
precedence. Also pad the left side of STRING so that it aligns
|
||||
with the text area."
|
||||
(setq header-line-format
|
||||
(concat
|
||||
(propertize " " 'display '(space :align-to 0))
|
||||
string
|
||||
(propertize " " 'display
|
||||
`(space :width
|
||||
(+ left-fringe
|
||||
left-margin
|
||||
,@(and (eq (car (window-current-scroll-bars))
|
||||
'left)
|
||||
'(scroll-bar)))))))
|
||||
(magit--add-face-text-property 0 (1- (length header-line-format))
|
||||
'magit-header-line t header-line-format))
|
||||
(concat (propertize " " 'display '(space :align-to 0))
|
||||
string)))
|
||||
|
||||
(defun magit-face-property-all (face string)
|
||||
"Return non-nil if FACE is present in all of STRING."
|
||||
(cl-loop for pos = 0 then (next-single-property-change
|
||||
pos 'font-lock-face string)
|
||||
unless pos
|
||||
return t
|
||||
for current = (get-text-property pos 'font-lock-face string)
|
||||
unless (if (consp current)
|
||||
(memq face current)
|
||||
(eq face current))
|
||||
return nil))
|
||||
(catch 'missing
|
||||
(let ((pos 0))
|
||||
(while (setq pos (next-single-property-change pos 'font-lock-face string))
|
||||
(let ((val (get-text-property pos 'font-lock-face string)))
|
||||
(unless (if (consp val)
|
||||
(memq face val)
|
||||
(eq face val))
|
||||
(throw 'missing nil))))
|
||||
(not pos))))
|
||||
|
||||
(defun magit--add-face-text-property (beg end face &optional append object)
|
||||
"Like `add-face-text-property' but for `font-lock-face'."
|
||||
(cl-loop for pos = (next-single-property-change
|
||||
beg 'font-lock-face object end)
|
||||
for current = (get-text-property beg 'font-lock-face object)
|
||||
for newface = (if (listp current)
|
||||
(if append
|
||||
(append current (list face))
|
||||
(cons face current))
|
||||
(if append
|
||||
(list current face)
|
||||
(list face current)))
|
||||
do (progn (put-text-property beg pos 'font-lock-face newface object)
|
||||
(setq beg pos))
|
||||
while (< beg end)))
|
||||
(while (< beg end)
|
||||
(let* ((pos (next-single-property-change beg 'font-lock-face object end))
|
||||
(val (get-text-property beg 'font-lock-face object))
|
||||
(val (if (listp val) val (list val))))
|
||||
(put-text-property beg pos 'font-lock-face
|
||||
(if append
|
||||
(append val (list face))
|
||||
(cons face val))
|
||||
object)
|
||||
(setq beg pos))))
|
||||
|
||||
(defun magit--propertize-face (string face)
|
||||
(propertize string 'face face 'font-lock-face face))
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-version.el --- the Magit version you are using
|
||||
|
||||
(setq magit-version "20200627.806")
|
||||
(setq magit-version "20210105.1030")
|
||||
|
||||
(provide 'migit-version)
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-wip.el --- commit snapshots to work-in-progress refs -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2010-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2010-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -107,6 +107,7 @@ is used as `branch-ref'."
|
||||
|
||||
;;; Modes
|
||||
|
||||
;;;###autoload
|
||||
(define-minor-mode magit-wip-mode
|
||||
"Save uncommitted changes to work-in-progress refs.
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit-worktree.el --- worktree support -*- lexical-binding: t -*-
|
||||
|
||||
;; Copyright (C) 2010-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2010-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -162,7 +162,10 @@ If there is only one worktree, then insert nothing."
|
||||
(pcase-lambda (`(,path ,barep ,commit ,branch))
|
||||
(cons (cond
|
||||
(branch (propertize
|
||||
branch 'font-lock-face 'magit-branch-local))
|
||||
branch 'font-lock-face
|
||||
(if (equal branch (magit-get-current-branch))
|
||||
'magit-branch-current
|
||||
'magit-branch-local)))
|
||||
(commit (propertize (magit-rev-abbrev commit)
|
||||
'font-lock-face 'magit-hash))
|
||||
(barep "(bare)"))
|
||||
@@ -172,7 +175,7 @@ If there is only one worktree, then insert nothing."
|
||||
(pcase-dolist (`(,head . ,path) cols)
|
||||
(magit-insert-section (worktree path)
|
||||
(insert head)
|
||||
(indent-to align)
|
||||
(insert (make-string (- align (length head)) ?\s))
|
||||
(insert (let ((r (file-relative-name path))
|
||||
(a (abbreviate-file-name path)))
|
||||
(if (< (string-width r) (string-width a)) r a)))
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;;; magit.el --- A Git porcelain inside Emacs -*- lexical-binding: t; coding: utf-8 -*-
|
||||
|
||||
;; Copyright (C) 2008-2020 The Magit Project Contributors
|
||||
;; Copyright (C) 2008-2021 The Magit Project Contributors
|
||||
;;
|
||||
;; You should have received a copy of the AUTHORS.md file which
|
||||
;; lists all contributors. If not, see http://magit.vc/authors.
|
||||
@@ -219,11 +219,75 @@ and/or `magit-branch-remote-head'."
|
||||
"Face for filenames."
|
||||
:group 'magit-faces)
|
||||
|
||||
;;; Global Bindings
|
||||
|
||||
;;;###autoload
|
||||
(define-obsolete-variable-alias 'global-magit-file-mode
|
||||
'magit-define-global-key-bindings "Magit 3.0.0")
|
||||
|
||||
;;;###autoload
|
||||
(defcustom magit-define-global-key-bindings t
|
||||
"Whether to bind some Magit commands in the global keymap.
|
||||
|
||||
If this variable is non-nil, then the following bindings may
|
||||
be added to the global keymap. The default is t.
|
||||
|
||||
key binding
|
||||
--- -------
|
||||
C-x g magit-status
|
||||
C-x M-g magit-dispatch
|
||||
C-c M-g magit-file-dispatch
|
||||
|
||||
These bindings may be added when `after-init-hook' is called.
|
||||
Each binding is added if and only if at that time no other key
|
||||
is bound to the same command and no other command is bound to
|
||||
the same key. In other words we try to avoid adding bindings
|
||||
that are unnecessary, as well as bindings that conflict with
|
||||
other bindings.
|
||||
|
||||
Adding the above bindings is delayed until `after-init-hook'
|
||||
is called to allow users to set the variable anywhere in their
|
||||
init file (without having to make sure to do so before `magit'
|
||||
is loaded or autoloaded) and to increase the likelihood that
|
||||
all the potentially conflicting user bindings have already
|
||||
been added.
|
||||
|
||||
Setting this variable after the hook has already been called
|
||||
has no effect.
|
||||
|
||||
We recommend that you bind \"C-c g\" instead of \"C-c M-g\" to
|
||||
`magit-file-dispatch'. The former is a much better binding
|
||||
but the \"C-c <letter>\" namespace is strictly reserved for
|
||||
users; preventing Magit from using it by default.
|
||||
|
||||
Also see info node `(magit)Commands for Buffers Visiting Files'."
|
||||
:package-version '(magit . "3.0.0")
|
||||
:group 'magit-essentials
|
||||
:type 'boolean)
|
||||
|
||||
;;;###autoload
|
||||
(progn
|
||||
(defun magit-maybe-define-global-key-bindings ()
|
||||
(when magit-define-global-key-bindings
|
||||
(let ((map (current-global-map)))
|
||||
(dolist (elt '(("C-x g" . magit-status)
|
||||
("C-x M-g" . magit-dispatch)
|
||||
("C-c M-g" . magit-file-dispatch)))
|
||||
(let ((key (kbd (car elt)))
|
||||
(def (cdr elt)))
|
||||
(unless (or (lookup-key map key)
|
||||
(where-is-internal def (make-sparse-keymap) t))
|
||||
(define-key map key def)))))))
|
||||
(if after-init-time
|
||||
(magit-maybe-define-global-key-bindings)
|
||||
(add-hook 'after-init-hook 'magit-maybe-define-global-key-bindings t)))
|
||||
|
||||
;;; Dispatch Popup
|
||||
|
||||
;;;###autoload (autoload 'magit-dispatch "magit" nil t)
|
||||
(transient-define-prefix magit-dispatch ()
|
||||
"Invoke a Magit command from a list of available commands."
|
||||
:info-manual "(magit)Top"
|
||||
["Transient and dwim commands"
|
||||
[("A" "Apply" magit-cherry-pick)
|
||||
("b" "Branch" magit-branch)
|
||||
@@ -425,7 +489,8 @@ and Emacs to it."
|
||||
(ignore-errors (delete-file static)))
|
||||
(setq magit-version
|
||||
(let ((default-directory topdir))
|
||||
(magit-git-string "describe" "--tags" "--dirty")))))
|
||||
(magit-git-string "describe"
|
||||
"--tags" "--dirty" "--always")))))
|
||||
(progn
|
||||
(push 'static debug)
|
||||
(when (and static (file-exists-p static))
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
This is magit.info, produced by makeinfo version 6.5 from magit.texi.
|
||||
|
||||
Copyright (C) 2015-2020 Jonas Bernoulli <jonas@bernoul.li>
|
||||
Copyright (C) 2015-2021 Jonas Bernoulli <jonas@bernoul.li>
|
||||
|
||||
You can redistribute this document and/or modify it under the terms
|
||||
of the GNU General Public License as published by the Free Software
|
||||
@@ -20,170 +20,172 @@ END-INFO-DIR-ENTRY
|
||||
|
||||
Indirect:
|
||||
magit.info-1: 754
|
||||
magit.info-2: 301032
|
||||
magit.info-2: 301793
|
||||
|
||||
Tag Table:
|
||||
(Indirect)
|
||||
Node: Top754
|
||||
Node: Introduction6464
|
||||
Node: Installation11187
|
||||
Node: Installing from Melpa11517
|
||||
Node: Installing from the Git Repository12590
|
||||
Node: Post-Installation Tasks14938
|
||||
Node: Getting Started16223
|
||||
Node: Interface Concepts21672
|
||||
Node: Modes and Buffers22033
|
||||
Node: Switching Buffers23782
|
||||
Node: Naming Buffers28533
|
||||
Node: Quitting Windows31840
|
||||
Node: Automatic Refreshing of Magit Buffers33586
|
||||
Node: Automatic Saving of File-Visiting Buffers36438
|
||||
Node: Automatic Reverting of File-Visiting Buffers37623
|
||||
Node: Risk of Reverting Automatically42618
|
||||
Node: Sections45000
|
||||
Node: Section Movement45926
|
||||
Node: Section Visibility50836
|
||||
Node: Section Hooks56913
|
||||
Node: Section Types and Values59320
|
||||
Node: Section Options60623
|
||||
Node: Transient Commands61095
|
||||
Node: Transient Arguments and Buffer Variables62332
|
||||
Node: Completion Confirmation and the Selection69350
|
||||
Node: Action Confirmation69794
|
||||
Node: Completion and Confirmation77144
|
||||
Node: The Selection80330
|
||||
Node: The hunk-internal region83229
|
||||
Node: Support for Completion Frameworks84318
|
||||
Node: Additional Completion Options89225
|
||||
Node: Running Git89824
|
||||
Node: Viewing Git Output90097
|
||||
Node: Git Process Status91230
|
||||
Node: Running Git Manually92195
|
||||
Node: Git Executable94665
|
||||
Node: Global Git Arguments96947
|
||||
Node: Inspecting97753
|
||||
Node: Status Buffer98910
|
||||
Node: Status Sections102900
|
||||
Node: Status Header Sections108452
|
||||
Node: Status Module Sections111082
|
||||
Node: Status Options113587
|
||||
Node: Repository List115056
|
||||
Node: Logging118094
|
||||
Node: Refreshing Logs120657
|
||||
Node: Log Buffer122103
|
||||
Node: Log Margin125959
|
||||
Node: Select from Log129138
|
||||
Node: Reflog131363
|
||||
Node: Cherries133020
|
||||
Node: Diffing134868
|
||||
Node: Refreshing Diffs137949
|
||||
Node: Commands Available in Diffs141528
|
||||
Node: Diff Options144064
|
||||
Node: Revision Buffer149102
|
||||
Node: Ediffing152432
|
||||
Node: References Buffer156080
|
||||
Node: References Sections166600
|
||||
Node: Bisecting167461
|
||||
Node: Visiting Files and Blobs169274
|
||||
Node: General-Purpose Visit Commands169744
|
||||
Node: Visiting Files and Blobs from a Diff170700
|
||||
Node: Blaming174159
|
||||
Node: Manipulating180722
|
||||
Node: Creating Repository181064
|
||||
Node: Cloning Repository181619
|
||||
Node: Staging and Unstaging187024
|
||||
Node: Staging from File-Visiting Buffers191107
|
||||
Node: Applying192275
|
||||
Node: Committing194168
|
||||
Node: Initiating a Commit194751
|
||||
Node: Editing Commit Messages198136
|
||||
Node: Using the Revision Stack200939
|
||||
Node: Commit Pseudo Headers203990
|
||||
Node: Commit Mode and Hooks205326
|
||||
Node: Commit Message Conventions208264
|
||||
Node: Branching210392
|
||||
Node: The Two Remotes210618
|
||||
Node: Branch Commands213271
|
||||
Node: Branch Git Variables225652
|
||||
Node: Auxiliary Branch Commands231043
|
||||
Node: Merging232161
|
||||
Node: Resolving Conflicts236169
|
||||
Node: Rebasing241170
|
||||
Node: Editing Rebase Sequences246029
|
||||
Node: Information About In-Progress Rebase250357
|
||||
Ref: Information About In-Progress Rebase-Footnote-1259239
|
||||
Node: Cherry Picking259835
|
||||
Node: Reverting264166
|
||||
Node: Resetting265615
|
||||
Node: Stashing267481
|
||||
Node: Transferring272182
|
||||
Node: Remotes272404
|
||||
Node: Remote Commands272556
|
||||
Node: Remote Git Variables276637
|
||||
Node: Fetching277916
|
||||
Node: Pulling280403
|
||||
Node: Pushing281449
|
||||
Node: Plain Patches284919
|
||||
Node: Maildir Patches286410
|
||||
Node: Miscellaneous287924
|
||||
Node: Tagging288240
|
||||
Node: Notes290157
|
||||
Node: Submodules292529
|
||||
Node: Listing Submodules292747
|
||||
Node: Submodule Transient294675
|
||||
Node: Subtree297197
|
||||
Node: Worktree299173
|
||||
Node: Common Commands301032
|
||||
Node: Wip Modes303079
|
||||
Node: Wip Graph308012
|
||||
Node: Legacy Wip Modes310326
|
||||
Node: Minor Mode for Buffers Visiting Files313221
|
||||
Node: Minor Mode for Buffers Visiting Blobs320322
|
||||
Node: Customizing321135
|
||||
Node: Per-Repository Configuration322731
|
||||
Node: Essential Settings324986
|
||||
Node: Safety325310
|
||||
Node: Performance327071
|
||||
Node: Microsoft Windows Performance334214
|
||||
Node: MacOS Performance335405
|
||||
Ref: MacOS Performance-Footnote-1336420
|
||||
Node: Plumbing336502
|
||||
Node: Calling Git337331
|
||||
Node: Getting a Value from Git338856
|
||||
Node: Calling Git for Effect341942
|
||||
Node: Section Plumbing348464
|
||||
Node: Creating Sections348692
|
||||
Node: Section Selection352592
|
||||
Node: Matching Sections354391
|
||||
Node: Refreshing Buffers360364
|
||||
Node: Conventions363512
|
||||
Node: Theming Faces363704
|
||||
Node: FAQ371819
|
||||
Node: FAQ - How to ...?372261
|
||||
Node: How to show git's output?372646
|
||||
Node: How to install the gitman info manual?373400
|
||||
Node: How to show diffs for gpg-encrypted files?374370
|
||||
Node: How does branching and pushing work?374966
|
||||
Node: Can Magit be used as ediff-version-control-package?375329
|
||||
Node: Should I disable VC?377347
|
||||
Node: FAQ - Issues and Errors377965
|
||||
Node: Magit is slow378861
|
||||
Node: I changed several thousand files at once and now Magit is unusable379075
|
||||
Node: I am having problems committing379804
|
||||
Node: I am using MS Windows and cannot push with Magit380285
|
||||
Node: I am using OS X and SOMETHING works in shell but not in Magit380902
|
||||
Node: Expanding a file to show the diff causes it to disappear381733
|
||||
Node: Point is wrong in the COMMIT_EDITMSG buffer382314
|
||||
Node: The mode-line information isn't always up-to-date383360
|
||||
Node: A branch and tag sharing the same name breaks SOMETHING384423
|
||||
Node: My Git hooks work on the command-line but not inside Magit385309
|
||||
Node: git-commit-mode isn't used when committing from the command-line386155
|
||||
Node: Point ends up inside invisible text when jumping to a file-visiting buffer388422
|
||||
Node: Debugging Tools389220
|
||||
Node: Keystroke Index391399
|
||||
Node: Command Index425456
|
||||
Node: Function Index462554
|
||||
Node: Variable Index478906
|
||||
Node: Introduction6512
|
||||
Node: Installation11235
|
||||
Node: Installing from Melpa11565
|
||||
Node: Installing from the Git Repository12638
|
||||
Node: Post-Installation Tasks15370
|
||||
Node: Getting Started16655
|
||||
Node: Interface Concepts21895
|
||||
Node: Modes and Buffers22256
|
||||
Node: Switching Buffers24005
|
||||
Node: Naming Buffers28756
|
||||
Node: Quitting Windows32063
|
||||
Node: Automatic Refreshing of Magit Buffers33809
|
||||
Node: Automatic Saving of File-Visiting Buffers36661
|
||||
Node: Automatic Reverting of File-Visiting Buffers37846
|
||||
Node: Risk of Reverting Automatically42841
|
||||
Node: Sections45223
|
||||
Node: Section Movement46149
|
||||
Node: Section Visibility51059
|
||||
Node: Section Hooks57136
|
||||
Node: Section Types and Values59543
|
||||
Node: Section Options60846
|
||||
Node: Transient Commands61318
|
||||
Node: Transient Arguments and Buffer Variables62555
|
||||
Node: Completion Confirmation and the Selection69573
|
||||
Node: Action Confirmation70017
|
||||
Node: Completion and Confirmation77833
|
||||
Node: The Selection81019
|
||||
Node: The hunk-internal region83918
|
||||
Node: Support for Completion Frameworks85007
|
||||
Node: Additional Completion Options89914
|
||||
Node: Running Git90513
|
||||
Node: Viewing Git Output90786
|
||||
Node: Git Process Status91919
|
||||
Node: Running Git Manually92884
|
||||
Node: Git Executable95354
|
||||
Node: Global Git Arguments97636
|
||||
Node: Inspecting98442
|
||||
Node: Status Buffer99599
|
||||
Node: Status Sections103589
|
||||
Node: Status Header Sections109141
|
||||
Node: Status Module Sections111771
|
||||
Node: Status Options114276
|
||||
Node: Repository List115745
|
||||
Node: Logging118783
|
||||
Node: Refreshing Logs121344
|
||||
Node: Log Buffer122790
|
||||
Node: Log Margin126646
|
||||
Node: Select from Log129825
|
||||
Node: Reflog132050
|
||||
Node: Cherries133707
|
||||
Node: Diffing135555
|
||||
Node: Refreshing Diffs138634
|
||||
Node: Commands Available in Diffs142213
|
||||
Node: Diff Options144749
|
||||
Node: Revision Buffer149787
|
||||
Node: Ediffing153117
|
||||
Node: References Buffer156765
|
||||
Node: References Sections167285
|
||||
Node: Bisecting168146
|
||||
Node: Visiting Files and Blobs170498
|
||||
Node: General-Purpose Visit Commands170968
|
||||
Node: Visiting Files and Blobs from a Diff171924
|
||||
Node: Blaming175383
|
||||
Node: Manipulating181724
|
||||
Node: Creating Repository182066
|
||||
Node: Cloning Repository182621
|
||||
Node: Staging and Unstaging188026
|
||||
Node: Staging from File-Visiting Buffers192109
|
||||
Node: Applying193277
|
||||
Node: Committing195170
|
||||
Node: Initiating a Commit195753
|
||||
Node: Editing Commit Messages199138
|
||||
Node: Using the Revision Stack201941
|
||||
Node: Commit Pseudo Headers204992
|
||||
Node: Commit Mode and Hooks206328
|
||||
Node: Commit Message Conventions209266
|
||||
Node: Branching211394
|
||||
Node: The Two Remotes211620
|
||||
Node: Branch Commands214273
|
||||
Node: Branch Git Variables226654
|
||||
Node: Auxiliary Branch Commands232045
|
||||
Node: Merging233163
|
||||
Node: Resolving Conflicts237171
|
||||
Node: Rebasing242172
|
||||
Node: Editing Rebase Sequences247031
|
||||
Node: Information About In-Progress Rebase251359
|
||||
Ref: Information About In-Progress Rebase-Footnote-1260241
|
||||
Node: Cherry Picking260837
|
||||
Node: Reverting265168
|
||||
Node: Resetting266617
|
||||
Node: Stashing268483
|
||||
Node: Transferring273184
|
||||
Node: Remotes273406
|
||||
Node: Remote Commands273558
|
||||
Node: Remote Git Variables277639
|
||||
Node: Fetching278918
|
||||
Node: Pulling281405
|
||||
Node: Pushing282451
|
||||
Node: Plain Patches286204
|
||||
Node: Maildir Patches287695
|
||||
Node: Miscellaneous289209
|
||||
Node: Tagging289523
|
||||
Node: Notes291440
|
||||
Node: Submodules293812
|
||||
Node: Listing Submodules294030
|
||||
Node: Submodule Transient295436
|
||||
Node: Subtree297958
|
||||
Node: Worktree299934
|
||||
Node: Common Commands301793
|
||||
Node: Wip Modes303916
|
||||
Node: Wip Graph308847
|
||||
Node: Legacy Wip Modes311161
|
||||
Node: Commands for Buffers Visiting Files314056
|
||||
Node: Minor Mode for Buffers Visiting Blobs319678
|
||||
Node: Customizing320489
|
||||
Node: Per-Repository Configuration322085
|
||||
Node: Essential Settings324340
|
||||
Node: Safety324685
|
||||
Node: Performance326446
|
||||
Node: Microsoft Windows Performance333614
|
||||
Node: MacOS Performance334805
|
||||
Ref: MacOS Performance-Footnote-1335982
|
||||
Node: Default Bindings336064
|
||||
Node: Plumbing337919
|
||||
Node: Calling Git338748
|
||||
Node: Getting a Value from Git340273
|
||||
Node: Calling Git for Effect343359
|
||||
Node: Section Plumbing349881
|
||||
Node: Creating Sections350109
|
||||
Node: Section Selection354009
|
||||
Node: Matching Sections355808
|
||||
Node: Refreshing Buffers361781
|
||||
Node: Conventions364929
|
||||
Node: Theming Faces365121
|
||||
Node: FAQ373236
|
||||
Node: FAQ - How to ...?373678
|
||||
Node: How to pronounce Magit?374091
|
||||
Node: How to show git's output?374893
|
||||
Node: How to install the gitman info manual?375679
|
||||
Node: How to show diffs for gpg-encrypted files?376649
|
||||
Node: How does branching and pushing work?377245
|
||||
Node: Can Magit be used as ediff-version-control-package?377608
|
||||
Node: Should I disable VC?379626
|
||||
Node: FAQ - Issues and Errors380244
|
||||
Node: Magit is slow381140
|
||||
Node: I changed several thousand files at once and now Magit is unusable381354
|
||||
Node: I am having problems committing382083
|
||||
Node: I am using MS Windows and cannot push with Magit382564
|
||||
Node: I am using OS X and SOMETHING works in shell but not in Magit383181
|
||||
Node: Expanding a file to show the diff causes it to disappear384012
|
||||
Node: Point is wrong in the COMMIT_EDITMSG buffer384593
|
||||
Node: The mode-line information isn't always up-to-date385639
|
||||
Node: A branch and tag sharing the same name breaks SOMETHING386702
|
||||
Node: My Git hooks work on the command-line but not inside Magit387588
|
||||
Node: git-commit-mode isn't used when committing from the command-line388434
|
||||
Node: Point ends up inside invisible text when jumping to a file-visiting buffer390705
|
||||
Node: Debugging Tools391503
|
||||
Node: Keystroke Index393682
|
||||
Node: Command Index427788
|
||||
Node: Function Index464927
|
||||
Node: Variable Index481198
|
||||
|
||||
End Tag Table
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
This is magit.info, produced by makeinfo version 6.5 from magit.texi.
|
||||
|
||||
Copyright (C) 2015-2020 Jonas Bernoulli <jonas@bernoul.li>
|
||||
Copyright (C) 2015-2021 Jonas Bernoulli <jonas@bernoul.li>
|
||||
|
||||
You can redistribute this document and/or modify it under the terms
|
||||
of the GNU General Public License as published by the Free Software
|
||||
@@ -31,9 +31,9 @@ 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 2.90.1 (v2.90.1-996-g6b88fab39+1).
|
||||
This manual is for Magit version 2.90.1 (v2.90.1-1138-gd583ea35d+1).
|
||||
|
||||
Copyright (C) 2015-2020 Jonas Bernoulli <jonas@bernoul.li>
|
||||
Copyright (C) 2015-2021 Jonas Bernoulli <jonas@bernoul.li>
|
||||
|
||||
You can redistribute this document and/or modify it under the terms
|
||||
of the GNU General Public License as published by the Free Software
|
||||
@@ -237,7 +237,7 @@ Miscellaneous
|
||||
* Worktree::
|
||||
* Common Commands::
|
||||
* Wip Modes::
|
||||
* Minor Mode for Buffers Visiting Files::
|
||||
* Commands for Buffers Visiting Files::
|
||||
* Minor Mode for Buffers Visiting Blobs::
|
||||
|
||||
Submodules
|
||||
@@ -261,6 +261,7 @@ Essential Settings
|
||||
|
||||
* Safety::
|
||||
* Performance::
|
||||
* Default Bindings::
|
||||
|
||||
|
||||
Plumbing
|
||||
@@ -295,6 +296,7 @@ FAQ
|
||||
|
||||
FAQ - How to ...?
|
||||
|
||||
* How to pronounce Magit?::
|
||||
* How to show git's output?::
|
||||
* How to install the gitman info manual?::
|
||||
* How to show diffs for gpg-encrypted files?::
|
||||
@@ -480,10 +482,10 @@ Melpa or at ‘/path/to/magit/../<package>’, then you have to tell ‘make’
|
||||
where to find them. To do so create the file ‘/path/to/magit/config.mk’
|
||||
with the following content before running ‘make’:
|
||||
|
||||
LOAD_PATH = -L /path/to/magit/lisp
|
||||
LOAD_PATH += -L /path/to/dash
|
||||
LOAD_PATH += -L /path/to/transient
|
||||
LOAD_PATH += -L /path/to/with-editor
|
||||
LOAD_PATH = -L ~/.emacs.d/site-lisp/magit/lisp
|
||||
LOAD_PATH += -L ~/.emacs.d/site-lisp/dash
|
||||
LOAD_PATH += -L ~/.emacs.d/site-lisp/transient/lisp
|
||||
LOAD_PATH += -L ~/.emacs.d/site-lisp/with-editor
|
||||
|
||||
Finally add this to your init file:
|
||||
|
||||
@@ -495,6 +497,13 @@ with the following content before running ‘make’:
|
||||
(add-to-list 'Info-directory-list
|
||||
"~/.emacs.d/site-lisp/magit/Documentation/"))
|
||||
|
||||
Of course if you installed the dependencies manually as well, then
|
||||
you have to tell Emacs about them too, by prefixing the above with:
|
||||
|
||||
(add-to-list 'load-path "~/.emacs.d/site-lisp/dash")
|
||||
(add-to-list 'load-path "~/.emacs.d/site-lisp/transient/lisp")
|
||||
(add-to-list 'load-path "~/.emacs.d/site-lisp/with-editor")
|
||||
|
||||
Note that you have to add the ‘lisp’ subdirectory to the ‘load-path’,
|
||||
not the top-level of the repository, and that elements of ‘load-path’
|
||||
should not end with a slash, while those of ‘Info-directory-list’
|
||||
@@ -569,11 +578,8 @@ tutorial. Alternatively you can use an existing local repository, but
|
||||
if you do that, then you should commit all uncommitted changes before
|
||||
proceeding.
|
||||
|
||||
To display information about the current Git repository, type ‘M-x
|
||||
magit-status RET’. You will be using this command a lot, and should
|
||||
therefore give it a global key binding. This is what we recommend:
|
||||
|
||||
(global-set-key (kbd "C-x g") 'magit-status)
|
||||
Type ‘C-x g’ to display information about the current Git repository
|
||||
in a dedicated buffer, called the status buffer.
|
||||
|
||||
Most Magit commands are commonly invoked from the status buffer. It
|
||||
can be considered the primary interface for interacting with Git using
|
||||
@@ -624,7 +630,7 @@ that invokes/sets it. Do not worry about this for now. We want to
|
||||
create a "normal" commit, which is done by typing ‘c’ again.
|
||||
|
||||
Now two new buffers appear. One is for writing the commit message,
|
||||
the other shows a diff with the changes that you are about to committed.
|
||||
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
|
||||
@@ -635,27 +641,24 @@ local branch onto the remote configured as the push-remote. (If the
|
||||
push-remote is not configured yet, then you would first be prompted for
|
||||
the remote to push to.)
|
||||
|
||||
So far we have mentioned the commit, push, and log transient prefix
|
||||
commands. These are probably among the transients you will be using the
|
||||
most, but many others exist. To show a transient that lists all other
|
||||
transients (as well as the various apply commands and some other
|
||||
essential commands), type ‘h’. Try a few.
|
||||
So far we have mentioned the commit, push, and log menu commands.
|
||||
These are probably among the menus you will be using the most, but many
|
||||
others exist. To show a menu that lists all other menus (as well as the
|
||||
various apply commands and some other essential commands), type ‘h’.
|
||||
Try a few. (Such menus are also called "transient prefix commands" or
|
||||
just "transients".)
|
||||
|
||||
The key bindings in that transient correspond to the bindings in
|
||||
Magit buffers, including but not limited to the status buffer. So you
|
||||
could type ‘h d’ to bring up the diff transient, but once you remember
|
||||
that "d" stands for "diff", you would usually do so by just typing ‘d’.
|
||||
But this "prefix of prefixes" is useful even once you have memorized all
|
||||
the bindings, as it can provide easy access to Magit commands from
|
||||
non-Magit buffers. You should create a global key binding for this
|
||||
command too:
|
||||
The key bindings in that menu correspond to the bindings in Magit
|
||||
buffers, including but not limited to the status buffer. So you could
|
||||
type ‘h d’ to bring up the diff menu, but once you remember that "d"
|
||||
stands for "diff", you would usually do so by just typing ‘d’. But this
|
||||
"prefix of prefixes" is useful even once you have memorized all the
|
||||
bindings, as it can provide easy access to Magit commands from non-Magit
|
||||
buffers. The global binding is ‘C-x M-g’.
|
||||
|
||||
(global-set-key (kbd "C-x M-g") 'magit-dispatch)
|
||||
|
||||
In the same vein, you might also want to enable
|
||||
‘global-magit-file-mode’ to get some more Magit key bindings in regular
|
||||
file-visiting buffers (see *note Minor Mode for Buffers Visiting
|
||||
Files::).
|
||||
In file visiting buffers ‘C-c M-g’ brings up a similar menu featuring
|
||||
commands that act on just the visited file, see *note Commands for
|
||||
Buffers Visiting Files::.
|
||||
|
||||
It is not necessary that you do so now, but if you stick with Magit,
|
||||
then it is highly recommended that you read the next section too.
|
||||
@@ -1905,6 +1908,16 @@ telling Magit to ask fewer questions.
|
||||
default (or selecting another). This action only
|
||||
concerns the deletion of multiple stashes at once.
|
||||
|
||||
• Publishing:
|
||||
|
||||
‘set-and-push’ When pushing to the upstream or the 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 configured to disallow fixing
|
||||
such mistakes, then that can be quite embarrassing and
|
||||
annoying.
|
||||
|
||||
• Edit published history:
|
||||
|
||||
Without adding these symbols here, you will be warned before
|
||||
@@ -3066,7 +3079,7 @@ Reflog::.
|
||||
Show log for all references and ‘HEAD’.
|
||||
|
||||
Two additional commands that show the log for the file or blob that
|
||||
is being visited in the current buffer exists, see *note Minor Mode for
|
||||
is being visited in the current buffer exists, see *note Commands for
|
||||
Buffers Visiting Files::. The command ‘magit-cherry’ also shows a log,
|
||||
see *note Cherries::.
|
||||
|
||||
@@ -3544,7 +3557,7 @@ another buffer:
|
||||
Show all diffs of a stash in a buffer.
|
||||
|
||||
Two additional commands that show the diff for the file or blob that
|
||||
is being visited in the current buffer exists, see *note Minor Mode for
|
||||
is being visited in the current buffer exists, see *note Commands for
|
||||
Buffers Visiting Files::.
|
||||
|
||||
* Menu:
|
||||
@@ -4336,8 +4349,11 @@ following suffix commands.
|
||||
Start a bisect session.
|
||||
|
||||
Bisecting a bug means to find the commit that introduced it. This
|
||||
command starts such a bisect session by asking for a known good and
|
||||
a bad commit.
|
||||
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
|
||||
conceptually more fitting than "bad" and "good", but the infix
|
||||
arguments to do so are disabled by default.
|
||||
|
||||
‘B s’ (‘magit-bisect-run’)
|
||||
|
||||
@@ -4356,6 +4372,13 @@ following suffix commands.
|
||||
Mark the current commit as good. Use this after you have asserted
|
||||
that the commit does not contain the bug in question.
|
||||
|
||||
‘B m’ (‘magit-bisect-mark’)
|
||||
|
||||
Mark the current commit with one of the bisect terms. This command
|
||||
provides an alternative to ‘magit-bisect-bad’ and
|
||||
‘magit-bisect-good’ and is useful when using terms other than "bad"
|
||||
and "good". This suffix is disabled by default.
|
||||
|
||||
‘B k’ (‘magit-bisect-skip’)
|
||||
|
||||
Skip the current commit. Use this if for some reason the current
|
||||
@@ -4505,10 +4528,7 @@ File: magit.info, Node: Blaming, Prev: Visiting Files and Blobs, Up: Inspecti
|
||||
Also see *note (gitman)git-blame::.
|
||||
|
||||
To start blaming invoke the ‘magit-file-dispatch’ transient prefix
|
||||
command by pressing ‘C-c M-g’. (This is only the default binding and
|
||||
the recommended binding is ‘C-c g’. Also neither binding may be
|
||||
available if you disabled ‘global-magit-file-mode’. Also see *note
|
||||
Minor Mode for Buffers Visiting Files::.)
|
||||
command by pressing ‘C-c M-g’.
|
||||
|
||||
The blaming suffix commands can be invoked from the dispatch
|
||||
transient. However if you want to set an infix argument, then you have
|
||||
@@ -7314,6 +7334,13 @@ add them to the transient.
|
||||
‘branch.<branch>.remote’, ‘branch.<branch>.merge’, and
|
||||
‘remote.<remote>.push’.
|
||||
|
||||
If you add this suffix to a transient prefix without explicitly
|
||||
specifying the description, then an attempt is made to predict what
|
||||
this command will do. For example:
|
||||
|
||||
(transient-insert-suffix 'magit-push \"p\"
|
||||
'(\"i\" magit-push-implicitly))"
|
||||
|
||||
-- Command: magit-push-to-remote remote args
|
||||
|
||||
This command pushes to the remote REMOTE without using an explicit
|
||||
@@ -7427,7 +7454,7 @@ File: magit.info, Node: Miscellaneous, Next: Customizing, Prev: Transferring,
|
||||
* Worktree::
|
||||
* Common Commands::
|
||||
* Wip Modes::
|
||||
* Minor Mode for Buffers Visiting Files::
|
||||
* Commands for Buffers Visiting Files::
|
||||
* Minor Mode for Buffers Visiting Blobs::
|
||||
|
||||
|
||||
@@ -7575,7 +7602,7 @@ File: magit.info, Node: Listing Submodules, Next: Submodule Transient, Up: Su
|
||||
The command ‘magit-list-submodules’ displays a list of the current
|
||||
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-submodules’ to the hook
|
||||
the super-repository by adding ‘magit-insert-modules’ to the hook
|
||||
‘magit-status-sections-hook’ as described in *note Status Module
|
||||
Sections::.
|
||||
|
||||
@@ -7601,17 +7628,6 @@ Sections::.
|
||||
It has to return a string to be inserted or nil. PROPS is an alist
|
||||
that supports the keys ‘:right-align’ and ‘:pad-right’.
|
||||
|
||||
-- Function: magit-insert-submodules
|
||||
|
||||
Insert sections for all submodules. For each section insert the
|
||||
path, the branch, and the output of ‘git describe --tags’, or,
|
||||
failing that, the abbreviated HEAD commit hash.
|
||||
|
||||
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.
|
||||
|
||||
|
||||
File: magit.info, Node: Submodule Transient, Prev: Listing Submodules, Up: Submodules
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
This is magit.info, produced by makeinfo version 6.5 from magit.texi.
|
||||
|
||||
Copyright (C) 2015-2020 Jonas Bernoulli <jonas@bernoul.li>
|
||||
Copyright (C) 2015-2021 Jonas Bernoulli <jonas@bernoul.li>
|
||||
|
||||
You can redistribute this document and/or modify it under the terms
|
||||
of the GNU General Public License as published by the Free Software
|
||||
@@ -41,8 +41,9 @@ beside the ones below, but these didn’t fit well anywhere else.
|
||||
When the region is active, this command saves that to the
|
||||
‘kill-ring’, like ‘kill-ring-save’ would, instead of behaving as
|
||||
described above. If a prefix argument is used and the region is
|
||||
within a hunk, it strips the outer diff marker column before saving
|
||||
the text.
|
||||
within a hunk, then it strips the diff marker column and keeps only
|
||||
either the added or removed lines, depending on the sign of the
|
||||
prefix argument.
|
||||
|
||||
‘M-w’ (‘magit-copy-buffer-revision’)
|
||||
|
||||
@@ -64,7 +65,7 @@ of these commands behave like ‘kill-ring-save’ instead of as described
|
||||
above.
|
||||
|
||||
|
||||
File: magit.info, Node: Wip Modes, Next: Minor Mode for Buffers Visiting Files, Prev: Common Commands, Up: Miscellaneous
|
||||
File: magit.info, Node: Wip Modes, Next: Commands for Buffers Visiting Files, Prev: Common Commands, Up: Miscellaneous
|
||||
|
||||
8.7 Wip Modes
|
||||
=============
|
||||
@@ -308,55 +309,22 @@ making changes that could cause the loss of earlier changes.
|
||||
Mode-line lighter for ‘magit-wip-initial-backup-mode’.
|
||||
|
||||
|
||||
File: magit.info, Node: Minor Mode for Buffers Visiting Files, Next: Minor Mode for Buffers Visiting Blobs, Prev: Wip Modes, Up: Miscellaneous
|
||||
File: magit.info, Node: Commands for Buffers Visiting Files, Next: Minor Mode for Buffers Visiting Blobs, Prev: Wip Modes, Up: Miscellaneous
|
||||
|
||||
8.8 Minor Mode for Buffers Visiting Files
|
||||
=========================================
|
||||
8.8 Commands for Buffers Visiting Files
|
||||
=======================================
|
||||
|
||||
The minor-mode ‘magit-file-mode’ enables certain Magit features in
|
||||
file-visiting buffers belonging to a Git repository. The globalized
|
||||
variant ‘global-magit-file-mode’ enables the local mode in all such
|
||||
buffers. It is enabled by default. Currently the local mode only
|
||||
establishes a few key bindings, but this might be extended in the
|
||||
future.
|
||||
Magit defines a few global key bindings unless the user sets
|
||||
‘magit-define-global-key-bindings’ to ‘nil’. This includes binding ‘C-c
|
||||
M-g’ to ‘magit-file-dispatch’. ‘C-c g’ would be a much better binding
|
||||
but the ‘C-c <letter>’ namespace is reserved for users, meaning that
|
||||
packages are not allowed to use it. If you want to use ‘C-c g’, then
|
||||
you have to add that binding yourself. Also see *note Default
|
||||
Bindings:: and *note (elisp)Key Binding Conventions::.
|
||||
|
||||
-- User Option: global-magit-file-mode
|
||||
If you want a better binding, you have to add it yourself:
|
||||
|
||||
Whether to establish certain Magit key bindings in all
|
||||
file-visiting buffers belonging to any Git repository. This is
|
||||
enabled by default. This globalized mode turns on the local
|
||||
minor-mode ‘magit-file-mode’ in all suitable buffers.
|
||||
|
||||
-- Variable: magit-file-mode-map
|
||||
|
||||
This keymap is used by the local minor-mode ‘magit-file-mode’ and
|
||||
establishes the key bindings described below.
|
||||
|
||||
Note that the default binding for ‘magit-file-dispatch’ is very
|
||||
cumbersome to use and that we recommend that you add a better
|
||||
binding.
|
||||
|
||||
Instead of ‘C-c M-g’ I would have preferred to use ‘C-c g’ because
|
||||
(1) it is similar to ‘C-x g’ (the recommended global binding for
|
||||
‘~magit-status’), (2) we cannot use ‘C-c C-g’ because we have been
|
||||
recommending that that be bound to ‘magit-dispatch’ for a long
|
||||
time, (3) we cannot use ‘C-x C-g’ because that is a convenient way
|
||||
of aborting the incomplete key sequence ‘C-x’, and most importantly
|
||||
(4) it would make it much easier to type the next key (a suffix
|
||||
binding) because most of those are letters.
|
||||
|
||||
For example ‘C-c g b’ is much easier to type than ‘C-c M-g b’. For
|
||||
suffix bindings that use uppercase letters, the default is just
|
||||
horrible—having to use e.g. ‘C-c M-g B’ (‘Control+c Meta+g
|
||||
Shift+b’) would drive anyone up the walls (or to Vim).
|
||||
|
||||
However ‘C-c LETTER’ bindings are reserved for users (see *note
|
||||
(elisp)Key Binding Conventions::). Packages are forbidden from
|
||||
using those. Doing so anyway is considered heresy. Therefore if
|
||||
you want a better binding, you have to add it yourself:
|
||||
|
||||
(define-key magit-file-mode-map
|
||||
(kbd "C-c g") 'magit-file-dispatch)
|
||||
(global-set-key (kbd "C-c g") 'magit-file-dispatch)
|
||||
|
||||
The key bindings shown below assume that you have not improved the
|
||||
binding for ‘magit-file-dispatch’.
|
||||
@@ -366,6 +334,9 @@ binding for ‘magit-file-dispatch’.
|
||||
This transient prefix command binds the following suffix commands
|
||||
and displays them in a temporary buffer until a suffix is invoked.
|
||||
|
||||
When invoked in a buffer that does not visit a file, then it falls
|
||||
back to regular ‘magit-dispatch’.
|
||||
|
||||
‘C-c M-g s’ (‘magit-stage-file’)
|
||||
|
||||
Stage all changes to the file being visited in the current buffer.
|
||||
@@ -484,7 +455,7 @@ leave edit mode (‘C-g’). Also see *note (transient)Enabling and
|
||||
Disabling Suffixes::.
|
||||
|
||||
|
||||
File: magit.info, Node: Minor Mode for Buffers Visiting Blobs, Prev: Minor Mode for Buffers Visiting Files, Up: Miscellaneous
|
||||
File: magit.info, Node: Minor Mode for Buffers Visiting Blobs, Prev: Commands for Buffers Visiting Files, Up: Miscellaneous
|
||||
|
||||
8.9 Minor Mode for Buffers Visiting Blobs
|
||||
=========================================
|
||||
@@ -620,6 +591,7 @@ might want to customize, for safety and/or performance reasons.
|
||||
|
||||
* Safety::
|
||||
* Performance::
|
||||
* Default Bindings::
|
||||
|
||||
|
||||
File: magit.info, Node: Safety, Next: Performance, Up: Essential Settings
|
||||
@@ -659,7 +631,7 @@ to make an informed decision you should see *note Risk of Reverting
|
||||
Automatically::.
|
||||
|
||||
|
||||
File: magit.info, Node: Performance, Prev: Safety, Up: Essential Settings
|
||||
File: magit.info, Node: Performance, Next: Default Bindings, Prev: Safety, Up: Essential Settings
|
||||
|
||||
9.2.2 Performance
|
||||
-----------------
|
||||
@@ -862,15 +834,61 @@ more information.
|
||||
|
||||
On Catalina, and potentially other macOS releases, there may be a
|
||||
performance problem where any action takes 20 times longer on Darwin
|
||||
than on Linux. This can be fixed by setting ‘magit-git-executable’ to
|
||||
the absolute path of the ‘git’ executable, instead of relying on
|
||||
resolving the ‘$PATH’.
|
||||
than on Linux. This can be worked around by setting
|
||||
‘magit-git-executable’ to the absolute path of the ‘git’ executable,
|
||||
instead of relying on resolving the ‘$PATH’. You should not do that if
|
||||
you want to use Magit on remote machines using Tramp and if ‘git’ is not
|
||||
installed in the same location on those machines.
|
||||
|
||||
---------- Footnotes ----------
|
||||
|
||||
(1)
|
||||
<https://lists.gnu.org/archive/html/bug-gnu-emacs/2017-04/msg00201.html>
|
||||
|
||||
|
||||
File: magit.info, Node: Default Bindings, Prev: Performance, Up: Essential Settings
|
||||
|
||||
9.2.3 Default Bindings
|
||||
----------------------
|
||||
|
||||
-- User Option: magit-define-global-key-bindings
|
||||
|
||||
This option controls whether some Magit commands are automatically
|
||||
bound in the global keymap even before Magit is used for the first
|
||||
time in the current session.
|
||||
|
||||
If this variable is non-nil, which it is by default, then the
|
||||
following bindings may be added to the global keymap.
|
||||
|
||||
‘C-x g’ ‘magit-status’
|
||||
‘C-x M-g’ ‘magit-dispatch’
|
||||
‘C-c M-g’ ‘magit-file-dispatch’
|
||||
|
||||
These bindings may be added when ‘after-init-hook’ is called. Each
|
||||
binding is added if and only if at that time no other key is bound
|
||||
to the same command and no other command is bound to the same key.
|
||||
In other words we try to avoid adding bindings that are
|
||||
unnecessary, as well as bindings that conflict with other bindings.
|
||||
|
||||
Adding the above bindings is delayed until ‘after-init-hook’ is
|
||||
called to allow users to set the variable anywhere in their init
|
||||
file (without having to make sure to do so before ‘magit’ is loaded
|
||||
or autoloaded) and to increase the likelihood that all the
|
||||
potentially conflicting user bindings have already been added.
|
||||
|
||||
Setting this variable after the hook has already been called has no
|
||||
effect.
|
||||
|
||||
We recommend that you bind ‘C-c g’ instead of ‘C-c M-g’ to
|
||||
‘magit-file-dispatch’. The former is a much better binding but the
|
||||
‘C-c <letter>’ namespace is strictly reserved for users; preventing
|
||||
Magit from using it by default.
|
||||
|
||||
(global-set-key (kbd "C-c g") 'magit-file-dispatch)
|
||||
|
||||
Also see *note Commands for Buffers Visiting Files:: and *note
|
||||
(elisp)Key Binding Conventions::.
|
||||
|
||||
|
||||
File: magit.info, Node: Plumbing, Next: FAQ, Prev: Customizing, Up: Top
|
||||
|
||||
@@ -1697,6 +1715,7 @@ A.1 FAQ - How to ...?
|
||||
|
||||
* Menu:
|
||||
|
||||
* How to pronounce Magit?::
|
||||
* How to show git's output?::
|
||||
* How to install the gitman info manual?::
|
||||
* How to show diffs for gpg-encrypted files?::
|
||||
@@ -1705,9 +1724,31 @@ A.1 FAQ - How to ...?
|
||||
* Should I disable VC?::
|
||||
|
||||
|
||||
File: magit.info, Node: How to show git's output?, Next: How to install the gitman info manual?, Up: FAQ - How to ...?
|
||||
File: magit.info, Node: How to pronounce Magit?, Next: How to show git's output?, Up: FAQ - How to ...?
|
||||
|
||||
A.1.1 How to show git’s output?
|
||||
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
|
||||
sense to pronounce Magit like magic, while taking into account that C
|
||||
and T do not sound the same.
|
||||
|
||||
The German "Magie" is not pronounced the same as the English "magic",
|
||||
so if you speak German then you can use the above rational to justify
|
||||
using the former pronunciation; ‘Mag{ie => it}’.
|
||||
|
||||
You can also choose to use the former pronunciation just because you
|
||||
like it better.
|
||||
|
||||
Also see <https://magit.vc/assets/videos/magic.mp4>. Also see
|
||||
<https://emacs.stackexchange.com/questions/13696>.
|
||||
|
||||
|
||||
File: magit.info, Node: How to show git's output?, Next: How to install the gitman info manual?, Prev: How to pronounce Magit?, Up: FAQ - How to ...?
|
||||
|
||||
A.1.2 How to show git’s output?
|
||||
-------------------------------
|
||||
|
||||
To show the output of recently run git commands, press ‘$’ (or, if that
|
||||
@@ -1724,7 +1765,7 @@ debugging purposes, it’s possible to do so anyway by setting
|
||||
|
||||
File: magit.info, Node: How to install the gitman info manual?, Next: How to show diffs for gpg-encrypted files?, Prev: How to show git's output?, Up: FAQ - How to ...?
|
||||
|
||||
A.1.2 How to install the gitman info manual?
|
||||
A.1.3 How to install the gitman info manual?
|
||||
--------------------------------------------
|
||||
|
||||
Git’s manpages can be exported as an info manual called ‘gitman’.
|
||||
@@ -1745,7 +1786,7 @@ one of the supported packages ‘man’ or ‘woman’, e.g.:
|
||||
|
||||
File: magit.info, Node: How to show diffs for gpg-encrypted files?, Next: How does branching and pushing work?, Prev: How to install the gitman info manual?, Up: FAQ - How to ...?
|
||||
|
||||
A.1.3 How to show diffs for gpg-encrypted files?
|
||||
A.1.4 How to show diffs for gpg-encrypted files?
|
||||
------------------------------------------------
|
||||
|
||||
Git supports showing diffs for encrypted files, but has to be told to do
|
||||
@@ -1758,7 +1799,7 @@ affects the diffs displayed inside Magit.
|
||||
|
||||
File: magit.info, Node: How does branching and pushing work?, Next: Can Magit be used as ediff-version-control-package?, Prev: How to show diffs for gpg-encrypted files?, Up: FAQ - How to ...?
|
||||
|
||||
A.1.4 How does branching and pushing work?
|
||||
A.1.5 How does branching and pushing work?
|
||||
------------------------------------------
|
||||
|
||||
Please see *note Branching:: and
|
||||
@@ -1767,7 +1808,7 @@ Please see *note Branching:: and
|
||||
|
||||
File: magit.info, Node: Can Magit be used as ediff-version-control-package?, Next: Should I disable VC?, Prev: How does branching and pushing work?, Up: FAQ - How to ...?
|
||||
|
||||
A.1.5 Can Magit be used as ‘ediff-version-control-package’?
|
||||
A.1.6 Can Magit be used as ‘ediff-version-control-package’?
|
||||
-----------------------------------------------------------
|
||||
|
||||
No, it cannot. For that to work the functions ‘ediff-magit-internal’
|
||||
@@ -1801,7 +1842,7 @@ only shows yet-to-be resolved conflicts.
|
||||
|
||||
File: magit.info, Node: Should I disable VC?, Prev: Can Magit be used as ediff-version-control-package?, Up: FAQ - How to ...?
|
||||
|
||||
A.1.6 Should I disable VC?
|
||||
A.1.7 Should I disable VC?
|
||||
--------------------------
|
||||
|
||||
If you don’t use VC (the built-in version control interface) then you
|
||||
@@ -2025,8 +2066,9 @@ to try. Personally I use:
|
||||
$ EDITOR="emacsclient --alternate-editor emacs" git commit
|
||||
|
||||
This will actually end up using ‘emacs’, not ‘emacsclient’. If you
|
||||
do this, then can still edit the commit message but ‘git-commit-mode’
|
||||
won’t be used and you have to exit ‘emacs’ to finish the process.
|
||||
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
|
||||
the process.
|
||||
|
||||
Tautology ahead. If you want to be able to use ‘emacsclient’ to
|
||||
connect to a running ‘emacs’ instance, even though no ‘emacs’ instance
|
||||
@@ -2163,27 +2205,28 @@ Appendix C Keystroke Index
|
||||
* A s: Cherry Picking. (line 76)
|
||||
* A s <1>: Cherry Picking. (line 94)
|
||||
* B: Bisecting. (line 8)
|
||||
* b: Blaming. (line 105)
|
||||
* b: Blaming. (line 102)
|
||||
* b <1>: Branch Commands. (line 12)
|
||||
* b <2>: Editing Rebase Sequences.
|
||||
(line 85)
|
||||
* B B: Bisecting. (line 16)
|
||||
* B b: Bisecting. (line 31)
|
||||
* B b: Bisecting. (line 34)
|
||||
* b b: Branch Commands. (line 49)
|
||||
* b C: Branch Commands. (line 29)
|
||||
* b c: Branch Commands. (line 67)
|
||||
* B g: Bisecting. (line 36)
|
||||
* B k: Bisecting. (line 41)
|
||||
* B g: Bisecting. (line 39)
|
||||
* B k: Bisecting. (line 51)
|
||||
* b k: Branch Commands. (line 147)
|
||||
* b l: Branch Commands. (line 74)
|
||||
* B m: Bisecting. (line 44)
|
||||
* b n: Branch Commands. (line 57)
|
||||
* B r: Bisecting. (line 47)
|
||||
* B r: Bisecting. (line 57)
|
||||
* b r: Branch Commands. (line 153)
|
||||
* B s: Bisecting. (line 24)
|
||||
* B s: Bisecting. (line 27)
|
||||
* b s: Branch Commands. (line 97)
|
||||
* b S: Branch Commands. (line 125)
|
||||
* b x: Branch Commands. (line 131)
|
||||
* c: Blaming. (line 138)
|
||||
* c: Blaming. (line 135)
|
||||
* C: Cloning Repository. (line 20)
|
||||
* c <1>: Initiating a Commit. (line 8)
|
||||
* c <2>: Editing Rebase Sequences.
|
||||
@@ -2245,39 +2288,39 @@ Appendix C Keystroke Index
|
||||
(line 29)
|
||||
* C-c C-w: Using the Revision Stack.
|
||||
(line 6)
|
||||
* C-c M-g: Minor Mode for Buffers Visiting Files.
|
||||
(line 54)
|
||||
* C-c M-g B: Blaming. (line 21)
|
||||
* C-c M-g b: Blaming. (line 32)
|
||||
* C-c M-g B <1>: Minor Mode for Buffers Visiting Files.
|
||||
(line 123)
|
||||
* C-c M-g B b: Blaming. (line 33)
|
||||
* C-c M-g B e: Blaming. (line 67)
|
||||
* C-c M-g B f: Blaming. (line 58)
|
||||
* C-c M-g B r: Blaming. (line 49)
|
||||
* C-c M-g c: Minor Mode for Buffers Visiting Files.
|
||||
(line 68)
|
||||
* C-c M-g D: Minor Mode for Buffers Visiting Files.
|
||||
(line 75)
|
||||
* C-c M-g d: Minor Mode for Buffers Visiting Files.
|
||||
(line 86)
|
||||
* C-c M-g e: Blaming. (line 66)
|
||||
* C-c M-g e <1>: Minor Mode for Buffers Visiting Files.
|
||||
(line 136)
|
||||
* C-c M-g f: Blaming. (line 57)
|
||||
* C-c M-g L: Minor Mode for Buffers Visiting Files.
|
||||
(line 96)
|
||||
* C-c M-g l: Minor Mode for Buffers Visiting Files.
|
||||
(line 107)
|
||||
* C-c M-g p: Minor Mode for Buffers Visiting Files.
|
||||
(line 146)
|
||||
* C-c M-g r: Blaming. (line 48)
|
||||
* C-c M-g s: Minor Mode for Buffers Visiting Files.
|
||||
(line 59)
|
||||
* C-c M-g t: Minor Mode for Buffers Visiting Files.
|
||||
(line 114)
|
||||
* C-c M-g u: Minor Mode for Buffers Visiting Files.
|
||||
(line 63)
|
||||
* C-c M-g: Commands for Buffers Visiting Files.
|
||||
(line 21)
|
||||
* C-c M-g B: Blaming. (line 18)
|
||||
* C-c M-g b: Blaming. (line 29)
|
||||
* C-c M-g B <1>: Commands for Buffers Visiting Files.
|
||||
(line 93)
|
||||
* C-c M-g B b: Blaming. (line 30)
|
||||
* C-c M-g B e: Blaming. (line 64)
|
||||
* C-c M-g B f: Blaming. (line 55)
|
||||
* C-c M-g B r: Blaming. (line 46)
|
||||
* C-c M-g c: Commands for Buffers Visiting Files.
|
||||
(line 38)
|
||||
* C-c M-g D: Commands for Buffers Visiting Files.
|
||||
(line 45)
|
||||
* C-c M-g d: Commands for Buffers Visiting Files.
|
||||
(line 56)
|
||||
* C-c M-g e: Blaming. (line 63)
|
||||
* C-c M-g e <1>: Commands for Buffers Visiting Files.
|
||||
(line 106)
|
||||
* C-c M-g f: Blaming. (line 54)
|
||||
* C-c M-g L: Commands for Buffers Visiting Files.
|
||||
(line 66)
|
||||
* C-c M-g l: Commands for Buffers Visiting Files.
|
||||
(line 77)
|
||||
* C-c M-g p: Commands for Buffers Visiting Files.
|
||||
(line 116)
|
||||
* C-c M-g r: Blaming. (line 45)
|
||||
* C-c M-g s: Commands for Buffers Visiting Files.
|
||||
(line 29)
|
||||
* C-c M-g t: Commands for Buffers Visiting Files.
|
||||
(line 84)
|
||||
* C-c M-g u: Commands for Buffers Visiting Files.
|
||||
(line 33)
|
||||
* C-c M-i: Commit Pseudo Headers.
|
||||
(line 42)
|
||||
* C-c M-s: Editing Commit Messages.
|
||||
@@ -2306,7 +2349,7 @@ Appendix C Keystroke Index
|
||||
* DEL: Log Buffer. (line 45)
|
||||
* DEL <1>: Commands Available in Diffs.
|
||||
(line 60)
|
||||
* DEL <2>: Blaming. (line 92)
|
||||
* DEL <2>: Blaming. (line 89)
|
||||
* DEL <3>: Editing Rebase Sequences.
|
||||
(line 28)
|
||||
* e: Ediffing. (line 9)
|
||||
@@ -2403,8 +2446,8 @@ Appendix C Keystroke Index
|
||||
(line 38)
|
||||
* M-p <2>: Editing Rebase Sequences.
|
||||
(line 43)
|
||||
* M-w: Blaming. (line 130)
|
||||
* M-w <1>: Common Commands. (line 27)
|
||||
* M-w: Blaming. (line 127)
|
||||
* M-w <1>: Common Commands. (line 28)
|
||||
* M-x magit-debug-git-executable: Git Executable. (line 45)
|
||||
* M-x magit-debug-git-executable <1>: Debugging Tools. (line 36)
|
||||
* M-x magit-describe-section-briefly: Section Types and Values.
|
||||
@@ -2431,8 +2474,8 @@ Appendix C Keystroke Index
|
||||
* Mt: Editing Rebase Sequences.
|
||||
(line 132)
|
||||
* n: Section Movement. (line 16)
|
||||
* n <1>: Blaming. (line 109)
|
||||
* N: Blaming. (line 113)
|
||||
* n <1>: Blaming. (line 106)
|
||||
* N: Blaming. (line 110)
|
||||
* n <2>: Editing Rebase Sequences.
|
||||
(line 39)
|
||||
* n <3>: Minor Mode for Buffers Visiting Blobs.
|
||||
@@ -2456,8 +2499,8 @@ Appendix C Keystroke Index
|
||||
* o s: Submodule Transient. (line 44)
|
||||
* o u: Submodule Transient. (line 39)
|
||||
* p: Section Movement. (line 10)
|
||||
* p <1>: Blaming. (line 117)
|
||||
* P: Blaming. (line 121)
|
||||
* p <1>: Blaming. (line 114)
|
||||
* P: Blaming. (line 118)
|
||||
* p <2>: Editing Rebase Sequences.
|
||||
(line 35)
|
||||
* P <1>: Pushing. (line 9)
|
||||
@@ -2474,7 +2517,7 @@ Appendix C Keystroke Index
|
||||
* P u: Pushing. (line 23)
|
||||
* q: Quitting Windows. (line 6)
|
||||
* q <1>: Log Buffer. (line 14)
|
||||
* q <2>: Blaming. (line 125)
|
||||
* q <2>: Blaming. (line 122)
|
||||
* q <3>: Minor Mode for Buffers Visiting Blobs.
|
||||
(line 20)
|
||||
* r: Rebasing. (line 9)
|
||||
@@ -2496,7 +2539,7 @@ Appendix C Keystroke Index
|
||||
* RET: References Buffer. (line 181)
|
||||
* RET <1>: Visiting Files and Blobs from a Diff.
|
||||
(line 8)
|
||||
* RET <2>: Blaming. (line 78)
|
||||
* RET <2>: Blaming. (line 75)
|
||||
* RET <3>: Editing Rebase Sequences.
|
||||
(line 16)
|
||||
* s: Staging and Unstaging.
|
||||
@@ -2509,7 +2552,7 @@ Appendix C Keystroke Index
|
||||
* SPC: Log Buffer. (line 35)
|
||||
* SPC <1>: Commands Available in Diffs.
|
||||
(line 56)
|
||||
* SPC <2>: Blaming. (line 82)
|
||||
* SPC <2>: Blaming. (line 79)
|
||||
* SPC <3>: Editing Rebase Sequences.
|
||||
(line 21)
|
||||
* t: Editing Rebase Sequences.
|
||||
@@ -2666,35 +2709,36 @@ Appendix D Command Index
|
||||
* magit-am-skip: Maildir Patches. (line 38)
|
||||
* magit-apply: Applying. (line 33)
|
||||
* magit-bisect: Bisecting. (line 8)
|
||||
* magit-bisect-bad: Bisecting. (line 31)
|
||||
* magit-bisect-good: Bisecting. (line 36)
|
||||
* magit-bisect-reset: Bisecting. (line 47)
|
||||
* magit-bisect-run: Bisecting. (line 24)
|
||||
* magit-bisect-skip: Bisecting. (line 41)
|
||||
* magit-bisect-bad: Bisecting. (line 34)
|
||||
* magit-bisect-good: Bisecting. (line 39)
|
||||
* magit-bisect-mark: Bisecting. (line 44)
|
||||
* magit-bisect-reset: Bisecting. (line 57)
|
||||
* magit-bisect-run: Bisecting. (line 27)
|
||||
* magit-bisect-skip: Bisecting. (line 51)
|
||||
* magit-bisect-start: Bisecting. (line 16)
|
||||
* magit-blame: Blaming. (line 21)
|
||||
* magit-blame <1>: Blaming. (line 105)
|
||||
* magit-blame <2>: Minor Mode for Buffers Visiting Files.
|
||||
(line 123)
|
||||
* magit-blame-addition: Blaming. (line 32)
|
||||
* magit-blame-addition <1>: Blaming. (line 33)
|
||||
* magit-blame-copy-hash: Blaming. (line 130)
|
||||
* magit-blame-cycle-style: Blaming. (line 138)
|
||||
* magit-blame-echo: Blaming. (line 66)
|
||||
* magit-blame-echo <1>: Blaming. (line 67)
|
||||
* magit-blame-next-chunk: Blaming. (line 109)
|
||||
* magit-blame-next-chunk-same-commit: Blaming. (line 113)
|
||||
* magit-blame-previous-chunk: Blaming. (line 117)
|
||||
* magit-blame-previous-chunk-same-commit: Blaming. (line 121)
|
||||
* magit-blame-quit: Blaming. (line 125)
|
||||
* magit-blame-removal: Blaming. (line 48)
|
||||
* magit-blame-removal <1>: Blaming. (line 49)
|
||||
* magit-blame-reverse: Blaming. (line 57)
|
||||
* magit-blame-reverse <1>: Blaming. (line 58)
|
||||
* magit-blame: Blaming. (line 18)
|
||||
* magit-blame <1>: Blaming. (line 102)
|
||||
* magit-blame <2>: Commands for Buffers Visiting Files.
|
||||
(line 93)
|
||||
* magit-blame-addition: Blaming. (line 29)
|
||||
* magit-blame-addition <1>: Blaming. (line 30)
|
||||
* magit-blame-copy-hash: Blaming. (line 127)
|
||||
* magit-blame-cycle-style: Blaming. (line 135)
|
||||
* magit-blame-echo: Blaming. (line 63)
|
||||
* magit-blame-echo <1>: Blaming. (line 64)
|
||||
* magit-blame-next-chunk: Blaming. (line 106)
|
||||
* magit-blame-next-chunk-same-commit: Blaming. (line 110)
|
||||
* magit-blame-previous-chunk: Blaming. (line 114)
|
||||
* magit-blame-previous-chunk-same-commit: Blaming. (line 118)
|
||||
* magit-blame-quit: Blaming. (line 122)
|
||||
* magit-blame-removal: Blaming. (line 45)
|
||||
* magit-blame-removal <1>: Blaming. (line 46)
|
||||
* magit-blame-reverse: Blaming. (line 54)
|
||||
* magit-blame-reverse <1>: Blaming. (line 55)
|
||||
* magit-blob-next: Minor Mode for Buffers Visiting Blobs.
|
||||
(line 16)
|
||||
* magit-blob-previous: Minor Mode for Buffers Visiting Files.
|
||||
(line 146)
|
||||
* magit-blob-previous: Commands for Buffers Visiting Files.
|
||||
(line 116)
|
||||
* magit-blob-previous <1>: Minor Mode for Buffers Visiting Blobs.
|
||||
(line 12)
|
||||
* magit-branch: Branch Commands. (line 12)
|
||||
@@ -2733,8 +2777,8 @@ Appendix D Command Index
|
||||
* magit-clone-shallow-exclude: Cloning Repository. (line 61)
|
||||
* magit-clone-shallow-since: Cloning Repository. (line 54)
|
||||
* magit-commit: Initiating a Commit. (line 8)
|
||||
* magit-commit <1>: Minor Mode for Buffers Visiting Files.
|
||||
(line 68)
|
||||
* magit-commit <1>: Commands for Buffers Visiting Files.
|
||||
(line 38)
|
||||
* magit-commit-amend: Initiating a Commit. (line 19)
|
||||
* magit-commit-augment: Initiating a Commit. (line 67)
|
||||
* magit-commit-create: Initiating a Commit. (line 14)
|
||||
@@ -2744,7 +2788,7 @@ Appendix D Command Index
|
||||
* magit-commit-instant-squash: Initiating a Commit. (line 63)
|
||||
* magit-commit-reword: Initiating a Commit. (line 33)
|
||||
* magit-commit-squash: Initiating a Commit. (line 55)
|
||||
* magit-copy-buffer-revision: Common Commands. (line 27)
|
||||
* magit-copy-buffer-revision: Common Commands. (line 28)
|
||||
* magit-copy-section-value: Common Commands. (line 10)
|
||||
* magit-cycle-margin-style: Log Margin. (line 70)
|
||||
* magit-debug-git-executable: Git Executable. (line 45)
|
||||
@@ -2753,10 +2797,10 @@ Appendix D Command Index
|
||||
(line 13)
|
||||
* magit-describe-section-briefly <1>: Matching Sections. (line 6)
|
||||
* magit-diff: Diffing. (line 21)
|
||||
* magit-diff <1>: Minor Mode for Buffers Visiting Files.
|
||||
(line 75)
|
||||
* magit-diff-buffer-file: Minor Mode for Buffers Visiting Files.
|
||||
(line 86)
|
||||
* magit-diff <1>: Commands for Buffers Visiting Files.
|
||||
(line 45)
|
||||
* magit-diff-buffer-file: Commands for Buffers Visiting Files.
|
||||
(line 56)
|
||||
* magit-diff-default-context: Refreshing Diffs. (line 73)
|
||||
* magit-diff-dwim: Diffing. (line 27)
|
||||
* magit-diff-edit-hunk-commit: Commands Available in Diffs.
|
||||
@@ -2771,9 +2815,9 @@ Appendix D Command Index
|
||||
* magit-diff-save-default-arguments: Refreshing Diffs. (line 29)
|
||||
* magit-diff-set-default-arguments: Refreshing Diffs. (line 22)
|
||||
* magit-diff-show-or-scroll-down: Log Buffer. (line 45)
|
||||
* magit-diff-show-or-scroll-down <1>: Blaming. (line 92)
|
||||
* magit-diff-show-or-scroll-down <1>: Blaming. (line 89)
|
||||
* magit-diff-show-or-scroll-up: Log Buffer. (line 35)
|
||||
* magit-diff-show-or-scroll-up <1>: Blaming. (line 82)
|
||||
* magit-diff-show-or-scroll-up <1>: Blaming. (line 79)
|
||||
* magit-diff-staged: Diffing. (line 51)
|
||||
* magit-diff-switch-range-type: Refreshing Diffs. (line 41)
|
||||
* magit-diff-toggle-file-filter: Refreshing Diffs. (line 51)
|
||||
@@ -2809,8 +2853,8 @@ Appendix D Command Index
|
||||
* magit-ediff-show-unstaged: Ediffing. (line 53)
|
||||
* magit-ediff-show-working-tree: Ediffing. (line 61)
|
||||
* magit-ediff-stage: Ediffing. (line 48)
|
||||
* magit-edit-line-commit: Minor Mode for Buffers Visiting Files.
|
||||
(line 136)
|
||||
* magit-edit-line-commit: Commands for Buffers Visiting Files.
|
||||
(line 106)
|
||||
* magit-emacs-Q-command: Debugging Tools. (line 16)
|
||||
* magit-fetch: Fetching. (line 9)
|
||||
* magit-fetch-all: Fetching. (line 50)
|
||||
@@ -2821,16 +2865,16 @@ Appendix D Command Index
|
||||
* magit-fetch-other: Fetching. (line 36)
|
||||
* magit-fetch-refspec: Fetching. (line 45)
|
||||
* magit-file-checkout: Resetting. (line 50)
|
||||
* magit-file-checkout <1>: Minor Mode for Buffers Visiting Files.
|
||||
(line 165)
|
||||
* magit-file-delete: Minor Mode for Buffers Visiting Files.
|
||||
(line 157)
|
||||
* magit-file-dispatch: Minor Mode for Buffers Visiting Files.
|
||||
(line 54)
|
||||
* magit-file-rename: Minor Mode for Buffers Visiting Files.
|
||||
(line 153)
|
||||
* magit-file-untrack: Minor Mode for Buffers Visiting Files.
|
||||
(line 161)
|
||||
* magit-file-checkout <1>: Commands for Buffers Visiting Files.
|
||||
(line 135)
|
||||
* magit-file-delete: Commands for Buffers Visiting Files.
|
||||
(line 127)
|
||||
* magit-file-dispatch: Commands for Buffers Visiting Files.
|
||||
(line 21)
|
||||
* magit-file-rename: Commands for Buffers Visiting Files.
|
||||
(line 123)
|
||||
* magit-file-untrack: Commands for Buffers Visiting Files.
|
||||
(line 131)
|
||||
* magit-find-file: General-Purpose Visit Commands.
|
||||
(line 9)
|
||||
* magit-find-file-other-frame: General-Purpose Visit Commands.
|
||||
@@ -2854,13 +2898,13 @@ Appendix D Command Index
|
||||
* magit-list-submodules: Listing Submodules. (line 13)
|
||||
* magit-list-submodules <1>: Submodule Transient. (line 54)
|
||||
* magit-log: Logging. (line 29)
|
||||
* magit-log <1>: Minor Mode for Buffers Visiting Files.
|
||||
(line 96)
|
||||
* magit-log <1>: Commands for Buffers Visiting Files.
|
||||
(line 66)
|
||||
* magit-log-all: Logging. (line 60)
|
||||
* magit-log-all-branches: Logging. (line 56)
|
||||
* magit-log-branches: Logging. (line 52)
|
||||
* magit-log-buffer-file: Minor Mode for Buffers Visiting Files.
|
||||
(line 107)
|
||||
* magit-log-buffer-file: Commands for Buffers Visiting Files.
|
||||
(line 77)
|
||||
* magit-log-bury-buffer: Log Buffer. (line 14)
|
||||
* magit-log-current: Logging. (line 35)
|
||||
* magit-log-double-commit-limit: Log Buffer. (line 61)
|
||||
@@ -2876,8 +2920,8 @@ Appendix D Command Index
|
||||
* magit-log-select-quit: Select from Log. (line 26)
|
||||
* magit-log-set-default-arguments: Refreshing Logs. (line 22)
|
||||
* magit-log-toggle-commit-limit: Log Buffer. (line 55)
|
||||
* magit-log-trace-definition: Minor Mode for Buffers Visiting Files.
|
||||
(line 114)
|
||||
* magit-log-trace-definition: Commands for Buffers Visiting Files.
|
||||
(line 84)
|
||||
* magit-margin-settings: Log Margin. (line 57)
|
||||
* magit-merge: Merging. (line 9)
|
||||
* magit-merge <1>: Merging. (line 89)
|
||||
@@ -2920,7 +2964,7 @@ Appendix D Command Index
|
||||
* magit-push-refspecs: Pushing. (line 41)
|
||||
* magit-push-tag: Pushing. (line 66)
|
||||
* magit-push-tags: Pushing. (line 58)
|
||||
* magit-push-to-remote remote args: Pushing. (line 85)
|
||||
* magit-push-to-remote remote args: Pushing. (line 92)
|
||||
* magit-rebase: Rebasing. (line 9)
|
||||
* magit-rebase-abort: Rebasing. (line 123)
|
||||
* magit-rebase-autosquash: Rebasing. (line 84)
|
||||
@@ -3010,7 +3054,7 @@ Appendix D Command Index
|
||||
* magit-shell-command-topdir: Running Git Manually.
|
||||
(line 35)
|
||||
* magit-show-commit: Diffing. (line 69)
|
||||
* magit-show-commit <1>: Blaming. (line 78)
|
||||
* magit-show-commit <1>: Blaming. (line 75)
|
||||
* magit-show-refs: References Buffer. (line 6)
|
||||
* magit-show-refs-current: References Buffer. (line 26)
|
||||
* magit-show-refs-head: References Buffer. (line 21)
|
||||
@@ -3022,8 +3066,8 @@ Appendix D Command Index
|
||||
(line 28)
|
||||
* magit-stage-file: Staging from File-Visiting Buffers.
|
||||
(line 10)
|
||||
* magit-stage-file <1>: Minor Mode for Buffers Visiting Files.
|
||||
(line 59)
|
||||
* magit-stage-file <1>: Commands for Buffers Visiting Files.
|
||||
(line 29)
|
||||
* magit-stage-modified: Staging and Unstaging.
|
||||
(line 36)
|
||||
* magit-stash: Stashing. (line 8)
|
||||
@@ -3075,8 +3119,8 @@ Appendix D Command Index
|
||||
(line 52)
|
||||
* magit-unstage-file: Staging from File-Visiting Buffers.
|
||||
(line 18)
|
||||
* magit-unstage-file <1>: Minor Mode for Buffers Visiting Files.
|
||||
(line 63)
|
||||
* magit-unstage-file <1>: Commands for Buffers Visiting Files.
|
||||
(line 33)
|
||||
* magit-version: Git Executable. (line 17)
|
||||
* magit-version <1>: Debugging Tools. (line 10)
|
||||
* magit-visit-ref: References Buffer. (line 181)
|
||||
@@ -3168,14 +3212,14 @@ Appendix E Function Index
|
||||
* magit-display-buffer-same-window-except-diff-v1: Switching Buffers.
|
||||
(line 53)
|
||||
* magit-display-buffer-traditional: Switching Buffers. (line 45)
|
||||
* magit-file-checkout: Minor Mode for Buffers Visiting Files.
|
||||
(line 165)
|
||||
* magit-file-delete: Minor Mode for Buffers Visiting Files.
|
||||
(line 157)
|
||||
* magit-file-rename: Minor Mode for Buffers Visiting Files.
|
||||
(line 153)
|
||||
* magit-file-untrack: Minor Mode for Buffers Visiting Files.
|
||||
(line 161)
|
||||
* magit-file-checkout: Commands for Buffers Visiting Files.
|
||||
(line 135)
|
||||
* magit-file-delete: Commands for Buffers Visiting Files.
|
||||
(line 127)
|
||||
* magit-file-rename: Commands for Buffers Visiting Files.
|
||||
(line 123)
|
||||
* magit-file-untrack: Commands for Buffers Visiting Files.
|
||||
(line 131)
|
||||
* magit-find-file: General-Purpose Visit Commands.
|
||||
(line 9)
|
||||
* magit-find-file-other-frame: General-Purpose Visit Commands.
|
||||
@@ -3255,7 +3299,6 @@ Appendix E Function Index
|
||||
* magit-insert-stashes: Status Sections. (line 67)
|
||||
* magit-insert-status-headers: Status Header Sections.
|
||||
(line 12)
|
||||
* magit-insert-submodules: Listing Submodules. (line 35)
|
||||
* magit-insert-tags: References Sections. (line 25)
|
||||
* magit-insert-tags-header: Status Header Sections.
|
||||
(line 56)
|
||||
@@ -3283,7 +3326,7 @@ Appendix E Function Index
|
||||
* magit-mode-quit-window: Quitting Windows. (line 34)
|
||||
* magit-mode-setup: Refreshing Buffers. (line 17)
|
||||
* magit-push-implicitly: Pushing. (line 74)
|
||||
* magit-push-to-remote: Pushing. (line 85)
|
||||
* magit-push-to-remote: Pushing. (line 92)
|
||||
* magit-region-sections: Section Selection. (line 10)
|
||||
* magit-region-values: Section Selection. (line 37)
|
||||
* magit-repolist-column-branch: Repository List. (line 44)
|
||||
@@ -3399,21 +3442,19 @@ Appendix F Variable Index
|
||||
(line 103)
|
||||
* global-auto-revert-mode: Automatic Reverting of File-Visiting Buffers.
|
||||
(line 22)
|
||||
* global-magit-file-mode: Minor Mode for Buffers Visiting Files.
|
||||
(line 13)
|
||||
* magit-auto-revert-immediately: Automatic Reverting of File-Visiting Buffers.
|
||||
(line 32)
|
||||
* magit-auto-revert-mode: Automatic Reverting of File-Visiting Buffers.
|
||||
(line 17)
|
||||
* magit-auto-revert-tracked-only: Automatic Reverting of File-Visiting Buffers.
|
||||
(line 55)
|
||||
* magit-bisect-show-graph: Bisecting. (line 55)
|
||||
* magit-blame-disable-modes: Blaming. (line 168)
|
||||
* magit-blame-echo-style: Blaming. (line 151)
|
||||
* magit-blame-goto-chunk-hook: Blaming. (line 174)
|
||||
* magit-blame-read-only: Blaming. (line 163)
|
||||
* magit-blame-styles: Blaming. (line 146)
|
||||
* magit-blame-time-format: Blaming. (line 158)
|
||||
* magit-bisect-show-graph: Bisecting. (line 65)
|
||||
* magit-blame-disable-modes: Blaming. (line 165)
|
||||
* magit-blame-echo-style: Blaming. (line 148)
|
||||
* magit-blame-goto-chunk-hook: Blaming. (line 171)
|
||||
* magit-blame-read-only: Blaming. (line 160)
|
||||
* magit-blame-styles: Blaming. (line 143)
|
||||
* magit-blame-time-format: Blaming. (line 155)
|
||||
* magit-branch-adjust-remote-upstream-alist: Branch Commands. (line 210)
|
||||
* magit-branch-direct-configure: Branch Commands. (line 20)
|
||||
* magit-branch-prefer-remote-upstream: Branch Commands. (line 165)
|
||||
@@ -3433,9 +3474,10 @@ Appendix F Variable Index
|
||||
* magit-commit-squash-confirm: Initiating a Commit. (line 88)
|
||||
* magit-completing-read-function: Support for Completion Frameworks.
|
||||
(line 27)
|
||||
* magit-define-global-key-bindings: Default Bindings. (line 6)
|
||||
* magit-diff-adjust-tab-width: Diff Options. (line 21)
|
||||
* magit-diff-buffer-file-locked: Minor Mode for Buffers Visiting Files.
|
||||
(line 91)
|
||||
* magit-diff-buffer-file-locked: Commands for Buffers Visiting Files.
|
||||
(line 61)
|
||||
* magit-diff-hide-trailing-cr-characters: Diff Options. (line 90)
|
||||
* magit-diff-highlight-hunk-region-functions: Diff Options. (line 94)
|
||||
* magit-diff-highlight-indentation: Diff Options. (line 75)
|
||||
@@ -3456,8 +3498,6 @@ Appendix F Variable Index
|
||||
* magit-ediff-dwim-show-on-hunks: Ediffing. (line 73)
|
||||
* magit-ediff-quit-hook: Ediffing. (line 88)
|
||||
* magit-ediff-show-stash-with-index: Ediffing. (line 81)
|
||||
* magit-file-mode-map: Minor Mode for Buffers Visiting Files.
|
||||
(line 20)
|
||||
* magit-generate-buffer-name-function: Naming Buffers. (line 6)
|
||||
* magit-git-debug: Viewing Git Output. (line 28)
|
||||
* magit-git-debug <1>: Getting a Value from Git.
|
||||
@@ -3469,8 +3509,8 @@ Appendix F Variable Index
|
||||
* magit-list-refs-sortby: Additional Completion Options.
|
||||
(line 6)
|
||||
* magit-log-auto-more: Log Buffer. (line 69)
|
||||
* magit-log-buffer-file-locked: Minor Mode for Buffers Visiting Files.
|
||||
(line 118)
|
||||
* magit-log-buffer-file-locked: Commands for Buffers Visiting Files.
|
||||
(line 88)
|
||||
* magit-log-margin: Log Margin. (line 12)
|
||||
* magit-log-margin-show-committer-date: Log Margin. (line 49)
|
||||
* magit-log-section-commit-count: Status Sections. (line 136)
|
||||
|
||||
Reference in New Issue
Block a user