Skip to content

Instantly share code, notes, and snippets.

@lludlow
lludlow / solarize-terminator.sh
Created February 28, 2017 21:12 — forked from kynan/solarize-terminator.sh
shell script for setting terminator color palette to use Solarized theme
#!/bin/bash
#
# Shell script that configures terminator to use solarized theme
# colors. Assumes a single terminator profile. Tested on Ubuntu 11.10.
#
# Solarized theme: http://ethanschoonover.com/solarized
#
# Original from 79CetiB:
# http://www.reddit.com/r/emacs/comments/npfmv/i_need_some_help_with_the_solarized_theme_in_a/c3b4mds
#

Keybase proof

I hereby claim:

  • I am madbuda on github.
  • I am lludlow (https://keybase.io/lludlow) on keybase.
  • I have a public key ASCEh80hbAnh8nhH9xpVWqTqOu0uI32bxBM4UdxRJlfWMgo

To claim this, I am signing this object:

@lludlow
lludlow / adblock-hostsfile.sh
Created April 20, 2017 14:48
dnsmasq ad blocking
#!/bin/bash
# Modified Pi-hole script to generate a generic hosts file
# for use with dnsmasq's addn-hosts configuration
# original : https://github.com/jacobsalmela/pi-hole/blob/master/gravity-adv.sh
# Address to send ads to. This could possibily be removed, but may be useful for debugging purposes?
destinationIP="0.0.0.0"
outlist='/etc/final_blocklist.txt'
tempoutlist="$outlist.tmp"
#include "stdafx.h"
#include "windivert.h"
#include <string>
#include <time.h>
using namespace std;
typedef struct
{
WINDIVERT_IPHDR ip;
@lludlow
lludlow / Readme.md
Created August 7, 2017 15:09
bulk delete your old repos or old forks

Use this trick to bulk delete your old repos or old forks

(Inspired by https://medium.com/@icanhazedit/clean-up-unused-github-rpositories-c2549294ee45#.3hwv4nxv5)

  1. Open in a new tab all to-be-deleted github repositores (Use the mouse’s middle click or Ctrl + Click) https://github.com/username?tab=repositories

  2. Use one tab https://chrome.google.com/webstore/detail/onetab/chphlpgkkbolifaimnlloiipkdnihall to shorten them to a list.

  3. Save that list to some path

  4. The list should be in the form of “ur_username\repo_name” per line. Use regex search (Sublime text could help). Search for ' :.*' and replace by empty.

@lludlow
lludlow / Brewfile
Created August 14, 2017 17:03
brewfile
##
# Brewfile by Joel Parker Henderson and SixArm.com
#
# CAUTION: THIS IS A WORK IN PROGRESS. USE AT YOUR OWN RISK.
#
# We use this Brewfile for our teams and their developer laptops.
#
# This file installs many apps, including office suites, multimedia suites,
# programming langauges and IDEs, unix utilities, and sysadmin tools.
#
@lludlow
lludlow / updateallbranches.sh
Created October 12, 2017 20:04
update fork from upstream origin
## Checkout all branches from remote as tracking branches.
UPSTREAM=$1
MYREPO=$2
usage() {
echo "Usage:"
echo "$0 <upstream-remote> <target-remote>"
echo ""
@lludlow
lludlow / docker-cleanup-resources.md
Created October 13, 2017 20:49 — forked from bastman/docker-cleanup-resources.md
docker cleanup guide: containers, images, volumes, networks

Docker - How to cleanup (unused) resources

Once in a while, you may need to cleanup resources (containers, volumes, images, networks) ...

delete volumes

// see: https://github.com/chadoe/docker-cleanup-volumes

$ docker volume rm $(docker volume ls -qf dangling=true)

$ docker volume ls -qf dangling=true | xargs -r docker volume rm

FROM ubuntu:16.04
ENV GIT_URL git://github.com/MyHush/hush.git
ENV HUSH_CONF /root/.hush/hush.conf
# install dependencies
RUN apt-get autoclean && apt-get autoremove && apt-get update && \
apt-get -qqy install --no-install-recommends build-essential \
automake ncurses-dev libcurl4-openssl-dev libssl-dev libgtest-dev \
@lludlow
lludlow / ansible.cfg
Created February 20, 2018 14:27
ansible config
# config file for ansible -- http://ansible.com/
# ==============================================
# nearly all parameters can be overridden in ansible-playbook
# or with command line flags. ansible will read ANSIBLE_CONFIG,
# ansible.cfg in the current working directory, .ansible.cfg in
# the home directory or /etc/ansible/ansible.cfg, whichever it
# finds first
[defaults]