Show newer

On the off chance that this is an original idea, I’d like to coin “pessimistic versioning branches”.

Show thread

Vim’s package manager doesn’t really support version constraints, as it’s mostly used with git submodules.

One way to fix that would be plugin repositories with branches like 1.x or 1.1.x, and have users `git submodule add --branch 1.x` to not break their setups. 🤔

I gave in. Instead of using netrw and ctags to navigate like I said I would, I installed fzf again. I’m really liking the new-to-me preview window. I’ve also added fzf.vim highlight colors to Dim ( to limit it to using ANSI colors.

Show thread

This is becoming quite the list! Thanks for your recommendations, everybody. I’ll have enough for a couple more bike rides (but feel free to keep them coming).

Help me out, here. What’s your favorite podcast? I’m just about to get ready to bike home, so I could do with a few recommendations.

Another great thing about coc.nvim is its ability to automatically format files on save through its plugins.

I've turned on automatic formatting for Elixir and Rust files by adding both to `coc.preferences.formatOnSaveFiletypes` in `coc-settings.json`.

Show thread

Just received an unsolicited email from [email API service] to invite me to their webinar on deliverability. It had a working unsubscribe link (although I have to unsubscribe from every type of these, apparently) and a physical address in it, so it’s all good, I guess. 🤷‍♂️

“How’s that for a quick turnaround? From lunch to patch release in 22 minutes!”

With Twitter now requiring developers to sign up and have their idea reviewed before they get an API token, we’re missing out on some really stupid bots.

Like the “rt for reach”-retweeting bot I wanted to build, which would have been the most fun you can have with recursion. 🤷‍♂️

That’s it for now! Please take it for a spin and let me know if you find something I can improve on.

Have a smart configuration in your ~/.vimrc yourself? Turn it into a plugin! A good place to start (and the source of most of my VimL-fu) is learnvimscriptthehardway.steve.

Show thread

That’s it! Sourcing our plugin once more, we can switch macOS’s appearance to dark mode and have Vim automatically follow when it gains focus.

Show thread

To add our autocommand to our plugin, we’ll wrap it in an `augroup` to make sure it’s reloaded properly when we load the plugin multiple times, for whatever reason:

augroup nightfall
autocmd FocusGained,BufEnter * call UpdateBackground()
augroup END

Show thread

We’ll use autocommands, which fire automatically when a certain trigger happens. In our case, we’ll call our function when Vim gains focus (`FocusGained`) or when entering a buffer (`BufEnter`):

:autocmd FocusGained,BufEnter * call UpdateBackground()

Show thread

Let’s try our function. To load our file, call `:source %` (`%` is a shortcut for the current file).

Then, we can switch the background by running `:call UpdateBackground()`. It should switch to match macOS’s background mode. 🎉

Show thread

In nightfall.vim, we'll define a function:

function UpdateBackground()
if system("defaults read -g AppleInterfaceStyle") == "Dark\n"
if &bg == "light" | set bg=dark | endif
if &bg == "dark" | set bg=light | endif

Show thread
Show older

Server run by the main developers of the project 🐘 It is not focused on any particular niche interest - everyone is welcome as long as you follow our code of conduct!