Codebase list magit / baa1b7c
Imported Upstream version 2.6.2 Rémi Vanicat 8 years ago
16 changed file(s) with 191 addition(s) and 123 deletion(s). Raw diff Collapse all Expand all
+0
-40
Documentation/2.6.1.txt less more
0 Magit v2.6.1 Release Notes
1 ==========================
2
3 Fixes since v2.6.0
4 ------------------
5
6 * When a submodule is manually removed without staging the removal,
7 then the status buffer could no longer be updated.
8
9 * In some cases not all modified submodules were shown in the status
10 buffer.
11
12 * Visiting a blob did turn on `diff-hl-mode' if the global mode is on.
13
14 * Stash and wipref were needlessly signed if signing is enabled.
15
16 * The command `git-commit-save-message' did not strip diffs produced
17 by `git commit --verbose'.
18
19 * Diffs produced by `git commit --verbose' were not completely
20 highlighted in the commit message buffer.
21
22 * When the commit message buffer contains nothing but a single line
23 that does not end with a newline, then a warning was shown about
24 there being a non-empty second line.
25
26 * When installing from Melpa, `async-bytecomp-package-mode' was no
27 longer activated early enough.
28
29 This release also contains documentation updates, typofixes, fixes for
30 minor bugs, and other small improvements.
31
32 Authors
33 -------
34
35 14 Jonas Bernoulli
36 5 Kyle Meyer
37 1 Fritz Grabo
38 1 Ingo Lohmar
39 1 Noam Postavsky
0 Magit v2.6.2 Release Notes
1 ==========================
2
3 Changes since v2.6.1
4 --------------------
5
6 * Added new section inserter `magit-insert-submodules'. For each
7 submodule it inserts the module path and a description of its tip.
8
9 * When re-adding an already configured but for some reason unstaged
10 submodule, then `magit-submodule-add' now offers the configured
11 submodule name as default choice.
12
13 Fixes since v2.6.1
14 ------------------
15
16 * When possible `git merge (--no-commit|--edit)' perform fast-forward
17 merges, which isn't what one would expect. `magit-merge-nocommit'
18 and `magit-merge-editmsg' now work around that by always using
19 `--no-ff'.
20
21 * The command `magit-log', when called with `--patch' but without
22 `--graph', deleted the first two characters of file names in the
23 diff.
24
25 * When performing an instant fixup/squash, the rebase often failed
26 because the commit process still held the lock on `index.lock'.
27
28 * The command `magit-submodule-add' offered an invalid default choice
29 for the module path and allowed selecting a file that isn't a
30 repository.
31
32 * `git-rebase-mode' failed to prevent `save-place-mode' from having an
33 effect.
34
35 * The section inserter `magit-insert-unpulled-from-upstream-or-recent'
36 failed to insert the recent commits instead when no upstream is
37 configured.
38
39 * Two key bindings in `magit-pull-and-fetch-popup' conflicted.
40
41 * The default value for `magit-cygwin-mount-points' checked if
42 "git.exe" was a cygwin flavor of git, instead of the (possibly user
43 customized) value of `magit-git-executable'.
44
45 Authors
46 -------
47
48 21 Jonas Bernoulli
49 1 John Mastro
50 1 Kyle Meyer
51 1 Noam Postavsky
44 libraries `git-commit.el`, `magit-popup.el`, and `with-editor.el`
55 which are distributed as separate Elpa packages.
66
7 For statistics see http://magit.vc/stats/authors.html.
7 For statistics see https://magit.vc/stats/authors.html.
88
99 Names below are sorted alphabetically.
1010
6464 libraries `git-commit.el`, `magit-popup.el`, and `with-editor.el`
6565 which are distributed as separate Elpa packages.
6666
67 For statistics see http://magit.vc/stats/authors.html.
67 For statistics see https://magit.vc/stats/authors.html.
6868
6969 Names below are sorted alphabetically.
7070
270270 * I am using an Emacs release older than v24.4: I am using an Emacs release older than v244.
271271 * I am using a Git release older than v1.9.4: I am using a Git release older than v194.
272272 * I am using MS Windows and cannot push with Magit::
273 * I am using OS X and SOMETHING works in shell, but not in Magit: I am using OS X and SOMETHING works in shell but not in Magit.
273274 * How to install the gitman info manual?::
274275 * How can I show Git's output?::
275276 * Diffs contain control sequences::
276277 * Expanding a file to show the diff causes it to disappear::
277 * Point is wrong in the COMMIT@math{_EDITMSG} buffer::
278 * Can Magit be used as ediff-version-control-package?::
278 * Point is wrong in the @code{COMMIT_EDITMSG} buffer::
279 * Can Magit be used as @code{ediff-version-control-package}?::
279280 * How to show diffs for gpg-encrypted files?::
280281 * Emacs 24.5 hangs when loading Magit: Emacs 245 hangs when loading Magit.
281 * Symbol's value as function is void --some::
282 * @code{Symbol's value as function is void --some}::
282283 * Where is the branch manager::
283284 @end detailmenu
284285 @end menu
21392140 Insert sections for modules that haven't been pushed to the
21402141 push-remote yet. These sections can be expanded to show the
21412142 respective commits.
2143 @end defun
2144
2145 @defun magit-insert-submodules
2146
2147 Insert sections for all modules. For each section insert the path
2148 and the output of @code{git describe --tags}.
21422149 @end defun
21432150
21442151 @defun magit-insert-unpulled-cherries
67006707 per-repository or per-repository-class basis only. See
67016708 @ref{Per-repository configuration,Per-repository configuration}.
67026709
6703 @menu
6704 * Committing Performance::
6705 @end menu
6706
67076710 @unnumberedsubsubsec Microsoft Windows Performance
67086711
67096712 In order to update the status buffer, @code{git} has to be run a few dozen
67196722 use the latest release. Magit too tries to work around some
67206723 Windows-specific issues.
67216724
6722 But all these efforts might not be enough, forcing users to make some
6723 changes themselves. For example, according to
6724 @uref{http://stackoverflow.com/questions/4485059}, setting the following Git
6725 variables might also help:
6725 According to some sources setting the following Git variables can also
6726 help.
67266727
67276728 @example
6728 git config --global core.preloadindex true
6729 git config --global core.fscache true
6729 git config --global core.preloadindex true # default since v2.1
6730 git config --global core.fscache true # default since v2.8
67306731 git config --global gc.auto 256
67316732 @end example
67326733
67946795 actually all exist. You can do so by pruning branches which no longer
67956796 exist using @code{f-pa}.
67966797
6797 @node Committing Performance
67986798 @unnumberedsubsubsec Committing Performance
67996799
68006800 When you initiate a commit, then Magit by default automatically shows
76427642 * I am using an Emacs release older than v24.4: I am using an Emacs release older than v244.
76437643 * I am using a Git release older than v1.9.4: I am using a Git release older than v194.
76447644 * I am using MS Windows and cannot push with Magit::
7645 * I am using OS X and SOMETHING works in shell, but not in Magit: I am using OS X and SOMETHING works in shell but not in Magit.
76457646 * How to install the gitman info manual?::
76467647 * How can I show Git's output?::
76477648 * Diffs contain control sequences::
76487649 * Expanding a file to show the diff causes it to disappear::
7649 * Point is wrong in the COMMIT@math{_EDITMSG} buffer::
7650 * Can Magit be used as ediff-version-control-package?::
7650 * Point is wrong in the @code{COMMIT_EDITMSG} buffer::
7651 * Can Magit be used as @code{ediff-version-control-package}?::
76517652 * How to show diffs for gpg-encrypted files?::
76527653 * Emacs 24.5 hangs when loading Magit: Emacs 245 hangs when loading Magit.
7653 * Symbol's value as function is void --some::
7654 * @code{Symbol's value as function is void --some}::
76547655 * Where is the branch manager::
76557656 @end menu
76567657
76797680
76807681 @node Diffs are collapsed after un-/staging
76817682 @section Diffs are collapsed after un-/staging
7683
7684 This typically happens on Windows and/or large repositories where
7685 preparing diffs takes longer than @code{magit-diff-expansion-threshold}. The
7686 default is one second, try increasing it to a larger value.
76827687
76837688 Currently when one part of a Magit buffer has to be updated the whole
76847689 buffer is recreated from scratch. That obviously isn't good for
77747779
77757780 Detailed setup instructions can be found at
77767781 @uref{https://github.com/magit/magit/wiki/Pushing-with-Magit-from-Windows}.
7782
7783 @node I am using OS X and SOMETHING works in shell but not in Magit
7784 @section I am using OS X and SOMETHING works in shell, but not in Magit
7785
7786 This usually occurs because Emacs doesn't have the same environment
7787 variables as your shell. Try installing and configuring
7788 @uref{https://github.com/purcell/exec-path-from-shell}. By default it
7789 synchronizes @code{$PATH}, which helps Magit find the same @code{git} as the one you
7790 are using on the shell.
7791
7792 If SOMETHING is "passphrase caching with gpg-agent for commit and/or
7793 tag signing", then you'll also need to synchronize @code{$GPG_AGENT_INFO}.
77777794
77787795 @node How to install the gitman info manual?
77797796 @section How to install the gitman info manual?
78747891 only undo that setting in Magit by customizing
78757892 @code{magit-git-global-arguments}.
78767893
7877 @node Point is wrong in the COMMIT@math{_EDITMSG} buffer
7878 @section Point is wrong in the COMMIT@math{_EDITMSG} buffer
7894 @node Point is wrong in the @code{COMMIT_EDITMSG} buffer
7895 @section Point is wrong in the @code{COMMIT_EDITMSG} buffer
78797896
78807897 Neither Magit nor `git-commit` fiddle with point in the buffer used to
78817898 write commit messages, so something else must be doing it.
78977914 (pointback-mode -1))))
78987915 @end lisp
78997916
7900 @node Can Magit be used as ediff-version-control-package?
7901 @section Can Magit be used as ediff-version-control-package?
7917 @node Can Magit be used as @code{ediff-version-control-package}?
7918 @section Can Magit be used as @code{ediff-version-control-package}?
79027919
79037920 No, it cannot. For that to work the functions @code{ediff-magit-internal}
79047921 and @code{ediff-magit-merge-internal} would have to be implemented, and they
79517968 @code{tramp-ssh-controlmaster-options}. Changing your DNS server (e.g. to
79527969 Google's @code{8.8.8.8}) may also be sufficient to work around the issue.
79537970
7954 @node Symbol's value as function is void --some
7955 @section Symbol's value as function is void --some
7971 @node @code{Symbol's value as function is void --some}
7972 @section @code{Symbol's value as function is void --some}
79567973
79577974 Update @code{dash}, restart Emacs, and then it will be defined.
79587975
5656 MAGIT_VERSION = 2.6
5757 ASYNC_VERSION = 1.5
5858 DASH_VERSION = 2.12.1
59 WITH_EDITOR_VERSION = 2.5.0
60 GIT_COMMIT_VERSION = 2.6.0
61 MAGIT_POPUP_VERSION = 2.6.0
59 WITH_EDITOR_VERSION = 2.5.1
60 GIT_COMMIT_VERSION = 2.6.1
61 MAGIT_POPUP_VERSION = 2.6.1
6262
6363 ASYNC_MELPA_SNAPSHOT = 20150909.2257
6464 DASH_MELPA_SNAPSHOT = 20151021.113
6565 WITH_EDITOR_MELPA_SNAPSHOT = 20160408.201
66 GIT_COMMIT_MELPA_SNAPSHOT = 20160412.130
67 MAGIT_POPUP_MELPA_SNAPSHOT = 20160408.156
66 GIT_COMMIT_MELPA_SNAPSHOT = 20160414.251
67 MAGIT_POPUP_MELPA_SNAPSHOT = 20160414.251
6868
6969 EMACSBIN ?= emacs
7070
1010 ;; Marius Vollmer <marius.vollmer@gmail.com>
1111 ;; Maintainer: Jonas Bernoulli <jonas@bernoul.li>
1212
13 ;; Package-Requires: ((emacs "24.4") (dash "2.12.1") (with-editor "2.5.0"))
13 ;; Package-Requires: ((emacs "24.4") (dash "2.12.1") (with-editor "2.5.1"))
1414 ;; Keywords: git tools vc
1515 ;; Homepage: https://github.com/magit/magit
1616
387387 (setq-local redisplay-highlight-region-function 'git-rebase-highlight-region)
388388 (setq-local redisplay-unhighlight-region-function 'git-rebase-unhighlight-region)
389389 (add-hook 'with-editor-pre-cancel-hook 'git-rebase-autostash-save nil t)
390 (add-hook 'with-editor-post-cancel-hook 'git-rebase-autostash-apply nil t))
390 (add-hook 'with-editor-post-cancel-hook 'git-rebase-autostash-apply nil t)
391 (when (boundp 'save-place)
392 (setq save-place nil)))
391393
392394 (defun git-rebase-cancel-confirm (force)
393395 (or (not (buffer-modified-p)) force (y-or-n-p "Abort this rebase? ")))
244244 current-prefix-arg
245245 magit-commit-squash-confirm))))
246246 (let ((magit-commit-show-diff nil))
247 (magit-run-git-with-editor "commit"
248 (unless edit "--no-edit")
249 (concat option "=" commit)
250 args))
247 (push (concat option "=" commit) args)
248 (unless edit
249 (push "--no-edit" args))
250 (if rebase
251 (with-editor "GIT_EDITOR"
252 (let ((magit-process-popup-time -1))
253 (magit-call-git "commit" args)))
254 (magit-run-git-with-editor "commit" args)))
251255 (magit-log-select
252256 `(lambda (commit)
253257 (magit-commit-squash-internal ,option commit ',args ,rebase ,edit t)
13981398 (setq orig (magit-decode-git-path orig)))
13991399 (setq file (magit-decode-git-path file))
14001400 ;; KLUDGE `git-log' ignores `--no-prefix' when `-L' is used.
1401 (when (derived-mode-p 'magit-log-mode)
1401 (when (and (derived-mode-p 'magit-log-mode)
1402 (--first (string-match-p "\\`-L" it)
1403 (nth 1 magit-refresh-args)))
14021404 (setq file (substring file 2))
14031405 (when orig
14041406 (setq orig (substring orig 2))))
587587 "Failed to parse Cygwin mount: %S" it))
588588 ;; If --exec-path is not a native Windows path,
589589 ;; then we probably have a cygwin git.
590 (and (not (string-match-p
591 "\\`[a-zA-Z]:"
592 (car (process-lines "git" "--exec-path"))))
593 (ignore-errors (process-lines "mount"))))
590 (let ((process-environment
591 (append magit-git-environment process-environment)))
592 (and (not (string-match-p
593 "\\`[a-zA-Z]:"
594 (car (process-lines
595 magit-git-executable "--exec-path"))))
596 (ignore-errors (process-lines "mount")))))
594597 #'> :key (-lambda ((cyg . _win)) (length cyg))))
595598 "Alist of (CYGWIN . WIN32) directory names.
596599 Sorted from longest to shortest CYGWIN name."
13631363 not yet been pulled into the current branch. If no upstream is
13641364 configured or if the upstream is not ahead of the current branch,
13651365 then show the last `magit-log-section-commit-count' commits."
1366 (if (equal (magit-rev-parse "HEAD")
1367 (magit-rev-parse "@{upstream}"))
1368 (magit-insert-recent-commits t)
1369 (magit-insert-unpulled-from-upstream)))
1366 (let ((upstream (magit-rev-parse "@{upstream}")))
1367 (if (or (not upstream)
1368 (equal upstream (magit-rev-parse "HEAD")))
1369 (magit-insert-recent-commits t)
1370 (magit-insert-unpulled-from-upstream))))
13701371
13711372 ;;;; Auxiliary Log Sections
13721373
333333 (?F "remotes and prune" magit-fetch-all-prune)
334334 "Fetch"
335335 (?o "another branch" magit-fetch-branch)
336 (?r "explicit refspec" magit-fetch-refspec)
336 (?s "explicit refspec" magit-fetch-refspec)
337337 (?m "submodules" magit-submodule-fetch))
338338 :default-action 'magit-fetch
339339 :max-action-columns 1)
4545
4646 Optional PATH is the path to the submodule relative to the root
4747 of the superproject. If it is nil, then the path is determined
48 based on URL.
48 based on the URL.
4949
5050 Optional NAME is the name of the submodule. If it is nil, then
5151 PATH also becomes the name."
5252 (interactive
5353 (magit-with-toplevel
54 (let ((path (read-file-name
55 "Add submodule: " nil nil nil
56 (magit-section-when [file untracked]
57 (directory-file-name (magit-section-value it))))))
58 (when path
59 (setq path (file-name-as-directory (expand-file-name path)))
60 (when (member path (list "" default-directory))
61 (setq path nil)))
54 (let ((path (magit-completing-read "Add submodules at path"
55 (magit-untracked-files)
56 #'magit-git-repo-p nil nil nil
57 (magit-section-when [file untracked]
58 (file-relative-name
59 (magit-section-value it)
60 default-directory)))))
61 (unless path
62 (user-error "No path selected"))
6263 (list (magit-read-string-ns
6364 "Remote url"
64 (and path (magit-git-repo-p path t)
65 (let ((default-directory path))
66 (magit-get "remote" (or (magit-get-remote) "origin")
67 "url"))))
68 (and path (directory-file-name (file-relative-name path)))
69 (magit-read-string-ns "Name submodule" path)))))
65 (let ((default-directory (file-name-as-directory
66 (expand-file-name path))))
67 (magit-get "remote" (or (magit-get-remote) "origin") "url")))
68 (directory-file-name path)
69 (magit-read-string-ns
70 "Name submodule" nil nil
71 (or (--keep (-let [(var val) (split-string it "=")]
72 (and (equal val path)
73 (cadr (split-string var "\\."))))
74 (magit-git-lines "config" "--list" "-f" ".gitmodules"))
75 (directory-file-name path)))))))
7076 (magit-run-git "submodule" "add" (and name (list "--name" name)) url path))
7177
7278 ;;;###autoload
118124 ;;; Sections
119125
120126 ;;;###autoload
127 (defun magit-insert-submodules ()
128 "Insert sections for all modules.
129 For each section insert the path and the output of `git describe --tags'."
130 (-when-let (modules (magit-get-submodules))
131 (magit-insert-section (modules nil t)
132 (magit-insert-heading "Modules:")
133 (magit-with-toplevel
134 (dolist (module modules)
135 (let ((default-directory
136 (expand-file-name (file-name-as-directory module))))
137 (magit-insert-section (file module t)
138 (insert (format "%-25s " module))
139 (let ((beg (point)))
140 (magit-git-insert "describe" "--tags")
141 (when (eq (point) beg)
142 (insert ?\n))))))))))
143
144 ;;;###autoload
121145 (defun magit-insert-modules-unpulled-from-upstream ()
122146 "Insert sections for modules that haven't been pulled from the upstream.
123147 These sections can be expanded to show the respective commits."
124 (magit-insert-submodules "Modules unpulled from @{upstream}"
125 'modules-unpulled-from-upstream
126 'magit-get-upstream-ref
127 "HEAD..%s"))
148 (magit--insert-modules-logs "Modules unpulled from @{upstream}"
149 'modules-unpulled-from-upstream
150 'magit-get-upstream-ref
151 "HEAD..%s"))
128152
129153 ;;;###autoload
130154 (defun magit-insert-modules-unpulled-from-pushremote ()
131155 "Insert sections for modules that haven't been pulled from the push-remote.
132156 These sections can be expanded to show the respective commits."
133 (magit-insert-submodules "Modules unpulled from <push-remote>"
134 'modules-unpulled-from-pushremote
135 'magit-get-push-branch
136 "HEAD..%s"))
157 (magit--insert-modules-logs "Modules unpulled from <push-remote>"
158 'modules-unpulled-from-pushremote
159 'magit-get-push-branch
160 "HEAD..%s"))
137161
138162 ;;;###autoload
139163 (defun magit-insert-modules-unpushed-to-upstream ()
140164 "Insert sections for modules that haven't been pushed to the upstream.
141165 These sections can be expanded to show the respective commits."
142 (magit-insert-submodules "Modules unmerged into @{upstream}"
143 'modules-unpushed-to-upstream
144 'magit-get-upstream-ref
145 "%s..HEAD"))
166 (magit--insert-modules-logs "Modules unmerged into @{upstream}"
167 'modules-unpushed-to-upstream
168 'magit-get-upstream-ref
169 "%s..HEAD"))
146170
147171 ;;;###autoload
148172 (defun magit-insert-modules-unpushed-to-pushremote ()
149173 "Insert sections for modules that haven't been pushed to the push-remote.
150174 These sections can be expanded to show the respective commits."
151 (magit-insert-submodules "Modules unpushed to <push-remote>"
152 'modules-unpushed-to-pushremote
153 'magit-get-push-branch
154 "%s..HEAD"))
155
156 (defun magit-insert-submodules (heading type fn format)
175 (magit--insert-modules-logs "Modules unpushed to <push-remote>"
176 'modules-unpushed-to-pushremote
177 'magit-get-push-branch
178 "%s..HEAD"))
179
180 (defun magit--insert-modules-logs (heading type fn format)
157181 "For internal use, don't add to a hook."
158182 (-when-let (modules (magit-get-submodules))
159183 (magit-insert-section section ((eval type) nil t)
00 ;;; magit-version.el --- the Magit version you are using
11
2 (setq magit-version "2.6.1")
2 (setq magit-version "2.6.2")
33
44 (provide 'magit-version)
55
1515 ;; Rémi Vanicat <vanicat@debian.org>
1616 ;; Yann Hodique <yann.hodique@gmail.com>
1717
18 ;; Package-Requires: ((emacs "24.4") (async "1.5") (dash "2.12.1") (with-editor "2.5.0") (git-commit "2.6.0") (magit-popup "2.6.0"))
18 ;; Package-Requires: ((emacs "24.4") (async "1.5") (dash "2.12.1") (with-editor "2.5.1") (git-commit "2.6.1") (magit-popup "2.6.1"))
1919 ;; Keywords: git tools vc
2020 ;; Homepage: https://github.com/magit/magit
2121
17941794 "Merge commit REV into the current branch; and edit message.
17951795 Perform the merge and prepare a commit message but let the user
17961796 edit it.
1797 \n(git merge --edit [ARGS] rev)"
1797 \n(git merge --edit --no-ff [ARGS] rev)"
17981798 (interactive (list (magit-read-other-branch-or-commit "Merge")
17991799 (magit-merge-arguments)))
18001800 (magit-merge-assert)
1801 (cl-pushnew "--no-ff" args :test #'equal)
18011802 (with-editor "GIT_EDITOR"
18021803 (let ((magit-process-popup-time -1))
18031804 (magit-run-git-async "merge" "--edit" args rev))))
18071808 "Merge commit REV into the current branch; pretending it failed.
18081809 Pretend the merge failed to give the user the opportunity to
18091810 inspect the merge and change the commit message.
1810 \n(git merge --no-commit [ARGS] rev)"
1811 \n(git merge --no-commit --no-ff [ARGS] rev)"
18111812 (interactive (list (magit-read-other-branch-or-commit "Merge")
18121813 (magit-merge-arguments)))
18131814 (magit-merge-assert)
1815 (cl-pushnew "--no-ff" args :test #'equal)
18141816 (magit-run-git "merge" "--no-commit" args rev))
18151817
18161818 ;;;###autoload
22732275 map)
22742276 "Keymap for `magit-file-mode'.")
22752277
2278 ;;;###autoload (autoload 'magit-file-popup "magit" nil t)
22762279 (magit-define-popup magit-file-popup
22772280 "Popup console for Magit commands in file-visiting buffers."
22782281 :actions '((?s "Stage" magit-stage-file)