Skip to content

Instantly share code, notes, and snippets.

View christianchristensen's full-sized avatar

Chris Christensen christianchristensen

View GitHub Profile
@x-way
x-way / index.php
Last active December 17, 2015 23:39
dyndns server
<?php
$myip = null;
$hostname = null;
$type = null;
$user = null;
$password = null;
$myzone = 'example.com';
$myserver = 'nameserver.example.com';
@adamwiggins
adamwiggins / adams-heroku-values.md
Last active January 13, 2026 12:45
My Heroku values

Make it real

Ideas are cheap. Make a prototype, sketch a CLI session, draw a wireframe. Discuss around concrete examples, not hand-waving abstractions. Don't say you did something, provide a URL that proves it.

Ship it

Nothing is real until it's being used by a real user. This doesn't mean you make a prototype in the morning and blog about it in the evening. It means you find one person you believe your product will help and try to get them to use it.

Do it with style

@crashdump
crashdump / check-ssl-expire.py
Last active February 15, 2025 19:16
Report how many days before and http ssl certificate expire. I've also provided a template if you want to use it with Zabbix as an External Check: - Configure ExternalScripts variable in zabbix_server.conf - Put the script in the external script folder (I've used /etc/zabbix/externalscripts/) - Import the template & assign it to your host. - Wat…
#!/usr/bin/env python
# -*- coding: utf-8 -*-
__author__ = "Adrien Pujol - http://www.crashdump.fr/"
__copyright__ = "Copyright 2013, Adrien Pujol"
__license__ = "Mozilla Public License"
__version__ = "0.3"
__email__ = "[email protected]"
__status__ = "Development"
__doc__ = "Check a TLS certificate validity."
@zacharyvoase
zacharyvoase / README.md
Last active May 21, 2020 06:19
A li’l class for data URI manipulation in Python.

DataURI.py

Data URI manipulation made easy.

This isn't very robust, and will reject a number of valid data URIs. However, it meets the most useful case: a mimetype, a charset, and the base64 flag.

Parsing

@danslimmon
danslimmon / read_opentsdb.r
Last active February 22, 2017 21:02
Reads data from OpenTSDB into an R data frame.
# Loads data from OpenTSDB.
#
# `server.url`: The URL of the OpenTSDB server (e.g. 'http://tsdb.example.com')
# `metrics`: List of strings specifying the metrics to pull (e.g.
# c("avg:web.cpu.user{host=*}", "sum:web.requests{type=login}")
# )
# `start.dt`: How far to go back in the time series, in any format OpenTSDB
# (e.g. "4h-ago")
# `end.dt`: Where to end the results (defaults to now)
# `datify`: Whether to convert timestamps to POSIXlt objects (defaults to TRUE)
[
{
"name": "Old KCI Control Tower",
"alternative name": "Old MCI Control Tower",
"ebn": "275682",
"building type": "airport tower",
"building status": "demolished [destroyed]",
"architectural style": "modernism",
"zip": "64153",
"complex": "Kansas City International Airport",
@samstokes
samstokes / todo
Last active January 3, 2025 01:29
A todo management system in a gist
#!/usr/bin/env bash
set -e
if [[ $# > 0 ]]; then
case "$1" in
-h | -\? | --help )
{
echo "Add a todo:"
echo " todo Reformulate the widget plans."
@johnbender
johnbender / prefs.js
Created February 23, 2013 06:20
Set up Chrome Secure Shell to handle solarized terminal colors
// Disable bold.
term_.prefs_.set('enable-bold', false)
// Use this for Solarized Dark
term_.prefs_.set('background-color', "#002b36");
term_.prefs_.set('foreground-color', "#839496");
term_.prefs_.set('color-palette-overrides', [
'#073642',
'#dc322f',

Install XHProf

Pear

pear upgrade PEAR
pecl install xhprof-0.9.2

MAMP

@ryansmith3136
ryansmith3136 / komrade-api.md
Last active December 11, 2015 18:28
Komrade's HTTP API

Komrade

Komrade is a message queue for your workers. Komrade will help you manage background jobs for web applications.

HTTP based queueing service.

  • PUT Job
  • POST Job's Heartbeat
  • PUT Job Failure
  • GET Jobs