Commit graph

11 commits

Author SHA1 Message Date
William Carroll
837cfe07c7 Rename dotfiles -> briefcase
Renaming my mono-repo briefcase.

I first introduced this commit in master, but it introduced a bug where one of
two things would happen:

1. Emacs wouldn't start and would crash X.
2. Emacs would start but my keyboard wouldn't work.

I learned some valuable debugging skills in the process. Here are some of them:

When my keyboard was broken, I wanted to control my computer using my
laptop. Thankfully this is possible by using `x2x`, which forward X events from
the SSH client to the SSH host.

```shell
> # I'm unsure if this is the *exact* command
> ssh -X desktop x2x -west :0.0
```

Git commit-local bisecting. I didn't need to do a `git bisect` because I knew
which commit introduced the bug; it was HEAD, master. But -- as you can see from
the size of this commit -- there are many changes involved. I wanted to binary
search through the changes, so I did the following workflow using `magit`:

- git reset --soft HEAD^
- git stash 1/2 of the files changed
- re-run `nix-env -f ~/briefcase/emacs -i`
- restart X session
- If the problem persists, the bug exists in the non-stashed files. Repeat the
  process until you find the bug.

In my case, the bug was pretty benign. Calling `(exwm/switch "Dotfiles")` at the
bottom of `window-manager.el` was failing because "Dotfiles" is the name of a
non-existent workspace; it should've been `(exwm/switch "Briefcase")`.

There may have been more problems. I changed a few other things along the way,
including exposing the env vars BRIEFCASE to `wpcarros-emacs` inside of
`emacs/default.nix`.

The important part is that this was a valuable learning opportunity, and I'm
glad that I'm walking away from the two days of "lost productivity" feeling
actually productive.
2020-01-31 15:27:48 +00:00
William Carroll
d28690d814 Remove PAGER prefix from hgst abbreviation
1. This isn't correct fish syntax.
2. I'm not sure that I need this.
2020-01-28 11:35:02 +00:00
William Carroll
fb51c8b458 Support nix-eval fish function
Wrapping the `nix eval` incantation in a fish function for two reasons:
1. Document that this is how to evaluate Nix from a file.
2. Provide a more ergonomic way of evaluating Nix from a file.
2020-01-27 11:39:02 +00:00
William Carroll
16dfa55df7 Ensure EDITOR and similar variables work with EXWM setup
After some confusion about my `emacsclient` is currently working as
expected. Perhaps it always did. I had `emacs --daemon` in my
`~/.xsessionrc.shared` for awhile, which may have confused
`emacsclient`. Whatever happened, I'm glad it's working now.
2020-01-22 21:13:06 +00:00
William Carroll
2640397131 Drop support for nix_find fish function
This function was causing problems with my Emacs. For example, when I ran
`wpc/find-file`, which is bound <leader>f and a KBD that I call frequently, the
internals would startup fish with my configuration file. Then `nix_find
autojump` would fail and the entire command would error. To make things worse,
the error was a bit opaque.

TODO: Why do certain commands `counsel-projectile-find-file` startup fish and
load my configuration file? I'd prefer it used something like bash and didn't
attempt to load a configuration file since that would most likely slow things
down.
2020-01-17 10:56:21 +00:00
William Carroll
2515304c77 Prefer eval to source for direnv in config.fish
Calling `source` on `(direnv hook fish)` was creating startup problems with
fish. These problems leaked into a few of my Emacs file-searching commands as
well, which was pretty irritating for awhile. I'm still unsure of the
differences between `eval` and `source`. I'm moving on for now.
2020-01-17 10:56:21 +00:00
William Carroll
7175d230c2 Nixify fish configuration
This isn't 100% usable, but it works. You can build it with `nix-env` and then
run it with `wpcarros-fish`.
2020-01-17 10:56:21 +00:00
William Carroll
73e988c298 Define nix_find command in fish
Defining a function for outputting the /nix/store path to a package built with
Nix.
2020-01-06 15:25:25 +00:00
William Carroll
7ae17daa98 Drop support for i3
While I first switched to EXWM warily and thinking it would only be temporary,
it seems like this switch is here to stay. It turns out that EXWM was exactly
the integration I've been looking for. How serendipitous it that I found it when
I did.

Thank you, @tazjin.
2020-01-06 15:25:25 +00:00
William Carroll
7bb4201905 Support more fish abbr's for git
I'm sure that there is a fish package that supports git aliases or
abbreviations. This time, I'm preferring to write my own.

Side note: The more that I use fish's abbreviations, the less that I like them
-- at least for the way in which I'm using them.
2020-01-06 15:25:25 +00:00
William Carroll
f739534203 Support fish shell!
After some back-and-forth, I'm trialing fish shell instead of zsh as my default
shell. For now, I'm porting the aliases.zsh into config.fish -- defining them as
abbreviations instead of aliases; this preference may change. See the commentary
in config.fish for more information.

A spent a lot of time in zsh and built much configuration, so supporting fish
may take considerable time. Here's some work that remains:

TODO:
- Port functions.zsh
- Port variables.zsh
- Port zle.zsh
2019-12-24 15:21:34 +00:00