Magit opening on a random window

If everything goes south and I find a better replacement for GNU Emacs, Magit1 would definitely be the hardest to replace. It is deeply ingrained in my daily workflow and I can’t imagine using Git with anything else.

Having said that, I always hated how it would open magit-status randomly. Sometimes on the top, sometimes splitting your screen in half. I’m sure there’s a reason and a rationale behind that, but I could never anticipate where it would pop-up. It’s also funny that I have never considered fixing this problem, I don’t know, I just lived with it… Until I saw a Hacker News comment on how to make it full screen.

(use-package magit
  ;; makes magit fullscreen and restore the windows when closing
  (setq magit-display-buffer-function 'magit-display-buffer-fullframe-status-topleft-v1
        magit-bury-buffer-function 'magit-restore-window-configuration))

As the comment says, this makes all Magit buffers open in full screen and then restore all your windows after closing it.

  1. Consider donating to it on Open Collective↩︎

Articles from blogs I follow around the net

Variations of the Range kata

In the languages I usually employ. The Range kata is succinct, bordering on the spartan in both description and requirements. To be honest, it's hardly the most inspiring kata available, and yet it may help showcase a few in…

via ploeh blog January 1, 2024

Some notes on NixOS

Hello! Over the holidays I decided it might be fun to run NixOS on one of my servers, as part of my continuing experiments with Nix. My motivation for this was that previously I was using Ansible to provision the server, but then I’d ad hoc installed a bunch…

via Julia Evans January 1, 2024

I found some of my first code! Annotating and reflecting on robotics code from 2009.

In high school, one of my teachers shattered my plans for my life, in the most beautiful way. Most of my life, I'd intended to become a math professional of some sort: a math teacher, when that was all I saw math for; an actuary, when I started to lear…

via blog January 1, 2024

Generated by openring