alphapapa / magit.sh

Run Magit in a separate Emacs instance

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

magit.sh

Run a standalone Magit editor! To improve startup speed, this script ignores the user’s Emacs init files and only loads the Emacs libraries Magit requires.

Note that this does not install any packages. Magit and its dependencies must already be installed in ~/.emacs.d.

Using a separate Emacs configuration

If you would prefer to run Magit separately from your main Emacs configuration, you could do so easily using emacs-sandbox.sh. For example:

  • Make a directory in which to install Magit and its dependencies, e.g. ~/.local/lib/emacs-sandbox/magit.
  • Run this command to install Magit and its dependencies into that directory:
emacs-sandbox.sh -d ~/.local/lib/emacs-sandbox/magit -i magit -- -f kill-emacs
  • Use this command to run Emacs in that config and call magit-status directly:
emacs-sandbox.sh --no-refresh-packages -d ~/.local/lib/emacs-sandbox/magit -- -f magit-status -f delete-other-windows

You could put that command into a magit.sh script, or use it as a shell alias.

About

Run Magit in a separate Emacs instance

License:GNU General Public License v3.0


Languages

Language:Shell 100.0%