Skip to content

Instantly share code, notes, and snippets.

View GhostofGoes's full-sized avatar

Chris Goes GhostofGoes

  • New Mexico, USA
  • 13:41 (UTC -06:00)
View GitHub Profile
@starenka
starenka / config
Created January 31, 2012 10:42
~/.config/terminator/config
[global_config]
geometry_hinting = False
enabled_plugins = ,
tab_position = hidden
borderless = True
[keybindings]
scaled_zoom = <Shift><Control>u
go_up = <Shift>Up
next_tab = <Shift>Right
split_horiz = <Shift><Control>t
@jpoehls
jpoehls / output.txt
Created March 26, 2012 16:48
PowerShell benchmarking function. Or, the Windows equivalent of Unix's `time` command.
PS> time { ping -n 1 google.com } -Samples 10 -Silent
..........
Avg: 62.1674ms
Min: 56.9945ms
Max: 87.9602ms
PS> time { ping -n 1 google.com } -Samples 10 -Silent -Long
..........
Avg: 00:00:00.0612480
Min: 00:00:00.0572167
@cynici
cynici / gist:2249169
Created March 30, 2012 08:00
Directory watcher as a Windows service using ActivePython
# Adapted from http://pypi.python.org/pypi/watchdog
import sys, os, re
import time
import logging
from optparse import OptionParser
import subprocess
from watchdog.observers import Observer
import watchdog.events
import pythoncom
@phansch
phansch / GitHub.PowerShell_profile.ps1
Created October 1, 2012 19:25
My custom PowerShell prompt
function shorten-path([string] $path) {
$loc = $path.Replace($HOME, '~')
# remove prefix for UNC paths
$loc = $loc -replace '^[^:]+::', ''
# make path shorter like tabs in Vim,
# handle paths starting with \\ and . correctly
return ($loc -replace '\\(\.?)([^\\])[^\\]*(?=\\)','\$1$2')
}
function prompt {
@Chaser324
Chaser324 / GitHub-Forking.md
Last active June 16, 2024 07:13
GitHub Standard Fork & Pull Request Workflow

Whether you're trying to give back to the open source community or collaborating on your own projects, knowing how to properly fork and generate pull requests is essential. Unfortunately, it's quite easy to make mistakes or not know what you should do when you're initially learning the process. I know that I certainly had considerable initial trouble with it, and I found a lot of the information on GitHub and around the internet to be rather piecemeal and incomplete - part of the process described here, another there, common hangups in a different place, and so on.

In an attempt to coallate this information for myself and others, this short tutorial is what I've found to be fairly standard procedure for creating a fork, doing your work, issuing a pull request, and merging that pull request back into the original project.

Creating a Fork

Just head over to the GitHub page and click the "Fork" button. It's just that simple. Once you've done that, you can use your favorite git client to clone your repo or j

@garbados
garbados / gist:f82604ea639e0e47bf44
Created July 27, 2014 23:07
Falsehoods Programmers Believe About Gender
  1. There are two and only two genders.
  2. Okay, then there are two and only two biological genders.
  3. Gender is determined solely by biology.
  4. Okay, it’s mostly determined by biology, right?
  5. Please tell me it’s determined by DNA.
  6. Gender can be reliably determined through visual means. After all, no man would ever wear a burka.
  7. Once gender is set, it never changes.
  8. Even if the gender can change, it will only change from the one value to the other value.
  9. Only one gender can be “active” at the same time.
  10. We’re tracking gender now, so we’ve always tracked it.
@higebu
higebu / mkimage_vyos.sh
Last active January 16, 2017 09:30
mkimage_vyos.sh
#!/bin/bash
# You need to install overlayroot
# sudo apt-get install overlayroot
LANG=C
set -e
set -x
@mattrude
mattrude / GnuPG-2.1.md
Last active September 10, 2023 12:05
GnuPG 2.1.18 Build Instructions for Ubuntu 16.04 LTS

GnuPG 2.1.20 Build Instructions

Below you is my build instructions for GnuPG 2.1.20 released on 03-Apr-2017. These instructions are built for a headless Ubuntu 16.04 LTS server.

Or if you wish, you may use the install script to install GnuPG 2.1.20 by entring the following:

curl -sL "https://gist.github.com/mattrude/3883a3801613b048d45b/raw/install-gnupg2.sh" |sh

Install the needed depends

apt-get -y install libgnutls-dev bzip2 make gettext texinfo gnutls-bin \

@cnf
cnf / Dockerfile
Created May 26, 2015 18:47
VyOS Docker Build
FROM debian:squeeze
ENV DEBIAN_FRONTEND noninteractive
RUN apt-get update \
&& apt-get install -y wget \
&& wget -O - http://packages.vyos.net/vyos-pubkey.gpg | apt-key add - \
&& echo "deb http://backports.debian.org/debian-backports squeeze-backports main" > /etc/apt/sources.list.d/bp.list \
&& apt-get update \
&& apt-get -t squeeze-backports install -y squashfs-tools \
@nickstanisha
nickstanisha / trie.py
Created November 21, 2015 22:58
An object-oriented implementation of a "Trie" in Python
class Node:
def __init__(self, label=None, data=None):
self.label = label
self.data = data
self.children = dict()
def addChild(self, key, data=None):
if not isinstance(key, Node):
self.children[key] = Node(key, data)
else: