Skip to content

Instantly share code, notes, and snippets.

View rayjanoka's full-sized avatar

Ray rayjanoka

View GitHub Profile
@janfri
janfri / gist:a3e61731864a63554ba6f32bdc7179aa
Last active June 13, 2024 15:19
Install sqlite-pcre on OSX
brew install sqlite pcre
git clone https://github.com/ralight/sqlite3-pcre.git
cd sqlite3-pcre
cc -shared -o pcre.so -I/usr/local/opt/pcre/include -fPIC -W -Werror pcre.c -L/usr/local/opt/pcre/lib -lpcre
echo ".load '`pwd`/pcre.so'" >> ~/.sqliterc
@Kangaroux
Kangaroux / gist:46bb853f13a637c071b1f890e1217724
Created July 16, 2020 01:24
Disable automatic audio device switching for linux, ubuntu (USB, controller, dualshock)
# If you want to stop your system from automatically switching audio devices,
# there is a simple edit to your PulseAudio config to disable that feature.
# Open PulseAudio config
sudo vim /etc/pulse/default.pa
# Comment out the line with "load-module module-switch-on-connect"
# Restart PulseAudio
pulseaudio -k
@vyaslav
vyaslav / add_to_bashrc.sh
Created October 10, 2020 19:32
aliases for kubectl with autocomplete
source <(kubectl completion bash)
__start_kubectl_cust()
{
local cur prev words cword
declare -A flaghash 2>/dev/null || :
if declare -F _init_completion >/dev/null 2>&1; then
_init_completion -s || return
else
__kubectl_init_completion -n "=" || return
fi
@Kenterfie
Kenterfie / terradiff
Created August 1, 2023 18:43
Small python script to make terraform plan outputs for terraform helm_release values better readable
#!/bin/env python3
#
# TERRADIFF
#
# Small script to convert EOT diffs into single line diffs to make them easier to read
#
# How to use
# terraform plan | terradiff
#