| Age | Commit message (Collapse) | Author |
|
If `uniquify-buffer-name-style' is `nil', then let-bind it
to `post-forward-angle-brackets', like we already do when
the global value is `forward'.
Fixes #2516.
|
|
By default Git only maintains reflogs for refs in certain namespaces.
To force it do so for other refs it was necessary to manually create the
appropriate file .git/logs/<ref> before calling `git update-ref'. Since
v2.6.0 that command supports the `--create-reflog' argument, and we now
use it if available.
To make that easier, wrap `git update-ref' in the new function
`magit-update-ref', which also falls back to the old approach for older
Git versions. Also remove the function `magit-reflog-enable', which is
where the hack used to be located.
This also fixes #2515. The old hack failed when creating a stash in a
linked working tree when the repository did not already contain another
stash. The problem was that a file .git/worktrees/<worktree>/logs/<ref>
was created, instead of .git/logs/<ref>. Like the `--create-reflog'
argument, support for linked working trees was added in Git v2.6.0, so
it's okay to use the old "touch file" approach for older Git versions
(not that we have a choice anyway).
|
|
For log and reflog buffers the margin was previously reset to the
default state according to `magit-{log or reflog}-show-margin', when a
command was invoked which changed what log/reflog is being displayed.
|
|
|
|
Change the section heading inserted by
`magit-insert-unpushed-to-upstream' from "Unpushed to <upstream>" to
"Unmerged into <upstream>" because one should merge into the upstream
instead of pushing to it.
|
|
|
|
|
|
|
|
|
|
Also add ARG argument to `magit-abbrev-arg'.
|
|
|
|
Unlike `concat', `insert' fails if one of its arguments is `nil'.
|
|
|
|
|
|
|
|
|
|
If `magit-status-always-refresh' is t (the default) then now also
refresh the status buffer if the current buffer isn't a Magit buffer.
Otherwise, if it is nil, then only refresh it if it itself is the
current buffer.
|
|
Replace the old magit-specific auto-revert implementation with the
mode `magit-auto-revert-mode', a globalized variant of the built-in
`auto-revert-mode'. By default Magit still explicitly triggers the
reverts after running git for side-effects. Automatic reverts are
still enabled by default, and Magit is less verbose about it. The
behavior can be tuned using `magit-auto-revert-' and `auto-revert-'
options.
The main benefit of this change is that this implementation caches
whether a file is tracked or not. The old implementation determined
this on every revert cycle, which did not perform well when there
were many open buffers and/or many tracked files.
|
|
Display popups using `display-buffer' with the value of the new
option `magit-popup-display-buffer-action' as ACTION argument.
|
|
Depending on the number of tracked files, the number of buffers, and
whether Tramp is used, testing whether the files in question actually
are tracked can reduce performance drastically. So we now default to
reverting all files inside the current repository.
Setting `magit-revert-buffers-only-for-tracked-files' to t restores
the old behavior.
|
|
|
|
But do not add it to the push popup by default.
|
|
This command was removed earlier, but it turned out that it is still
required for certain work-flows. Restore the command, but do not add it
to the push popup again. If the user follows the instructions on how to
add the command to the popup, then that now shows what the command will
do.
|
|
|
|
|
|
Combine `magit-pull-popup' and `magit-fetch-popup' into one common
popup. By default the old popups are still bound in `magit-mode-map'.
Add this to your init file to use the new popup:
(with-eval-after-load 'magit-remote
(define-key magit-mode-map "f" 'magit-pull-and-fetch-popup)
(define-key magit-mode-map "F" nil))
One advantage of the new popup is that it is once more possible to
press the same key twice to fetch. However that binding now is "f f",
not "F F", and it fetches all remotes not just the current remote.
The new popup also lacks the commands for fetching from only a single
remote. You can add them to the new popup by adding something like this
to your init file:
(with-eval-after-load 'magit-remote
(magit-define-popup-action 'magit-pull-and-fetch-popup ?U
'magit-get-upstream-branch
'magit-fetch-from-upstream-remote ?F)
(magit-define-popup-action 'magit-pull-and-fetch-popup ?P
'magit-get-push-branch
'magit-fetch-from-push-remote ?F))
|
|
|
|
|
|
|
|
|
|
It turned out that this is not actually necessary but has downsides.
Users should instead set `remote.pushDefault' once per repository.
Doing so has the advantage that this variable affects all branches,
including branches that already exist. `branch.autoSetupPush' on the
other hand only takes effect when new branches are being created.
Furthermore needlessly setting a variable per-branch (using
`branch.<name>.pushRemote') which could just as well be set per
repository (because it is the same for all branches) has the
disadvantage that changing that value becomes much more work.
In rare cases the push-remote of a branch might be different from that
of the other branches. In that case `branch.<unicorn>.pushRemote'
should be set manually. Whether `branch.autoSetupPush' exists or not,
doesn't matter, if the unicorn needs a different push-remote, then
`branch.<unicorn>.pushRemote' always has to be set explicitly.
|
|
Mark the valid selection (i.e. one that contains only rebase lines and
that includes the entire line) with magit-section-heading-selection.
Re: #2412
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Disable this feature by default to address privacy concerns. Re #2369.
|
|
|
|
|
|
|
|
|
|
Support is pretty basic and will be improved eventually. It won't be
improved incrementally, i.e. I won't add related arguments as they are
being requested, but only when I feel that the time to do so has come,
i.e. once I have the time to tackle this exciting area of Git properly.
|
|
|
|
Add variable `magit-log-remove-graph-args' replacing the old
`magit-log-remove-graph-re', because that makes it easier to
change the value.
|
|
|
|
|
|
This allows adding suitable key bindings in blog buffers even though
these buffers use arbitrary major-modes. "q" now kills the buffer.
|
|
Rename related symbols accordingly.
|