Commit graph

5004 commits

Author SHA1 Message Date
Itai Y. Efrat
a20cd88e8e refactor!(haskell): remove dante support
BREAKING CHANGE: Now that haskell-language-server is mature there is
little reason not to pick it over dante.
2021-09-15 01:56:26 +03:00
Henrik Lissner
6541ae5135 fix: revert x-select-request-type to default
Its default value is acceptable in 28+ and handles clipboard integration
in PGTK Emacs, so we don't have to.

Thanks to @sei40kr for revealing this fix to me (in #5219).

Fix #5219
2021-09-13 17:26:33 +02:00
Henrik Lissner
48239aeb97 fix(cli): git version check on Windows
Of course Git on Windows produces '2.33.0.windows.2'. Why wouldn't it?
2021-09-11 14:26:45 +02:00
Henrik Lissner
c298dc3ac7 refactor(doom-quit): distinguish flavor text in quit prompts
Makes it easier to tell apart flavor text from the actual prompt.
2021-08-16 15:01:22 -04:00
Henrik Lissner
462bfb9693 fix: doom/reload runs remotely in tramp buffers
When run in a remote buffer, `doom sync` is executed on the remote host,
which is not intended behavior.

Fix #5378
2021-08-14 02:29:46 -04:00
Daanturo
14f9289998
fix: wrong-number-of-args error in doom/reload-env
Close #5368
Ref 9687c04a84
2021-08-12 12:26:56 -04:00
Henrik Lissner
9687c04a84 fix: doom/reload 404ing on executables
Half-reverts c2c6a64, which tried to get doom/reload to regenerate the
envvar file from within Emacs, but running an environment scraper in a
bare environment is really hard to get right. Ideally, your shell config
should set up your environment, but there are too many edge cases or
poor configs in the wild to depend on this.

I've brought back doom/reload-env, but only to reload the envvar file
-- *not* regenerate it. I've given up on trying to do that from within
Emacs.

Fix #5344
Ref c2c6a64118
2021-08-11 01:50:42 -04:00
Henrik Lissner
2c4328ccf0 fix: flipped logic in tramp + projectile advice
Some logic derps from 0b5243c. Also restores
projectile-git-submodule-command in remote buffers (to fix a
wrong-type-argument error waiting to happen).

Ref 0b5243c12c
Ref #5360
2021-08-10 17:32:34 -04:00
Henrik Lissner
0b5243c12c perf: optimize tramp + projectile integration
Reduce how much projectile hits the server in TRAMP buffers by:

- Not looking for fd/fdfind (just use the VCS-specific commands
  projectile provides and assume they're present on the remote).
- Not walking up the directory tree to display the project name in the
  mode line.
- Reducing TRAMP file-cache misses.
- Reducing how chatty tramp is about its connections.

Fix #5360
2021-08-10 17:10:42 -04:00
Henrik Lissner
e76f5388be fix: doom-system-cpus not handling int values
ce31880 did not fix doom-system-cpus on msys2 builds because the
function didn't handle integer return values from any of its code
paths (which formerly returned strings or lists).

Ref ce31880ccc
Fix #5347
2021-08-06 03:44:34 -04:00
Henrik Lissner
1352f8a9aa fix: args-out-of-range when cleaning project cache
Caused when the key of a cached project is an empty string.

Fix #5345
2021-08-06 03:13:36 -04:00
Henrik Lissner
ce31880ccc fix: doom-system-cpus returning 1 on msys2 build
Fix #5347
2021-08-06 03:08:33 -04:00
Henrik Lissner
24866a17ee fix: void-variable arg error from doom/reload
Some leftover code from the doom/reload-env, which was removed in
c2c6a6411.

Ref c2c6a64118
Fix #5344
2021-08-05 12:54:37 -04:00
Henrik Lissner
abc16ef68c refactor(cli): make all searches case-sensitive
This is more predictable, and is safe as a global default in CLI
sessions (but not in interactive ones). This indirectly fixes case
insensitivity in our commit linter rules.
2021-08-05 12:53:20 -04:00
Henrik Lissner
a3f917c42d dev: fix off-by-one for line length rule 2021-08-04 10:46:10 -04:00
Henrik Lissner
045ea7460d nit: revise and reformat code comments 2021-08-04 01:53:12 -04:00
Henrik Lissner
06392a723f refactor: rename orig-fn arg in advice to fn
A minor tweak to our naming conventions for the first argument of an
:around advice.
2021-08-04 01:53:12 -04:00
Henrik Lissner
12732be155 feat: don't delay when opening auto-saved files
If a file has auto-saved data (see auto-save-default), after-find-file
will stop the world for 1 second to tell you about it. Very annoying.
Just log it to *Messages* and open the file immediately.
2021-08-04 01:53:12 -04:00
Henrik Lissner
c2c6a64118 fix: doom/reload now regenerates the envvar file
Removes doom/reload-env, now that it is redundant.
2021-08-03 23:00:43 -04:00
Henrik Lissner
3beff3133f dev: refactor, fix, and add rules to commit linter
- Conform commit linter to 50/72 rule
- Add linter rule for body line length; excludes the footer and lines
  with long URLs.
- Add linter rule for validating scopes are in lexical order.
- Add linter rule for validating footer refs.
  Footer references should reference one thing per line. That thing can
  be one of:
  - An URL.
  - An issue or PR reference (local or remote).
  - A 12-character commit hash (local or remote).
- Extend linter to detect new scopes for docs:
  - Commits of type 'docs' can now use these additional scopes (in
    addition to other possible scopes):
    - docs(install) -> for changes to our installation guide(s). It is
      expected for this to change so often that it has its own scope.
    - docs(X) -> where X is the basename of any org file in docs/*.org.
      e.g.
      - docs(index): ...
      - docs(modules): ...
      - docs(faq): ...
- Modify the scope checker to consider *any* parenthetical scope given
  for bump, revert, merge, module, or release commits to be invalid.
- Update bump commit linter for 12c hashes (see 3bedae38dd).
- Fix language in imperative ref linter warning.

Ref https://discourse.doomemacs.org/how2commit
Ref 3bedae38dd
2021-08-03 23:00:43 -04:00
Henrik Lissner
3bedae38dd dev: transition to 12c long hashes
In bumps, in :pin's, and in our git conventions. We have no rules for
the commit linter for it yet, though.
2021-08-02 22:07:13 -04:00
Henrik Lissner
74f72c15b3 dev: fix commit linter target and lint all commits
- Was formerly processing the internal merge commit, which never conforms
  to our conventions, but is also unrelated to the work at hand.
- Now lints the range of commits applicable to the event, and not just
  the latest commit.
2021-08-02 15:00:53 -04:00
Henrik Lissner
5df31a4895 dev: fix and refactor commit lint rules
- Fix rules that weren't working due to faulty logic.
- Revise linter messages for clarity and concision.
- Use conventional commit nomenclature: summary -> subject
- case-fold-search = nil, to ensure case sensitive searches
- Exclude bump type from length checks
2021-08-01 23:37:36 -04:00
Henrik Lissner
11a0c0cbdb dev: add linter rule for commit capitalization
Bad:  'fix(abc): Prevent freezes'
Good: 'fix(abc): prevent freezes'
2021-08-01 23:37:36 -04:00
Henrik Lissner
5d1d0fc7c9 dev: add linter rule for Refs: in commit footer
+ No colon.
+ One ref per line.

Bad:
  Refs: A B C
  Ref: X Y
  Ref: Z
Good:
  Ref A
  Ref B
  Ref C
  Ref X
  Ref Y
  Ref Z
2021-08-01 23:37:36 -04:00
NightMachinary
a6f365bb3f
fix: doom/move-this-file when directory is the target
* doom/move-this-file now supports moving directly into a directory
* applied requested changes

Close #4861
2021-08-01 15:13:52 -04:00
Henrik Lissner
3d423862d7 dev: add linter rules for module type
Recently added 'module' to our list of git commit types to represent
changes to our module list. These events are important enough to
Doom (and users) to track separately.
2021-08-01 11:43:01 -04:00
Henrik Lissner
345ff621c3 dev: link to gist for commit docs
Until the new docs are up, link to the gist.
2021-08-01 02:03:36 -04:00
Henrik Lissner
0b4e1c30b7 dev: fix commit linter
Forgot to add the new -C/--nocolor option for 'doom sync', and to load
the 'doom ci *' family.
2021-08-01 01:02:51 -04:00
Henrik Lissner
074b9eb0d1 dev: add commit linter workflow
Experimenting with an internal linter. Only trouble is, if Doom's CLI is
ever in a broken state, a contributor will have to know about
--no-verify option for git commit. This can be improved post CLI
rewrite.
2021-07-31 23:51:27 -04:00
Daanturo
bfc12b83b4 Black list XDG_SESSION_TYPE from doom-env
The variable is obsolete once we switch between "x11" and "wayland".
2021-07-30 08:14:48 +07:00
Itai Y. Efrat
ae2a63137a fix: use new commit format in doom/bumpify-diff 2021-07-28 23:57:39 +03:00
Henrik Lissner
33b646826b fix(vertico): add counsel-file-jump analogue
Fix 'SPC f F' / 'C-c f F' for vertico users
2021-07-28 12:54:23 -04:00
Henrik Lissner
93f6591faf tweak: gcmh-idle-delay = 5 -> 0.5
Reduce the chance of memory leaks by being a little more aggressive
about idle GC. This *may* be too low; time will tell.
2021-07-28 12:42:46 -04:00
Henrik Lissner
cd87cc0cc8 refactor: remove redundant org code
org-collect-keywords does the job here. No need to reinvent the wheel.
2021-07-28 12:42:22 -04:00
Henrik Lissner
dd9657d90d Fix SPC f F w/ vertico + consult
Not a perfect analogue to counsel-file-jump, but it's a start (and
better than the previous no-op).
2021-07-25 17:55:59 -04:00
Henrik Lissner
91e1eac024 Fix doom/delete-backward-word errors in minibuffer
The cause of the error is harmless, but the error itself was causing
breakage in the minibuffer.
2021-07-25 16:26:47 -04:00
Itai Y. Efrat
a0eb4e9b65 completion/selectrum -> completion/vertico, part 3
- Rename all functions and variables in the module to reflect the
  namechange (and the irc jump function)
2021-07-25 02:52:04 +03:00
Itai Y. Efrat
92586cacd4 selectrum: remove doom-project-find-file hack
This solution doesn't rely on condition evaluation order, and doesn't
contain `featurep!`'s unnecessarily.
2021-07-25 02:50:42 +03:00
Itai Y. Efrat
49a5c51615 selectrum: fix bugs when counsel is loaded (hack)
some doom functions check the completion module with `fboundp`'s instead
of `featurep!`, and counsel can be loaded by using e.g. `lispy`. we add
temporary fixes for this by checking for selectrum stuff first, but this
should be given a more robust fix later on

also we document the selectrum PR's hacks in the TODO.org

see discussion on #5013
2021-07-25 02:50:42 +03:00
Itai Y. Efrat
26a310d04c selectrum: improve ivy parity
- add `completion-at-point` as analogue to `cousnel-company`
- fix emacs-bindings `counsel-company` binding to respect helm and selectrum
- add org jump commands `consult-org-heading` and `consult-org-agenda` bindings
- add `consult-history` as `counsel-minibuffer-history` analogue
- add support for `doom/help-search`
- update TODO.org
2021-07-25 02:50:31 +03:00
Henrik Lissner
3fb4ac2e4b
Merge pull request #5274 from Yp3rion/develop
Fix doom/help-packages to correctly print config locations
2021-07-23 16:15:31 -04:00
Henrik Lissner
8862f8694c Activate general-auto-unbind-keys post-startup
To prevent "X starts with non-prefix key Y" errors except at startup.
2021-07-13 14:34:30 -04:00
Henrik Lissner
6672ee5cf5 Simplify session persistence 2021-07-12 16:22:30 -04:00
Henrik Lissner
5c741cb65f Fix #5255: reload session after dashboard init
Otherwise, the dashboard replaces one of the buffers when reloading the
last session at startup.
2021-07-12 16:00:45 -04:00
Henrik Lissner
cbb0ce9f85 Don't log hooks
Produces a lot of logging noise, and Doom already injects context into
errors that occur in hooks.
2021-07-11 17:52:08 -04:00
Henrik Lissner
f523830a0e Don't load core-cli on doom/reload
Hopefully addresses "Device 1 is not a termcap terminal device" errors,
due to core-cli changing `debugger`. core-cli should never be loaded in
an interactive session anyway.

Possibly fixes #4849
2021-07-11 17:52:08 -04:00
Henrik Lissner
d79cea2e4c Minor refactors, reformatting, & comment revision 2021-07-11 17:52:08 -04:00
Henrik Lissner
95f40c62ab Add doom/bumpify-diff & doom/commit-bumps commands
To make bumping things easier. Use M-x doom/commit-bumps to create a
pre-filled bump commit in magit. Use M-x doom/bumpify-diff to scrape the
current buffer (assuming it's a diff buffer) and copy a bump commit
message to your clipboard.
2021-07-11 17:52:08 -04:00
Henrik Lissner
8da669adf0 Fix #5253: error if message is called with nil arg 2021-07-10 19:41:13 -04:00