| Age | Commit message (Collapse) | Author |
|
We already do this in Transient's documentation because that's what
is being done in Emacs' documentation and Transient is part of Emacs.
Let's be consistent even at the cost of making the English unhappy.
Also add a comma before "e.g." and "i.e.", if not inside parentheses,
which is the correct thing to do, regardless which style guide one
chooses to follow.
|
|
Also see previous commit and #4942.
|
|
`git-commit-usage-message' is long enough to
potentially span more than one line. Previously one had to remove
`with-editor-usage-message' from `git-commit-setup-hook' to prevent
that. But then `with-editor-usage-message' wasn't displayed either
and that meant that the user got to see the misleading message that
`server-execute' insists on showing.
Add a new mechanism for disabling showing the long message; setting
`git-commit-usage-message' to nil.
|
|
|
|
|
|
As suggested by Stefan Monnier:
> I just saw this code in emacsql:
>
> (unless (require 'sqlite3 nil t)
> (declare-function sqlite3-open "sqlite3-api")
> (declare-function sqlite3-exec "sqlite3-api")
> (declare-function sqlite3-close "sqlite3-api"))
>
> This isn't right: the `require` and the `unless` will be executed only at
> runtime, not during compilation, but that that time the
> `declare-function`s will have disappeared, so you'll end up running
>
> (unless (require 'sqlite3 nil t)
> )
>
> Also the effect of `declare-function` should be limited to "the current
> scope", which could be argued to end at the end of the `unless` (I don't
> know if that's how the byte-compiler currently treats it, but that's how
> I think it should, ideally).
>
> So I think you want to just remove the `unless`.
> This way both the `require` and the `declare-function`s will be at
> top-level where the compiler likes them to be.
|
|
|
|
|
|
|
|
This reverts commit ece2cb84dd31aa967ef37a0d8bc2293c1c52db87.
That commit's goal was to ensure that we don't unset variables
that are not permanently local but that also prevented the major-
mode specified with `git-commit-major-mode' from being enabled.
Eventually we should fix both issues.
|
|
|
|
|
|
`git-commit-post-finish-hook' is not run until the new commit has been
created. If Git takes more than 1 second to do so, the hook isn’t run.
Whereas a 1 second timeout seems reasonable for most use cases, there
are use cases where a greater time is desirable.
For ex., when git is configured to sign commits with GnuPG, the user
might be interactively prompted to enter the passphrase of the GnuPG
private key.
If the user takes more than 1 second to type their passphrase, the
hook isn’t run.
In order to address such use cases, the new variable
`git-commit-post-finish-hook-timeout' allows to tune the value of this
timeout.
Co-authored-by: Jonas Bernoulli <jonas@bernoul.li>
Name of new option and docstring tweaks.
|
|
"N-git" < "N"; but "N.50-git" > "N".
|
|
This is a commonly used header, for example in patches for the Linux
kernel (see
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/process/submitting-patches.rst).
|
|
Closes #4806.
|
|
Obsolete since Emacs 29 / b7e867b841f47dcff3aeaef9b5608a237386ce70.
|
|
The set of files that contain non-ASCII characters has grown since
1c6205d8 (Only set coding system for libraries that need it,
2016-12-27). Set the coding system for all files listed by
git grep -lP '[^\x00-\x7f]' '*.el'
Closes #4732.
|
|
|
|
|
|
Also state why we are going through all this trouble.
|
|
|
|
|
|
|
|
|
|
|
|
It hasn't been true for quite some time that this library only (or
even just mostly) defined things that have "very little to do with
Git or Magit", and it is time to account for that.
"magit-base.el" serves a role similar to that of "magit-core.el",
except that it comes even earlier in the dependency tree. For that
reason other libraries that depend on one or more of the libraries
that `magit-base' depends on should just require that feature.
|
|
Some of the "insert header" commands use git-commit-self-ident to get
a name and email. git-commit-self-ident wraps its git-config calls in
ignore-errors and then proceeds to fallback values.
user.name and user.email are something that all Git users should
configure, and git-commit will complain ("Please tell me who you are
..."). Use with-demoted-errors instead of ignore-errors so that
there's a message about these variables being unset. This change
means that errors won't be caught when debug-on-error is non-nil, but,
given git-commit-self-ident is called only by "insert header"
commands, that seems appropriate.
Re: magit/with-editor#106
|
|
Any error in git-commit-setup-font-lock will cause committing to fail
with something like:
1 git … commit --
hint: Waiting for your editor to close the file...
Waiting for Emacs...
*ERROR*: ...
error: There was a problem with the editor '/path/to/emacsclient --socket-name=...'
Please supply the message using either -m or -F option.
Demote these errors to messages to prevent committing from failing due
to any error related to font locking.
Re: magit/with-editor#106
|
|
git-commit-setup-font-lock calls 'git config core.commentchar' via
call-process. This call exits with 1 if the key isn't found. On
success or failure, that normally shouldn't produce any stderr, and on
success the only stdout should be the core.commentchar.
But to be safe and reduce the chances of processing unintended output,
1) stop if there was a non-zero exit and 2) insert only standard
output into the buffer.
|
|
Three spots in git-commit.el hard code "git" as the git executable.
Two of these spots are in git-commit-self-ident. If the user doesn't
have git in $PATH, these spots aren't much of a problem because 1)
these calls are wrapped with ignore-errors and have fallback values
and 2) their only callers are some of the git-commit-* "insert header"
commands.
The "git" in git-commit-setup-font-lock, on the other hand, can cause
committing to fail if git isn't in $PATH:
1 git … commit --
hint: Waiting for your editor to close the file...
Waiting for Emacs...
*ERROR*: Searching for program: No such file or directory, git
[...]
A Magit user without git in $PATH must configure the
magit-git-executable variable, so teach git-commit.el to try to get
the executable path from the magit-git-executable function. Using the
function means that the appropriate path is also used for Tramp
buffers.
Fixes magit/with-editor#106.
|
|
|
|
|
|
format-prompt isn't available until (what will be) Emacs 28.1. Use a
plain format call instead.
The new behavior is different in that 1) it doesn't respect
minibuffer-default-prompt-format and 2) it shows "(default )" for an
empty string default rather than hiding the default entirely. The
first seems an acceptable trade for compatibility while avoiding a
wrapper/kludge. And the second seems fine in general given that the
empty string is in fact the default, so it's worth telling the user
about the useless default value.
|
|
|
|
Closes #4537.
|
|
|
|
|
|
|
|
Re https://github.com/tarsius/orglink/issues/12.
|
|
|
|
|
|
|
|
Closes #4503.
|
|
Otherwise all non-permanent variables would get reset.
|
|
|
|
- For multi-library packages Melpa gets the dependency information
from <package>-pkg.el files. Melpa uses timestamps for snapshot
versions, so that is what we store in these files.
- NonGNU Elpa gets the dependency information from headers in a
package's main library. In NonGNU Elpa snapshot versions consist
of the release followed by a timestamp, so we store the release
versions in the library headers.
|
|
|
|
|
|
|