Skip to content

Commit

Permalink
git{,-blame}.el: remove old bitrotting Emacs code
Browse files Browse the repository at this point in the history
The git-blame.el mode has been superseded by Emacs's own
vc-annotate (invoked by C-x v g). Users of the git.el mode are now
much better off using either Magit or the Git backend for Emacs's own
VC mode.

These modes were added over 10 years ago when Emacs's own Git support
was much less mature, and there weren't other mature modes in the wild
or shipped with Emacs itself.

These days these modes have few if any users, and users of git aren't
well served by us shipping these (some OS's install them alongside git
by default, which is confusing and leads users astray).

So let's remove these per Alexandre Julliard's message to the
ML[1]. If someone still wants these for some reason they're better
served by hosting these elsewhere (e.g. on ELPA), instead of us
distributing them with git.

However, since downstream packagers such as Debian are packaging this
as git-el it's less disruptive to still carry these files as Elisp
code that'll error out with a message suggesting alternatives, rather
than drop the files entirely[2].

Then rather than receive a cryptic load error when they upgrade
existing users will get an error directing them to the README file, or
to just stop requiring these modes. I think it makes sense to link to
GitHub's hosting of contrib/emacs/README (which'll be updated by the
time users see this) so they don't have to hunt down the packaged
README on their local system.

1. "Re: [PATCH] git.el: handle default excludesfile
   properly" (87muzlwhb0.fsf@winehq.org) --
   https://public-inbox.org/git/87muzlwhb0.fsf@winehq.org/

2. "Re: [PATCH v3] git{,-blame}.el: remove old bitrotting Emacs
   code" (20180327165751.GA4343@aiede.svl.corp.google.com) --
   https://public-inbox.org/git/20180327165751.GA4343@aiede.svl.corp.google.com/

Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
  • Loading branch information
avar authored and gitster committed Apr 16, 2018
1 parent d0db9ed commit 6d5ed48
Show file tree
Hide file tree
Showing 5 changed files with 25 additions and 2,228 deletions.
1 change: 0 additions & 1 deletion contrib/emacs/.gitignore

This file was deleted.

21 changes: 0 additions & 21 deletions contrib/emacs/Makefile

This file was deleted.

32 changes: 13 additions & 19 deletions contrib/emacs/README
Original file line number Diff line number Diff line change
@@ -1,30 +1,24 @@
This directory contains various modules for Emacs support.
This directory used to contain various modules for Emacs support.

To make the modules available to Emacs, you should add this directory
to your load-path, and then require the modules you want. This can be
done by adding to your .emacs something like this:
These were added shortly after Git was first released. Since then
Emacs's own support for Git got better than what was offered by these
modes. There are also popular 3rd-party Git modes such as Magit which
offer replacements for these.

(add-to-list 'load-path ".../git/contrib/emacs")
(require 'git)
(require 'git-blame)


The following modules are available:
The following modules were available, and can be dug up from the Git
history:

* git.el:

Status manager that displays the state of all the files of the
project, and provides easy access to the most frequently used git
commands. The user interface is as far as possible compatible with
the pcl-cvs mode. It can be started with `M-x git-status'.
Wrapper for "git status" that provided access to other git commands.

Modern alternatives to this include Magit, and VC mode that ships
with Emacs.

* git-blame.el:

Emacs implementation of incremental git-blame. When you turn it on
while viewing a file, the editor buffer will be updated by setting
the background of individual lines to a color that reflects which
commit it comes from. And when you move around the buffer, a
one-line summary will be shown in the echo area.
A wrapper for "git blame" written before Emacs's own vc-annotate
mode learned to invoke git-blame, which can be done via C-x v g.

* vc-git.el:

Expand Down
Loading

0 comments on commit 6d5ed48

Please sign in to comment.