Skip to content

Instantly share code, notes, and snippets.

View lindhe's full-sized avatar
🦥

Andreas Lindhé lindhe

🦥
View GitHub Profile
@lindhe
lindhe / NOTES.md
Last active September 12, 2024 15:03
Backup requirements

Backup requirements

Different applications have different requirements when it comes to being backed up. Some applications works perfectly fine if a disk snapshot is taken, while others may require to first enter some sort of maintenance mode first to ensure data consistency. These are my personal notes on what requirements different software stacks has. I make no promises that any of this is true. What I do promise you is that this is not an exhaustive list.

OpenSearch (ElasticSearch)

@lindhe
lindhe / work.gitconfig
Created August 4, 2024 14:23
A gitconfig to dynamically include different configs for different repos.
[user]
email = primary-work-email@example.com
[includeIf "gitdir:~/git/foo/"]
path = foo.gitconfig
[includeIf "hasconfig:remote.*.url:https://foo.example.com/**"]
path = foo.gitconfig
[includeIf "hasconfig:remote.*.url:git@foo.example.com:*/*"]
path = foo.gitconfig
@lindhe
lindhe / example-crd.yaml
Created March 5, 2024 08:20
Example CRD
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
name: foos.example.lindhe.io
spec:
group: example.lindhe.io
versions:
- name: v1
served: true
storage: true
@lindhe
lindhe / repo_split.md
Created October 23, 2023 13:00
Splitting a repo

Splitting a repo

Here is a recepie for how to split a repo.

If you have a repo that you want to split in twine, life can be simple! At least if you have been a good boy and kept the different parts in different subdirectories to begin with…

This is all you have to do:

@lindhe
lindhe / lsp.log
Created August 11, 2023 09:07
rust_analyzer lspconfig neovim ascii color codes issue
[START][2023-08-11 11:04:33] LSP logging initiated
[INFO][2023-08-11 11:04:33] .../vim/lsp/rpc.lua:634 "Starting RPC client" { args = {}, cmd = "/home/andreas/.local/share/nvim/mason/bin/rust-analyzer", extra = { cwd = "/home/andreas/tmp/foo" }}
[DEBUG][2023-08-11 11:04:33] .../vim/lsp/rpc.lua:261 "rpc.send" { id = 1, jsonrpc = "2.0", method = "initialize", params = { capabilities = { experimental = { serverStatusNotification = true }, general = { positionEncodings = { "utf-16" } }, textDocument = { callHierarchy = { dynamicRegistration = false }, codeAction = { codeActionLiteralSupport = { codeActionKind = { valueSet = { "", "quickfix", "refactor", "refactor.extract", "refactor.inline", "refactor.rewrite", "source", "source.organizeImports" } } }, dataSupport = true, dynamicRegistration = true, isPreferredSupport = true, resolveSupport = {
@lindhe
lindhe / settings.json
Last active November 25, 2023 12:19
Windows Terminal configuration file
{
"$help": "https://aka.ms/terminal-documentation",
"$schema": "https://aka.ms/terminal-profiles-schema",
"actions":
[
{
"command":
{
"action": "resizePane",
"direction": "left"
@lindhe
lindhe / wsl.conf
Last active October 5, 2023 18:50
[boot]
command = "mount --make-rshared /"
command = "ntpdate ntp.ubuntu.com"
[network]
hostname = wsl
generateResolvConf = false
@lindhe
lindhe / gestures.ahk
Last active July 14, 2022 15:58
AutoHotKey (AHK)
; Place me in %APPDATA%\Microsoft\Windows\Start Menu\Programs\Startup
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
#Warn ; Enable warnings to assist with detecting common errors.
SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.
; Map touchpad gestures to custom keybindings (Ctrl+F1, ...)
^F1:: Run wt
^F2:: Run Code
@lindhe
lindhe / kubeapps_icon_error.log
Created April 17, 2020 14:09
Log of curl to problematic icon in Kubeapps
$ curl -vvv https://emojipedia-us.s3.dualstack.us-west-1.amazonaws.com/thumbs/120/microsoft/209/negative-squared-latin-capital-letter-b_1f171.png --output - > /dev/null
* Expire in 0 ms for 6 (transfer 0x55a5970caf50)
* Expire in 1 ms for 1 (transfer 0x55a5970caf50)
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0* Expire in 0 ms for 1 (transfer 0x55a5970caf50)
* Expire in 1 ms for 1 (transfer 0x55a5970caf50)
* Expire in 0 ms for 1 (transfer 0x55a5970caf50)
* Expire in 0 ms for 1 (transfer 0x55a5970caf50)
* Expire in 1 ms for 1 (transfer 0x55a5970caf50)
@lindhe
lindhe / userChrome.css
Created November 12, 2019 22:04
Thunderbird userChrome.css for reasonable zoom level
/*
* PUT THIS IN ~/.thudnerbird/[profile_name]/chrome/userChrome.css
*
* And remember to set layout.css.devPixelsPerPx to 1.2 in about:config
*
*/
/*
* Do not remove the @namespace line -- it's required.
*/