Skip to content

Instantly share code, notes, and snippets.

View russellballestrini's full-sized avatar
💭
https://www.makepostsell.com

Russell russellballestrini

💭
https://www.makepostsell.com
View GitHub Profile
@kklimonda
kklimonda / pybrowser.py
Created March 28, 2011 15:18
A minimal Gtk+/Webkit based browser in Python
import sys
from gi.repository import Gtk, Gdk, WebKit
class BrowserTab(Gtk.VBox):
def __init__(self, *args, **kwargs):
super(BrowserTab, self).__init__(*args, **kwargs)
go_button = Gtk.Button("go to...")
go_button.connect("clicked", self._load_url)
self.url_bar = Gtk.Entry()
@trey
trey / happy_git_on_osx.md
Last active February 18, 2024 10:46
Creating a Happy Git Environment on OS X

Creating a Happy Git Environment on OS X

Step 1: Install Git

brew install git bash-completion

Configure things:

git config --global user.name "Your Name"

git config --global user.email "you@example.com"

@jordansissel
jordansissel / logstash-mysql-query-parse.md
Last active June 7, 2021 21:10
parsing mysql's query log format with logstash

parsing mysql query logs with logstash

The problem is that some lines in the file are missing timestamps when they aren't continuations of any previous line. It's dumb, really.

The mysql query log is seriously bullshit format, but nothing logstash can't unscrew.

The main goal here is to show how we can fix the 'missing timestamp' problem.

% ruby bin/logstash agent -e '

@asenchi
asenchi / logstash-mysql-query-parse.md
Created September 20, 2012 01:06 — forked from jordansissel/logstash-mysql-query-parse.md
parsing mysql's bullshit query log format with logstash

parsing mysql query logs with logstash

The problem is that some lines in the file are missing timestamps when they aren't continuations of any previous line. It's dumb, really.

The mysql query log is seriously bullshit format, but nothing logstash can't unscrew.

The main goal here is to show how we can fix the 'missing timestamp' problem.

% ruby bin/logstash agent -e '

@tshirtman
tshirtman / Ground_(front_layer).png
Created October 10, 2012 22:37
This gist show how to build a scrolling and repeating background with kivy
Ground_(front_layer).png
@jathanism
jathanism / dictobject.py
Last active December 9, 2015 20:28
A dictionary-like object to recursively (or not) represent its items as attributes, but still behaves like a dict in every way.
# -*- coding: utf-8 -*_
"""
A dictionary-like object to represent items as attributes, but still behaves
like a dict in every way.
"""
__author__ = 'Jathan McCollum'
__maintainer__ = 'Jathan McCollum'
__email__ = 'jathanism@aol.com'
@conorbranagan
conorbranagan / gist:4513828
Last active May 18, 2024 21:28
Linux System Metrics

Linux System Metrics

CPU

  • system.cpu.idle: % Idle CPU
  • system.cpu.system: % System CPU
  • system.cpu.user: % User CPU

Disk

@rodacato
rodacato / notes.txt
Created September 19, 2013 03:28
Things you need to know when install piwik on smartos
# Congifuration Files
vi /opt/local/etc/php.ini
vi /opt/local/etc/php-fpm.conf
vi /opt/local/etc/nginx/nginx.conf
# Restart services
svcadm [refresh|restart|enable|disable] nginx
svcadm [refresh|restart|enable|disable] php-fpm
@ericrasmussen
ericrasmussen / users.idr
Created May 3, 2014 20:02
Contrived user history example to show off dependent types
module main
{-
I assume you're coming here from
http://chromaticleaves.com/posts/idris-and-dependent-types.html
If not, please take a moment to read it. It's a very important white paper.
Completely serious, too.
Now that we have that out of the way, this gist is a contrived example that
@elsonrodriguez
elsonrodriguez / README.md
Last active October 17, 2023 14:21
Selenium on Kubernetes!

This is a quick and dirty guide on how to deploy Selenium on Kubernetes.

It is required that you have Kubernetes cluster up and running. If you don't have one, GKE is pretty nifty: https://cloud.google.com/container-engine/

Deploy the Seleniumb Hub:

kubectl create -f selenium-hub-rc.yaml
kubectl create -f selenium-hub-svc.yaml