Skip to content

Instantly share code, notes, and snippets.


Tianon Gravi tianon

View GitHub Profile
tianon / vizio-gv42l-xorg.conf
Last active Mar 7, 2017
Vizio GV42L in Linux without overscan
View vizio-gv42l-xorg.conf
# see
Section "Monitor"
Identifier "VizioGV42L"
VendorName "VIZIO"
ModelName "GV42L"
HorizSync 31.0 - 70.0
VertRefresh 50.0 - 85.0
Option "DPMS"
tianon / nginx-go.conf
Last active Dec 13, 2016
configuration behind, inspired by
View nginx-go.conf
# inspired by
server {
listen 80;
listen 443 ssl http2;
tianon /
Last active May 13, 2016
discover the minimum set of packages that need to be "apt-mark manual" to keep what's currently installed
set -e
# usage:
# $
# inetutils-ping
tianon / driver.go
Last active Apr 21, 2016
View driver.go
package main
import (
yosifkit / git-diff-process-substitution.patch
Last active Jun 26, 2019
dev-vcs/git-2.4.10 patch for git diff to work for process substitution: `$ git diff --color-words <(echo a b c) <(echo a d c)`
View git-diff-process-substitution.patch
diff --git a/Documentation/git-diff.txt b/Documentation/git-diff.txt
index bbab35f..f4ca476 100644
--- a/Documentation/git-diff.txt
+++ b/Documentation/git-diff.txt
@@ -99,10 +99,17 @@ include::diff-options.txt[]
The <paths> parameters, when given, are used to limit
the diff to the named paths (you can give directory
names and get diff for all files under them).
tianon /
Last active Dec 13, 2019
SUPERSEDED BY -- collection of useful sbuild-related scripts
set -eu
shift || { echo >&2 "usage: $0 suite [arch]"; exit 1; }
case "$targetSuite" in
ceilfors / cleanupUnusedWorkspaceInSlaves.groovy
Last active Sep 29, 2020
When you delete jobs in Jenkins, the corresponding workspaces in the build slaves won't be deleted automatically. This Jenkins script will go to each slave and check if the jobs are already deleted in Jenkins master and delete the workspace.
View cleanupUnusedWorkspaceInSlaves.groovy
import com.cloudbees.hudson.plugins.folder.Folder
import hudson.FilePath
import jenkins.model.Jenkins
def boolean isFolder(String name) {
def item = Jenkins.instance.getItemByFullName(name)
return item instanceof Folder
def deleteUnusedWorkspace(FilePath root, String path) {
set -e
cd "$(dirname "$(readlink -f "$BASH_SOURCE")")"
hackVendor="$(< hack/"
if [ "$1" ]; then
hackVendor="$(git show "$1":hack/"
set -e
str='docker run'
str+=' {{printf "--name=%q" .Name}}'
str+='{{if (eq .HostConfig.NetworkMode "bridge")}} {{printf "--hostname=%q" .Config.Hostname}}{{else}} {{printf "--net=%q" .HostConfig.NetworkMode}}{{end}}'
str+='{{if .Config.OpenStdin}} --interactive{{end}}'
str+='{{if .Config.Tty}} --tty{{end}}'
md5 /
Last active Dec 3, 2020
Demonstration Docker config for Wordpress on PHP-FPM behind Nginx

Proof of concept setup for Wordpress running under PHP-FPM with an Nginx frontend


Build a copy of this image:

git clone git:// docker-nginx-fpm
cd docker-nginx-fpm
docker build -t nginx-fpm .
You can’t perform that action at this time.