Commit Graph

50 Commits

Author SHA1 Message Date
Henrik Lissner
da2247e3d6
Remove redundant +default/lsp-format-region-or-buffer command 2020-05-06 15:14:16 -04:00
Henrik Lissner
493b85c396
Wait a second before restarting server
sit-for doesn't necessarily do so if emacs recieves input during.
2020-02-11 03:21:44 -05:00
Henrik Lissner
27bf3c85b5
Generalize thing-at-point & region functions 2020-01-03 02:39:47 -05:00
Henrik Lissner
d1becfce89
config/default: reorganize autoloads 2019-12-23 17:20:19 -05:00
Henrik Lissner
322bca710a
General refactors & reformatting 2019-12-20 00:59:52 -05:00
Henrik Lissner
a999a0ddd6
General refactors & comment revision 2019-12-19 14:51:34 -05:00
Henrik Lissner
6f1665563c
Error if +default/lsp-format-region-or-buffer in non-lsp buffer 2019-12-04 23:32:13 -05:00
Henrik Lissner
bd4755123f
Replace */tasks commands w/ magit-todos-list
If we want ivy/helm interfaces to it, we should use magit-todos as a
backend.
2019-11-15 22:17:31 -05:00
Henrik Lissner
3d26befd47
Move 'SPC /' to 'SPC s'
/ is harder to reach than s, more so on certain keyboard layouts, so
'SPC /' has been moved to 'SPC s'. Similar has been done to other / and
. leader keybinds. Whats more, 'SPC s' for snippets is seldomly used and
available through other means, so it was removed.

Summary:
- 'SPC /' moved to 'SPC s'
- 'SPC f .' and 'SPC f /' moved to 'SPC f f' and 'SPC f F', respectively
- 'SPC p /' removed (already on 'SPC p f')
- 'SPC p ?' moved to 'SPC p F' (doom/find-file-in-other-projects)
- 'SPC n /' moved to 'SPC n s' (+default/org-notes-search)
- 'SPC n .' removed (already on 'SPC n N')
- Remove 'SPC s' prefix for snippets. Was seldomly used and most of its
  commands are available on other keys or through `M-x`, which is
  enough.
2019-11-15 22:17:30 -05:00
Henrik Lissner
21eeb5c1a5
Bind 'SPC i {f,F}' to insert current file name/path 2019-11-15 22:17:30 -05:00
Henrik Lissner
64222c69c8
Fix wrong-number-of-arguments on newline-and-indent
And ensure all custom comment-line-break-function functions its
argument requirements.
2019-11-12 15:24:02 -05:00
Henrik Lissner
f4e641950c
Minor, general refactors 2019-11-05 18:46:07 -05:00
Henrik Lissner
e47d357e56
Fix regexp quoting in +default/search-notes-for-symbol-at-point 2019-11-05 18:44:19 -05:00
Henrik Lissner
3d21f4ef5e
Add +default/restart-server command
Its keybind on 'SPC q d' was already pushed in ace1eceab
2019-10-26 23:44:29 -04:00
Henrik Lissner
d246307f87
config/default: bind SPC c {F,i,r} to LSP commands
These are experimental keybinds. I'm looking for a way to integrate
LSP's formatter commands (and lsp-organize-imports) into the :editor
format module. And a way to unify refactoring commands (perhaps with emr
or erefactor), including lsp-rename.

- 'SPC c F' -> format region or buffer
- 'SPC c i' -> organize imports
- 'SPC c r' -> rename symbol at point

Addresses #1417
2019-10-22 19:55:50 -04:00
Henrik Lissner
f79d191701
completion/ivy: use region is active & fix regex quoting
Fixes #1930
2019-10-22 12:36:43 -04:00
Henrik Lissner
9634a3860e
config/default: invoke magit-todos-list on SPC p t
Before falling back to +ivy/tasks and helm/tasks (not implemented yet).
2019-10-20 19:57:27 -04:00
Henrik Lissner
e10cd8cf2e
Insult byte-compiler's mom
Yeah, that shut him up.
2019-09-20 23:10:53 -04:00
Henrik Lissner
2d365619cd
General refactor & cleanup, across the board 2019-09-13 22:00:34 -04:00
Henrik Lissner
f90cf1f974
Fix +default/org-notes-headlines 2019-08-28 22:08:13 -04:00
Henrik Lissner
f4a11fd437
Fix #1679: newline-and-indent advice not deleting trailing whitespace 2019-08-21 00:29:12 -04:00
Henrik Lissner
b330728032
Fix #1575: SPC * error when no symbol at point 2019-08-07 18:37:02 -04:00
Henrik Lissner
9ffb740b0f
Add SPC / D and SPC / P keybinds #1531
For searching from another directory/project (prompted)
2019-07-02 14:13:30 +02:00
Henrik Lissner
65efbc4204
Fix prompts for search-{cwd,project} commands 2019-07-02 14:06:31 +02:00
Henrik Lissner
57bd7a385e
Fix typo in +default/org-notes-headlines 2019-05-20 21:09:10 -04:00
Henrik Lissner
2e6d8be6fc
Rethink SPC n keybinds and add new ones
Adds the following keybinds:

SPC n .    Browses org-directory
SPC n /    Text search in org-directory
SPC n *    Text search in org-directory with symbol at point
SPC n h    Jump to org headline in org-agenda-files
2019-05-17 23:57:24 -04:00
Henrik Lissner
b821bfca1f
Fix newline-and-indent advice forgetting indentation
e.g. in python-mode docstrings. The point-in-string case is no longer
handled, because indent-according-to-mode handles it properly already.
2019-05-15 15:22:08 -04:00
Henrik Lissner
3c01de8876
Fix #1320: generalize SPC *
Was formerly using ripgrep, and only ripgrep.
2019-04-10 20:14:50 -04:00
Henrik Lissner
3f751c1179
Correctly regexp-quote symbol on SPC * 2019-04-10 20:11:41 -04:00
Henrik Lissner
5e8687cd45
Add SPC * for project-searching symbol at point 2019-04-10 18:57:57 -04:00
Henrik Lissner
f2b8280b2a
Add +default/search-from-cwd & +default/search-project 2019-03-08 04:25:45 -05:00
Henrik Lissner
d46bb287ae
General refactor of Doom core
- Code reduction and refactor across the board (cull unneeded minor
  advise, hooks and hacks or update them)
- Revise outdated comments and docstrings
- Reorganize core autoload libraries
- Remove large file check (Emacs already has a built-in one, which we
  augment to be even more performant when it does kick in)
- helpful.el can now be disabled completely through package!
2019-03-02 01:34:19 -05:00
Henrik Lissner
acddf6a047
Move delete-backward-char & newline-and-indent advice
To config/default; the only place it is used.
2019-02-22 00:25:30 -05:00
Henrik Lissner
d46c2582d0
Fix 'not an evil-paste' error on SPC i y #1095
yank-pop and evil-paste-pop are picky little buggers, we need our own
delegate.
2019-02-12 00:51:07 -05:00
Henrik Lissner
d79817edeb
Fix unbalanced parens in +default/project-tasks 2019-02-12 00:47:15 -05:00
Henrik Lissner
3694b0d411
Standardize M-RET/M-S-RET as an "add new item" key 2019-01-21 22:07:31 -05:00
Henrik Lissner
9f455edcdf
Add interactive form to +default/project-tasks
It is required for key-bound commands. Also added a docstring.
2018-12-31 15:28:35 -05:00
Oleksii Filonenko
9a0da588d9
Add helm to project tasks 2018-12-28 03:31:03 +02:00
Henrik Lissner
4daa9271a0
Introduce general.el & rewrite map!
+ Now uses an overriding keymap for leader keys, so that it is always
  available, even outside of normal/visual states. In insert/emacs
  states, or in sessions where evil is absent, an alternative prefix is
  used for leader/localleader keys. See these variables:
  + doom-leader-prefix
  + doom-leader-alt-prefix
  + doom-localleader-prefix
  + doom-localleader-alt-prefix
+ Keybinds now support alternative prefixes through the new :alt-prefix
  property. This is useful for non-evil users and non-normal evil
  states. By default, this is M-SPC (leader) and M-SPC m (localleader).
+ Removed +evil-commands flag from config/default (moved to
  feature/evil/+commands.el).
+ config/default/+bindings.el has been split into
  config/default/+{evil,emacs}-bindings.el, which one is loaded depends
  on whether evil is present or not. The latter is blank, but will soon
  be populated with a keybinding scheme for non-evil users (perhaps
  inspired by #641).
+ The define-key! macro has been replaced; it is now an alias for
  general-def.
+ Added unmap! as an alias for general-unbind.
+ The following modifier key conventions are now enforced for
  consistency, across all OSes:
    alt/option      = meta
    windows/command = super
  It used to be
    alt/option      = alt
    windows/command = meta
  Many of the default keybinds have been updated to reflect this switch,
  but it is likely to affect personal meta/super keybinds!

The map! macro has also been rewritten to use general-define-key. Here
is what has been changed:

+ map! no longer works with characters, e.g. (map! ?x #'do-something) is
  no longer supported. Keys must be kbd-able strings like "C-c x" or
  vectors like [?C-c ?x].
+ The :map and :map* properties are now the same thing. If specified
  keymaps aren't defined when binding keys, it is automatically
  deferred.
+ The way you bind local keybinds has changed:

    ;; Don't do this
    (map! :l "a" #'func-a
          :l "b" #'func-b)
    ;; Do this
    (map! :map 'local "a" #'func-a
                      "b" #'func-b)

+ map! now supports the following new blocks:
  + (:if COND THEN-FORM ELSE-FORM...)
  + (:alt-prefix PREFIX KEYS...) -- this prefix will be used for
    non-normal evil states. Equivalent to :non-normal-prefix in general.
+ The way you declare a which-key label for a prefix key has changed:

    ;; before
    (map! :desc "label" :prefix "a" ...)
    ;; now
    (map! :prefix ("a" . "label") ...)

+ It used to be that map! supported binding a key to a key sequence,
  like so:

    (map! "a" [?x])  ; pressing a is like pressing x

  This functionality was removed *temporarily* while I figure out the
  implementation.

Addresses: #448, #814, #860
Mentioned in: #940
2018-12-22 04:14:43 -05:00
Henrik Lissner
91b76d8437
Move default snippets library to feature/snippets
Removes the +snippets flag from config/default. The default snippets can
be disabled by disabling the emacs-snippets package.
2018-11-02 18:43:44 -04:00
Henrik Lissner
dc8c01f17f
Add +default/newline alias
Forgot to add it in 08beff91
2018-06-28 14:46:33 +02:00
Henrik Lissner
6693db48af
Mark +org-dir obsolete (use org-directory instead)
I prefer not to invent new variables when they aren't strictly
necessary. org-directory is one such variable (although the other path
variables are still necessary).
2018-06-15 01:05:22 +02:00
Henrik Lissner
82f240ffc9
Bind SPC h w to +default/man-or-woman #639
Woman is essentially elisp-only Man; useful for systems without
man (Windows, particularly).
2018-06-01 12:13:56 +02:00
Henrik Lissner
1b8dce260b
config/default: restore find-in-snippets command #597
And conditionally bind snippets keybinds
2018-05-21 18:34:33 +02:00
Henrik Lissner
355b4b1364
💥 Replace config/private w/ first-class support
The config/private module has been removed. ~/.doom.d (or
~/.config/doom; whichever is detected first) is now a first class
citizen of Doom and should just work(tm).

Your init.el only needs to contain:

  (require 'core (concat user-emacs-directory "core/core"))

And you may place your doom! block in ~/.doom.d/init.el (or
~/.config/doom/init.el).
2018-04-03 03:07:30 -04:00
Henrik Lissner
aeb030e391
config/default: new +default/compile command (bound to M-b) 2018-03-14 19:45:52 -04:00
Henrik Lissner
9d55d1e1ba
config/default: remove private macros (unnecessary complexity) 2018-03-01 04:15:09 -05:00
Henrik Lissner
873ad22894
config/default: make private macros private again! 2018-03-01 04:09:39 -05:00
Henrik Lissner
22e9452104
config/default: +default/find-in-snippets => +default/browse-snippets 2018-02-18 03:12:38 -05:00
Henrik Lissner
6d7db48dc1
💥 Move :private modules to :config 2018-02-14 23:36:27 -05:00