Skip to content

Instantly share code, notes, and snippets.

View bartdorsey's full-sized avatar

Bart Dorsey bartdorsey

View GitHub Profile
@bartdorsey
bartdorsey / vscode-to-neovim.md
Created April 3, 2024 18:52
VSCode To Neovim Rosetta Stone

VSCode to Neovim Rosetta Stone

@bartdorsey
bartdorsey / neovim-lsp-glossary.md
Created February 5, 2024 18:15
Neovim LSP Glossary

Neovim LSP Glossary

When setting up Language Server Protocol on Neovim, what plugins do what can be pretty confusing. So this table is a list of the most common plugins people use and what they are and why they are.

Plugin Role Why?
lspconfig Configuring the language servers You can use neovim's built in vim.lsp.start() function, but often we don't know all the command line arguments and options needed to pass to that function, so lspconfig is really just a database of a bunch of configurations for lsps
mason Installing language servers Mason will automatically download and install the actual language server programs. This is optional because if you install an LSP server in your $PATH manually you don't necessarily need this
mason-lspconfig Automatically setting up lsps when you install them This glues lspconfig and mason together, So when an lsp is configured the setup function for it will be automatically called, not necessary if you want to manage your LSPs manually
@bartdorsey
bartdorsey / neovim-plugins.md
Last active January 19, 2024 20:07
Neovim must have plugins

Neovim must have plugins

This is my curated list of the neovim plugins I can't live without

Note: if you are just starting out, check out kickstart.nvim

  • Lazy.nvim - The plugin manager I use. Not to be confused with LazyVim the neovim distribution.
  • lspconfig - The must have plugin for configuring LSP support in neovim.
  • nvim-cmp - Completion engine for neovim. Without this you won't get autocomplete for anything
  • oil.nvim - A magical plugin which lets you browse and edit your files and folders like they are in an editor buffer
@bartdorsey
bartdorsey / command-line-utils.md
Last active January 19, 2024 19:39
Must have command line utilities

Must have command line utilities

This is my curated list of command line utilities that I can't live without

  • neovim - Enough said, you either use neovim, or you don't, I'm not going to tell you to use vim, but if you do, neovim is the way. See my neovim must have plugin list here
  • zsh - My shell of choice.
  • zoxide - zoxide is a fuzzy matching cd command. It will automatically remember commonly visited directories, and you can jump to them instantly.
  • fzf - fzf is a tool which will do fuzzy searching. Many of the other tools I use integrate fzf. For instance, zoxide's zi command uses this. You can also use it in your own shell aliases and scripts.
  • starship - Starship is a cross platform shell prompt. I use this so I can have the same prompt no matter which shell I'm using.
  • [lsd](https
@bartdorsey
bartdorsey / docker-inside-wsl.md
Last active January 18, 2024 19:08
Running Docker Inside WSL with systemd.

Running Docker inside WSL with systemd.

Why would you want to do this?

  • Because when you run docker desktop for Windows, it will be creating two WSL instances behind the scenes anyway. This will take up more resources than this method.
  • Docker desktop attempts to inject the docker commands into your existing WSL instance. It does this through a series of hacks that frankly are just complex and prone to breakage.
  • Bind mounts are from Linux to Linux. When you run Docker Desktop on Windows, you are bind mounting from the Windows filesystem to a Linux system. This can make things like hot reloading web frameworks not work very well. (this is because it can't recieve filesystem events when you save the files)

Why is this simpler?

local neovim = {
[[⠀⠀⠀⢀⡴⣂⠀⠀⠀⠀⠀⠀⠀⠀⢰⣄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀]],
[[⠀⢀⡴⣏⣷⡹⣆⡀⠀⠀⠀⠀⠀⠀⢸⣯⣷⣄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣀⣀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀]],
[[⣴⣻⣽⣻⣼⢳⡹⣖⡄⠀⠀⠀⠀⠀⢸⣷⢿⣾⢷⡄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠿⠿⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀ ]],
[[Γú»Γó╖Γú╗Γó╖Γú»Γó│Γí¥Γí╛Γú£ΓíåΓáÇΓáÇΓáÇΓáÇΓó╕Γú┐Γí┐Γú»Γú┐ΓíçΓáÇΓáÇΓáÇΓáÇΓáÇΓóÇΓíÇΓáÇΓúÇΓúñΓúñΓúÇΓáÇΓáÇΓáÇΓáÇΓáÇΓúÇΓúñΓúñΓúÇΓíÇΓáÇΓáÇΓáÇΓáÇΓóÇΓúáΓúñΓúñΓúÇΓíÇΓáÇΓóáΓúñΓúñΓáÇΓáÇΓáÇΓáÇΓóÇΓúñΓúñΓíäΓúñΓúñΓáÇΓóáΓúñΓíäΓúáΓúñΓú╢ΓúñΓíÇΓóÇΓúáΓú┤Γ
@bartdorsey
bartdorsey / docker-compose-cheatsheet.md
Last active December 2, 2022 22:43
Docker Compose Cheatsheet

Docker Compose Cheatsheet

Docker recently changed from a standalone command to a plugin. You might need to run docker-compose instead of docker compose depending on which version you have.

Starting all the containers at once in the background

docker compose up -d
@bartdorsey
bartdorsey / wsl-commands.md
Last active December 1, 2022 08:14
WSL Cheatsheet

WSL Cheatsheet

Powershell commands

Listing out your WSL machines

wsl -l -v
@bartdorsey
bartdorsey / how-to-play-minecraft.md
Last active October 27, 2022 19:22
How-to-play-minecraft.md

How to play minecraft

Learning Objectives

By the end of the presentation you should be able to

  • Explain how to move around the minecraft world
  • Explain how to collect resources
  • Explain why you need to collect and craft things in minecraft
  • Explain how to craft basic resources
@bartdorsey
bartdorsey / django-speed-run-part-1.md
Last active October 4, 2022 21:01
Django Speedrun Part 1

Django Speed run

In video gaming culture a speed run is where someone tries to play a video game all the way through as fast as they can. Turns out this is a great way to practice! So we are going to be setting up a basic django app from scratch as fast as we can.

We want to get to the point where we do the following as fast as possible.

  1. Create a project folder