aboutsummaryrefslogtreecommitdiff
path: root/lisp/git-commit.el
AgeCommit message (Collapse)Author
2017-12-14git-commit-font-lock-keywords-3: fontify "Your branch is..."Jonas Bernoulli
2017-12-14git-commit-comment-action: inherit from boldJonas Bernoulli
Previously from `git-commit-comment-branch-local', which didn't make any sense.
2017-12-14git-commit: use different faces for local and remote branchesJonas Bernoulli
2017-12-14git-commit: provide three font-lock levelsJonas Bernoulli
Use `git-commit-font-lock-keywords-2' as the default as is done for other such triplets. `git-commit-font-lock-keywords-3' does not yet contain any additional fruit cake. `git-commit-font-lock-keywords-1' is for users who want less fruit cake.
2017-12-14git-commit: store font-lock keywords in variablesJonas Bernoulli
2017-12-14git-commit-comment-headings: move definitionJonas Bernoulli
2017-12-14git-commit-setup-font-lock: move definitionJonas Bernoulli
2017-12-03git-commit-turn-on-flyspell: avoid unnecessary workJonas Bernoulli
Our `git-commit-flyspell-verify' does its job as intended, but that only keeps flyspell from actually checking words inside comments, it does not keep it from looking at each word in comments and from incorrectly claiming that it is checking them. That takes time and is confusing. To avoid it, call `flyspell-region' on the relevant part of the buffer only. We cannot use `forward-comment' because that is syntax based, but we cannot use syntax for comments because the comment character only begins a comment if it is located at the beginning of a line.
2017-11-23git-commit-mode-map: change JќL bindingsJonas Bernoulli
Nothing to be seen here. For the time being I am the only one using JќL bindings. Still here? Okay then, I am doing this so that I don't accidentally switch to the previous message when I just wanted to move to the next paragraph.
2017-10-07git-commit-setup: pretend minor-modes are enabled earlierJonas Bernoulli
Hook functions that are run by the major-mode specified by `git-commit-major-mode' might want to consult the state of the minor-modes `git-commit-mode' and `with-editor-mode', but these minor-modes are not enabled until after the major-mode. To pretend that the minor-modes are already enabled, bind the minor-mode variables around the call to `normal-mode'. Closes #3184.
2017-10-04git-commit-comment-headings: add Authors and DateJonas Bernoulli
2017-10-04git-commit-pseudo-header: fix doc-stringJonas Bernoulli
2017-10-02Don't enable with-editor-mode twiceJonas Bernoulli
In `git-commit-setup' and `git-rebase-mode' do not enable `with-editor-mode' again if it is already enabled. That mode may already enabled if the user commits or rebases using `*-shell-command' or from a `shell', `term`, or `eshell` buffer.
2017-09-14git-commit-propertize-diff: ensure diff-mode keeps buffer writableJonas Bernoulli
Fixes #3170.
2017-09-13Reset Package-Requires for MelpaJonas Bernoulli
2017-09-13Release version 2.11.02.11.0Jonas Bernoulli
2017-08-23Small grammar fixMarc Sherry
2017-08-21Recognize EDIT_DESCRIPTION fileKyle Meyer
As of Git 2.13.0 (c10388c7dc), the file for editing a branch's description is named "EDIT_DESCRIPTION" rather than "BRANCH_DESCRIPTION". Fixes #3149.
2017-08-21git-commit-modified: new commandJonas Bernoulli
Useful for inserting: Modified-by: Jonas Bernoulli <jonas@bernoul.li> (Though usually you would only do that if you modified a commit originally written by someone else, obviously.)
2017-06-10Break up all multi-assignment setq'sKyle Meyer
Jonas notes: "Stefan says that the ability to set multiple variables is only supported for backward compatibility." https://github.com/magit/magit/pull/3101#discussion_r121172938
2017-05-10git-commit: add autoload cookiesBasil L. Contovounesios
Until now, enabling global-git-commit-mode meant loading git-commit.el and all of its dependencies. Exposing git-commit-filename-regexp and git-commit-setup allows users to defer loading the package in a more flexible way. For example, users may wish to pair the two in an auto-mode-alist entry.
2017-05-07git-commit-turn-on-auto-fill: Disable comment-auto-fill-only-commentsKyle Meyer
Buffers in text-mode do not define a comment syntax, which means that auto-filling ignores a non-nil value for comment-auto-fill-only-comments (i.e., auto-filling works on non-comments). A user would reasonably expect a commit buffer (in the default text-mode) to behave the same, but it does not because git-commit-mode sets up the comment syntax, resulting in comment-auto-fill-only-comments no longer being ignored. Explicitly set comment-auto-fill-only-comments to nil to avoid this discrepancy. Fixes #3068.
2017-05-06Add missing comma to various doc-strings and commentsAdam Benanti
2017-05-05git-commit-fill-column: officially mark obsoleteNoam Postavsky
It was effectively obsoleted in favor of fill-column in 2.9.0 [1]. [1]: 2016-11-08 22:35:55 +0100 2087cce6c021c3f985e5c53caa74bf56ebdd30fe git-commit: only override fill-column if not local yet
2017-03-14git-commit-setup: improve check before inserting newlineIoan-Adrian Ratiu
git-commit-setup always inserts a hardcoded newline after the beginning of a new commit message and this is very annoying when committing with --signoff because you get by default 3 empty lines before the "Signed-off-by:" and you have to manually remove that hardcoded line to conform to general git log style. This happens because `git commit` also inserts a newline (only if --signoff is used) so in that case a redundant newline is created (thanks tarsius for figuring this out!). So improve the check before inserting the newline to not insert if --signoff is used, but keep old behaviour when the flag is absent. Signed-off-by: Ioan-Adrian Ratiu <adi@adirat.com>
2017-03-08Reset Package-Requires for MelpaJonas Bernoulli
2017-03-08Release version 2.10.32.10.3Jonas Bernoulli
2017-02-14Reset Package-Requires for MelpaJonas Bernoulli
2017-02-14Release version 2.10.22.10.2Jonas Bernoulli
2017-01-28Reset Package-Requires for MelpaJonas Bernoulli
2017-01-28Release version 2.10.12.10.1Jonas Bernoulli
2017-01-12Suggest bug-reference-mode on relevant hooksJonas Bernoulli
Re #2949.
2017-01-09git-commit-setup: Call 'normal-mode' with argumentAlex Kost
This fixes a regression introduced by commit 084182e8e7dc82550543a4933c082a2a188d7faf. According to the docstring (and the code) of 'normal-mode', when it is called without argument, 'enable-local-variables' is ignored, so if there are unsafe local variables, a user will be prompted about them every time.
2017-01-04Reset Package-Requires for MelpaJonas Bernoulli
2017-01-04Release version 2.10.02.10.0Jonas Bernoulli
2017-01-04Bump copyright yearsJonas Bernoulli
2016-12-27Set local variables in lisp/.dir-locals.elJonas Bernoulli
2016-12-22Link from Custom groups and options to relevant Info nodesJonas Bernoulli
2016-12-22Improve, fix, and add many doc-stringsJonas Bernoulli
2016-12-20magit-hook-custom-get: new function used to initialize hook optionsJonas Bernoulli
Third-party hooks should not be defined as options, at least not when they have a non-nil value, because otherwise an early `add-hook' would not add to the hook but initialize it to just the added function. But users expect to be able to customize hooks, so we do it anyway. Previously each `defcustom' form that defines a hook was preceded by a form which made sure that the default functions got added to the hook even when users added their own functions earlier. Unfortunately, and surprisingly long undiscovered, that had the side-effect of overriding any customization made using the Custom interface. Now we use an approach that works in both cases, obviously. Fixes #2902.
2016-12-14Add support for JќL key bindingsJonas Bernoulli
JќL is the name I have given to my (for now) personal key bindings, which replace "bpnf" with "jikl" for navigation (similar to how vi uses "hjkl", but non-modal). Maintaining such changed key bindings across all the packages I use has proven to be challenging to say the least. Recently I have decided to try a new approach - just patch the packages that I use. That might seem like bad idea, and maybe it is, but all the others didn't really scale either. (And considering that I have written a package manager, Epkg, that is supposed to help with exactly this sort of thing, I ought to try that approach.) However for Magit patching is not feasible, because I work on that all the time, and sometimes when I work on a feature branch I do have to restart Emacs. I need my key bindings even when I am on a feature branch and not by own personal key bindings branch. Sometimes I add some optional functionality to Magit for the benefit of a very small number of users, sometimes consisting of a single user, who manages to convince me how very important a change is, even though nobody else seems to have the same need. Well, this time that user is me.
2016-12-14Cosmetic improvements for many keymap definitionsJonas Bernoulli
Some of the rearrangement is a bit strange. These changes prepare for those that come in the next commit. Look at that if you want to know why some binding definitions have moved to the beginnings of their respective definition blocks.
2016-12-14git-commit-mode-map: bind "C-c C-x i" for consistencyJonas Bernoulli
2016-12-07Reset Package-Requires for MelpaJonas Bernoulli
2016-12-07Release version 2.9.02.9.0Jonas Bernoulli
2016-11-24doc fix: correct git commit style convention nameBasil L. Contovounesios
2016-11-08git-commit: only override fill-column if not local yetJonas Bernoulli
We used to set the buffer-local value of `fill-column' in commit message buffers to the value of option `git-commit-fill-column', which overrides settings in ".dir-locals.el" and is surprising. Change `git-commit-turn-on-auto-fill' to only do so if `fill-column' does not already have a buffer-local value and if our option's value actually is an integer. Also change the options default value to be nil. The default value of `fill-column' is 70 and that of our option used to be 72.
2016-11-08git-commit-setup: use normal-modeNoam Postavsky
This ensures file and directory local variables are setup in the standard way.
2016-10-12bump with-editor dependencyJonas Bernoulli
2016-10-09git-commit: cosmeticsJonas Bernoulli