Skip to content

Instantly share code, notes, and snippets.

View jjmpsp's full-sized avatar
💭
Working on a new personal website

Joel Murphy jjmpsp

💭
Working on a new personal website
View GitHub Profile
@pamelafox
pamelafox / marvel_characters.sql
Last active April 4, 2024 06:53
marvel_characters.sql
/* Marvel Heroes and Villains
Based on the website http://marvel.wikia.com/Main_Page
with popularity data from http://observationdeck.io9.com/something-i-found-marvel-character-popularity-poll-cb-1568108064
and power grid data from http://marvel.wikia.com/Power_Grid#Power
Collected by: https://www.khanacademy.org/profile/Mentrasto/
*/
CREATE TABLE marvels (ID INTEGER PRIMARY KEY,
name TEXT,
popularity INTEGER,
@pamelafox
pamelafox / solar_system_objects.sql
Last active April 4, 2024 06:41
solar_system_objects.sql
/*
Solar system objects
Adapted from: http://en.wikipedia.org/wiki/List_of_Solar_System_objects_by_size
Collected by: https://www.khanacademy.org/profile/patrick809/programs
*/
CREATE TABLE solar_system_objects(
body TEXT
, mean_radius NUMERIC /* km */
, mean_radius_rel NUMERIC /* relative to earth */
, volume NUMERIC /* 10^9 km^3 */
@pamelafox
pamelafox / countries_and_territories.sql
Last active May 2, 2024 20:09
countries_and_territories.sql
/*
Countries and dependent territories, 2020
Data adapted from
http://www.worldometers.info/world-population/population-by-country/
Does not include rows which had "N.A." values, so some territories are missing.
*/
CREATE TABLE countries(
name TEXT PRIMARY KEY,
population INTEGER,
@pamelafox
pamelafox / top_movies.sql
Last active April 4, 2024 06:39
Top 100 Movies
/* Source: http://www.boxofficemojo.com/alltime/world/ */
CREATE TABLE topmovies(
Rank INTEGER,
Title TEXT,
Studio TEXT,
Worldwide REAL,
Domestic REAL,
DomesticPct REAL,
Overseas REAL,
OverseasPct REAL,
@GABeech
GABeech / haproxy.cfg
Created August 21, 2014 18:35
Stack Exchange HAProxy
# This is an example of the Stack Exchange Tier 1 HAProxy config
# The only things that have been changed from what we are running are:
# 1. User names have been removed
# 2. All Passwords have been remove
# 3. IPs have been changed to use the example/documentation ranges
# 4. Rate limit numbers have been changed to randome numbers, don't read into them
userlist stats-auth
group admin users $admin_user
user $admin_user insecure-password $some_password
@rtt
rtt / tinder-api-documentation.md
Last active April 20, 2024 17:01
Tinder API Documentation

Tinder API documentation

Note: this was written in April/May 2014 and the API may has definitely changed since. I have nothing to do with Tinder, nor its API, and I do not offer any support for anything you may build on top of this. Proceed with caution

http://rsty.org/

I've sniffed most of the Tinder API to see how it works. You can use this to create bots (etc) very trivially. Some example python bot code is here -> https://gist.github.com/rtt/5a2e0cfa638c938cca59 (horribly quick and dirty, you've been warned!)

@georgiecel
georgiecel / wp-comment-walker
Last active December 28, 2022 15:16
Custom comment walker for HTML5 friendly WordPress comment and threaded replies. To be inserted in functions.php.
<?php
class comment_walker extends Walker_Comment {
var $tree_type = 'comment';
var $db_fields = array( 'parent' => 'comment_parent', 'id' => 'comment_ID' );
// constructor – wrapper for the comments list
function __construct() { ?>
<section class="comments-list">
@kevin-smets
kevin-smets / iterm2-solarized.md
Last active May 2, 2024 22:18
iTerm2 + Oh My Zsh + Solarized color scheme + Source Code Pro Powerline + Font Awesome + [Powerlevel10k] - (macOS)

Default

Default

Powerlevel10k

Powerlevel10k

@dsamarin
dsamarin / UndoStack.js
Created July 5, 2012 00:37
Easy undo-redo in JavaScript.
function UndoItem (perform, data) {
this.perform = perform;
this.data = data;
}
/**
* UndoStack:
* Easy undo-redo in JavaScript.
**/
@jexchan
jexchan / multiple_ssh_setting.md
Created April 10, 2012 15:00
Multiple SSH keys for different github accounts

Multiple SSH Keys settings for different github account

create different public key

create different ssh key according the article Mac Set-Up Git

$ ssh-keygen -t rsa -C "your_email@youremail.com"