Skip to content

Instantly share code, notes, and snippets.


Lewis Cowles Lewiscowles1986

View GitHub Profile
# program-specific xbindkeys bindings
# there's a tool called `autokey`, which does this, but unlike xbindkeys, it doesn't catch mouse buttons
# doesn't interfere with main xbindkeys
# `pacman -S xbindkeys xdotool`
# `sleep 3 && cat /proc/$(xdotool getwindowpid $(xdotool getwindowfocus))/comm`
freekmurze / bookmarklet
Last active Feb 22, 2019
Oh Dear! Reachable bookmarklet
View bookmarklet
lyshie / config-deb-i386.json
Last active Oct 7, 2020
Scratch Desktop (Scratch 3.0 Offline Editor) on GNU/Linux
View config-deb-i386.json
"src": "/tmp/scratch-desktop/",
"dest": "/tmp/",
"arch": "i386",
"icon": "/tmp/scratch-desktop/resources/Icon.png",
"categories": [

Freezer cgroup FTW

In a terminal start a server.

$ python -m SimpleHTTPServer 8000

In another terminal set up the cgroups freezer.

jessfraz / boxstarter.ps1
Last active Oct 22, 2020
Boxstarter Commands for a new Windows box.
View boxstarter.ps1
# Description: Boxstarter Script
# Author: Jess Frazelle <>
# Last Updated: 2017-09-11
# Install boxstarter:
# . { iwr -useb } | iex; get-boxstarter -Force
# You might need to set: Set-ExecutionPolicy RemoteSigned
# Run this boxstarter by calling the following from an **elevated** command-prompt:
View Jenkinsfile
node {
bitbucketStatusNotify(buildState: 'INPROGRESS')
ws("${JENKINS_HOME}/jobs/${JOB_NAME}/builds/${BUILD_ID}/") {
withEnv(["GOPATH=${JENKINS_HOME}/jobs/${JOB_NAME}/builds/${BUILD_ID}"]) {
alexellis /
Last active Oct 24, 2020
K8s on Raspbian
Lewiscowles1986 /
Created Aug 21, 2017
Raspberry pi stretch allow dhcpcd5 with /etc/network/interfaces
#!/bin/sh -e
# This file belongs in /usr/lib/dhcpcd5/dhcpcd how you get it there is up to you
honktang / web-snippet-055 ( upload to Imgur in JavaScript)
Created Jun 14, 2017 — forked from achudars/web-snippet-055 ( upload to Imgur in JavaScript)
Use JavaScript to upload anonymously to Imgur using Imgur API and show the link to the file. Make sure your API key is valid and working!
View web-snippet-055 ( upload to Imgur in JavaScript)
function upload(file) {
var imageLink ="";
/* Is the file an image? */
if (!file || !file.type.match(/image.*/)) return;
var fd = new FormData();
fd.append("image", file); // Append the file
fd.append("key", "<Imgur API key>");
View curry.php
function curry($f, $argument)
return function (...$arguments) use ($f, $argument) {
return $f(...array_merge([$argument], $arguments));
function add(...$numbers)
You can’t perform that action at this time.