Commit graph

33 commits

Author SHA1 Message Date
Vincent Ambo
3a719993fc fix(emacs.d): Change binding for ivy-browse-repositories
This avoids a conflict with some work tooling.
2019-12-17 00:38:18 +00:00
Vincent Ambo
0b6365efe5 fix(emacs): withLocalEmacs now loads packages via $EMACSLOADPATH
For some reason setting the initial load-path via `--directory` does
not work and leads to an Emacs without any packages.
2019-12-17 00:37:49 +00:00
Vincent Ambo
05168b9a3c feat(emacs): Add 'withLocalEmacs' override function
This function makes it possible to build an Emacs instance that,
instead of launching an Emacs built by Nix, configures an Emacs
already present on the system to use the packages built by Nix.

This **requires** that the versions of the two Emacsen (i.e. the one
used by Nix to build and the one used to run the packages) are kept in
sync, otherwise byte-code incompatibilities may lead to undefined
behaviour.
2019-12-16 23:57:32 +00:00
Vincent Ambo
43f07099a7 feat(emacs): Install 'request.el', an HTTP client 2019-12-16 23:57:17 +00:00
Vincent Ambo
99909ddd04 feat(emacs): Add withLocalConfig override function
This function makes it possible to pass in a folder with additional
local configuration from somewhere downstream.
2019-12-16 13:33:29 +00:00
Vincent Ambo
6ae799e8c8 feat(emacs): Make list of packages overridable
Exposes an `overrideEmacs` which can take a package function that
receives the current package list and can make arbitrary modifications
to it.

This makes it possible for me to maintain a private overlay for e.g.
work purposes with packages that should not be visible in my public
repos.
2019-12-16 11:59:07 +00:00
Vincent Ambo
67a9b3cc52 feat(emacs.d): Install refine 2019-12-16 11:38:22 +00:00
Vincent Ambo
e5839306f8 fix(emacs.d): Set correct magit-repository-directories path
This was set to my old home directory name from a different machine
and I had low-key been wondering why it didn't work, but not enough to
go do something about it.
2019-12-16 10:04:46 +00:00
Vincent Ambo
20ef6710e0 fix(emacs.d): Only highlight current line in prog-modes
This is extremely annoying in vterms, so now it's gone!
2019-12-16 03:56:12 +00:00
Vincent Ambo
e991834275 feat(emacs.d): Install and configure emacs-libvterm
This incredible package provides a fully functional, libvterm based
terminal emulator inside of Emacs.

Killer feature: It's possible to switch the buffer into a full Emacs
text mode (read-only) for selections and such.
2019-12-16 03:51:28 +00:00
Vincent Ambo
458163910b chore(emacs.d): Use local term-switcher package 2019-12-15 22:55:43 +00:00
Vincent Ambo
f34c82f765 refactor(emacs-pkgs): Extract term-switcher into separate emacs pkg 2019-12-15 22:54:58 +00:00
Vincent Ambo
9f8542fe75 chore(emacs.d): Remove smartparens
I actually find a lot of its behaviour very annoying, rather than
smart. Good old electric-pair-mode usually does what I want.
2019-12-15 22:54:58 +00:00
Vincent Ambo
97555884e2 fix(emacs.d): Fix uses use-package's :config instead of :init
In several places I used `:init` instead of `:config` and things
worked due to lazy loading anyways.

That's no excuse not to fix it though ...
2019-12-15 22:54:58 +00:00
Vincent Ambo
6ee061e205 refactor(emacs.d): Use dottime from my dottime package
Instead of locally advicing format-time-string, use my dottime
package.
2019-12-15 22:54:58 +00:00
Vincent Ambo
02e2877193 chore(emacs): Move carp-mode to third-party 2019-12-15 20:55:46 +00:00
Vincent Ambo
00c9060c2f feat(emacs.d): Introduce custom mc/mark-dwim cursor marker
Adds a "do what I mean" multiple-cursor selection with the logic that
I find most useful:

* If there is no active region, mark the next line (or lines, based on
  prefix argument)
* If there is an active region that spans multiple lines, call
  `mc/edit-lines`
* If there is an active region on a single line, trigger a custom
  selection hydra with functionality equivalent to
  `mc/mark-more-like-this-extended` but a slightly improved user
  experience

Hopefully this will make it easier to get into the habit of actually
using multiple-cursors without calling the mc commands via M-x
2019-12-15 17:13:17 +00:00
Vincent Ambo
895deabb3a chore(emacs.d): Comment out not-currently-used email bindings 2019-12-15 17:09:39 +00:00
Vincent Ambo
f69dfbc40e fix(emacs.d): Fix loading of custom.el 2019-12-14 17:15:47 +00:00
Vincent Ambo
c8bf0f9008 feat(emacs.d): Add function to open depot in magit 2019-12-14 17:07:25 +00:00
Vincent Ambo
7315ca331e chore(emacs.d): Clean up <tab> bindings
One simple rule to rule them all: In prog-mode, <tab> tries to invoke
company.
2019-12-14 15:59:20 +00:00
Vincent Ambo
9df9fafd82 fix(emacs.d): Let emacs write to customize configuration
Configures Emacs' `customize` to write directly to my Emacs
configuration. This comes with the caveat that the new config will
only be loaded if my Emacs is rebuilt.
2019-12-14 15:38:03 +00:00
Vincent Ambo
fadf0619eb feat(tools/emacs): Build fully pre-configured Emacs
Builds an Emacs that is not only configured with the required packages
but with the entire Emacs configuration for my personal setup.

This means that `nix-env -iA tools.emacs` will install a
fully-configured Emacs that can be launched as the window manager from
my ~/.xsession.
2019-12-14 15:25:04 +00:00
Vincent Ambo
7d03ab7140 chore(emacs.d): Move init/* to config/* 2019-12-14 15:24:53 +00:00
Vincent Ambo
1584607fb9 chore: Remove some configuration from a previous life 2019-12-14 14:56:13 +00:00
Vincent Ambo
bd7903815d feat(emacs.d): Load local Emacs configuration if present
This allows me to have local Emacs configuration that is tracked
separately from the rest.
2019-12-14 13:35:03 +00:00
Vincent Ambo
c490bbf4b3 chore(emacs.d): Import several months of privately tracked changes
These changes were made in a fork of my configuration that is not
publicly available and detailed history will not be included in this
public commit.
2019-12-14 13:23:20 +00:00
Vincent Ambo
1f204f2891 feat(emacs.d): Display modeline time in dottime
See dotti.me for more information about dottime.

<3 edef
2019-12-14 13:22:28 +00:00
Vincent Ambo
c1ba41a62d feat(emacs.d): Generalise counsel terminal selector
This makes it possible to use my terminal selector with any X11
terminal, configurable via two simple variables.
2019-12-14 13:21:12 +00:00
Vincent Ambo
2b80265a1f refactor(emacs): Rewrite derivation to match depot layout 2019-12-14 12:47:07 +00:00
Vincent Ambo
863f5b146d chore(emacs): Move Nix derivation for building Emacs over from infra 2019-12-14 11:57:11 +00:00
Vincent Ambo
a80ebfb067 docs(emacs): Update README file 2019-12-14 11:32:54 +00:00
Vincent Ambo
15c61c0bee chore(emacs): Move emacs config to tools/emacs 2019-12-14 11:30:56 +00:00