Skip to content

Instantly share code, notes, and snippets.

View damien's full-sized avatar
🤝
Open for business! Hire me for your project at https://mindglob.com

Damien Wilson damien

🤝
Open for business! Hire me for your project at https://mindglob.com
View GitHub Profile
@matthiassb
matthiassb / dns-sync.sh
Last active March 20, 2024 12:12
Init.d script for keeping WSL resolv.conf in-sync with Windows
#! /bin/bash
### BEGIN INIT INFO
# Provides: dns-sync
# Required-Start:
# Required-Stop:
# Default-Start: S
# Default-Stop:
# Short-Description: Synchronizes /etc/resolv.conf in WLS with Windows DNS - Matthias Brooks
### END INIT INFO
# Source global definitions
if [ -f /etc/bashrc ]; then
. /etc/bashrc
fi
export KAFKA_URL='kafka.service.consul:9092'
export ZOOKEEPER_URL='zookeeper.service.consul:2181'
export SCHEMA_REGISTRY_URL='http://schema-registry.localservice'
export FC_CONNECT_URL='http://workers-fc-connect.service.consul'
@lelandbatey
lelandbatey / whiteboardCleaner.md
Last active April 25, 2024 02:01
Whiteboard Picture Cleaner - Shell one-liner/script to clean up and beautify photos of whiteboards!

Description

This simple script will take a picture of a whiteboard and use parts of the ImageMagick library with sane defaults to clean it up tremendously.

The script is here:

#!/bin/bash
convert "$1" -morphology Convolve DoG:15,100,0 -negate -normalize -blur 0x1 -channel RBG -level 60%,91%,0.1 "$2"

Results