Commit graph

17 commits

Author SHA1 Message Date
Henrik Lissner
b573fcce20
quit-window on multiple magit-status windows
If you accidentally open multiple magit status windows, you'll be stuck
in a deadlock, where `q` will do nothing. Now, +magit/quit will use
`quit-window` on excess magit-status windows instead.
2018-10-03 00:04:08 -04:00
Henrik Lissner
fcd1e913c5
tools/magit: update vc on +magit/quit
Instead of magit-post-refresh-hook, which fires much more frequently.
Updating vc across all buffers is expensive, so let's only do it when we
quit magit.

Warning: this may make quitting magit expensive when you have many
buffers open. Still searching for a better solution.
2018-09-26 12:10:00 -04:00
Henrik Lissner
7d3ffdff06
Remove third line in section headers
This is truly important stuff. We've saved many lives with this update.
2018-09-09 09:58:19 -04:00
Henrik Lissner
17abb990e4
tools/magit: don't make new windows too tall
Some popups (like logs or revisions) completely consume the current
window.
2018-08-21 22:45:42 +02:00
Henrik Lissner
9e0e586dd8
tools/magit: use current window instead of fullcol
Full column is a bit tempermental. This also removes the need to restore
the window config after quitting magit.

Why the switch from full-frame magit to current-buffer? It is the least
intrusive policy; it doesn't rearrange the user's workspace.
2018-08-19 01:15:22 +02:00
Henrik Lissner
2cc5d223fe
Rewrite how magit windows/popups are managed
The old policy was to invoke magit in fullscreen, but in practice, I've
found myself wanting to peek at other buffers (maybe even notes) while I
manage my project in version control.

So this change introduces two big changes and one fix:

+ Instead of a full-frame policy, we use full-column. e.g. Invoking
  magit-status will take up a full column of windows (and will restore
  them when you quit).
+ Popups are displayed below the current window if called from a magit
  buffer, otherwise as a popup at the bottom of the frame.
+ Fixes popups opening in a random window if called from a magit buffer
  in a popup.

This is only a start and needs more testing.
2018-08-13 21:47:56 +02:00
Henrik Lissner
fd949e7063
Make diff larger when committing via magit
The diff window contains more important information, so we shrink the
git commit window and enlargen the diff window.
2018-06-16 21:48:37 +02:00
Henrik Lissner
01b2856cc2
From eshell, open magit buffers in same window 2018-06-16 15:20:10 +02:00
Henrik Lissner
c305d63dd7
Improve magit display-buffer logic
Now opens derivative magit buffers (from popup magit windows) in
fullscreen.
2018-06-16 14:38:52 +02:00
Henrik Lissner
383ecf7a08
Fix magit rebase/log windows being hidden by diffs 2018-06-10 17:28:17 +02:00
Henrik Lissner
85a0c9efc9
New default display-buffer handler for magit
+magit-display-buffer-fullscreen is a more sophisticated (albeit
experimental) replacement for magit-display-buffer-fullframe-status-v1,
which fullscreens magit, but will also:

a) Keep the status window visible
b) Treat magit buffers not opened from magit-status as popups
2018-06-07 02:51:45 +02:00
Henrik Lissner
bab530ea2e
Revert +hub flag, but disable magithub by default
Must be enabled on a per-project basis. You can change this behavior by
setting +magit-hub-enabled-by-default to non-nil (before magit is
loaded).

Magithub has been made opt-in because:

1. Magithub is imposing, asking the user for a token, especially for
   users who don't use github (much or at all), but may occasionally
   have a project with a github remote.
2. magithub is really slow on first load for medium-to-large repos.
3. It's really easy to enable it through the magithub popup (H C e).
   magithub.enabled is saved into the project's .git/config file, so the
   setting will persist.

Also added a docstring to +magit-hub-features
2018-06-01 11:13:37 +02:00
Henrik Lissner
3a16b70022
Add +magit/clone command & bind to SPC g C #633
magithub-clone doesn't support full urls, magit-clone doesn't support
user/repo notation. +magit/clone supports both.
2018-05-31 13:59:21 +02:00
Benjamin Andresen
8917bc9194 Fix: tools/magit: +magit--kill-buffer function call corrected 2018-04-12 00:41:38 +02:00
Henrik Lissner
460461ef54
tools/magit: clean up after magit more intelligently #506
Ensures magit buffers are cleaned up after magit-status is closed. Will
defer cleanup on process buffers, until the processes have finished.

Also fixes issue where quitting magit will leave leftover windows.
2018-04-08 20:44:40 -04:00
Henrik Lissner
163d0ce70e
tools/magit: don't kill processes 2018-04-04 09:35:39 -04:00
Henrik Lissner
b98e26856d
Add tools/magit/autoload.el 2018-04-04 08:04:54 -04:00