Skip to content

Instantly share code, notes, and snippets.

Notice: Sending packet of type "A2S_INFO_Packet"... in /site/lib/steam/sockets/SteamSocket.php on line 134
Notice: Received reply of type "RCONGoldSrcResponse" in /site/lib/steam/sockets/SourceSocket.php on line 80
Notice: Sending packet of type "A2S_INFO_Packet"... in /site/lib/steam/sockets/SteamSocket.php on line 134
Notice: Received reply of type "RCONGoldSrcResponse" in /site/lib/steam/sockets/SourceSocket.php on line 80
Fatal error: Uncaught exception 'SteamCondenserException' with message 'Response of type RCONGoldSrcResponse cannot be handled by this method.' in /site/lib/steam/servers/GameServer.php:313
Stack trace:
@mitchellhuang
mitchellhuang / tf2_install.sh
Last active July 9, 2016 15:56
SRCDS/TF2 install on Ubuntu 12.04/12.10
#!/bin/bash
# TF2/SRCDS install script by huangbong
# Last updated: 2013-01-18
# https://gist.github.com/4557661/
#########################
# Settings - edit this!
#########################
USER="username" # user that will be running the SRCDS instance (not root)
@mitchellhuang
mitchellhuang / kvm.sh
Created February 3, 2013 17:26
kvmbuilder example
sudo vmbuilder kvm ubuntu --suite oneiric --flavour virtual --arch amd64 \
-v --hostname=siriproxy.local \
--dest=/vm/vm1 \
--user 'mitchell' --name 'Mitchell Huang' --pass '12345' \
--bridge 'br0' --libvirt 'qemu:///system' \
--mem=1024 --cpus=1 \
--rootsize=10240 --swapsize=1024 \
--addpkg openssh-server \
--addpkg vim \
--addpkg acpid
@mitchellhuang
mitchellhuang / jb.txt
Last active December 12, 2015 03:49
iOS 6 Jailbreak Apps to Install
FlashLock
Switchy or MultiStory
OpenSSH
iFile
BlurriedNCBackground
BiteSMS
Nitrous
AdBlocker
Zephyr
Poof
@mitchellhuang
mitchellhuang / autoexec.txt
Last active December 13, 2015 20:48
TF2 Settings
// Unexplained crashes? Try changing mat_queue_mode to `-1'.
// ----------------------------------------------------------------------------
// Chris' highframes config, designed to get you a large performance boost
// v2.016 | 25 January 2013 | fakkelbrigade.eu/chris/configs/
// ----------------------------------------------------------------------------
// Problems or questions? Contact me at #christf2 on QuakeNet.
// ----------------------------------------------------------------------------
// Launch options:
// IMPORTANT: Remove -dxlevel 81 from the launch options after the first launch!
//
@mitchellhuang
mitchellhuang / autoexec.cfg
Created February 12, 2014 02:55
CS:GO SRCDS configs
log on
@mitchellhuang
mitchellhuang / partitions.py
Created November 21, 2014 02:01
proj4 q19 doeeeeee
def partitions(n, m):
"""Return a linked list of partitions
of n using parts of up to m.
Each partition is a linked list.
"""
if n == 0:
return link(empty, empty)
elif n < 0:
return empty
elif m == 0:
@mitchellhuang
mitchellhuang / checkout.js
Created February 24, 2018 06:40
Stripe Elements Next.js (works with SSR)
import React, { Component, Fragment } from 'react';
import PropTypes from 'prop-types';
import { compose } from 'react-apollo';
import cookies from 'next-cookies';
import jsCookie from 'js-cookie';
import Script from 'react-load-script';
import { StripeProvider, Elements } from 'react-stripe-elements';
import Main from '../layouts/Main';
import withData from '../lib/withData';
import { viewerGraphql } from '../apollo/queries/viewer';

Keybase proof

I hereby claim:

  • I am mitchellhuang on github.
  • I am huang (https://keybase.io/huang) on keybase.
  • I have a public key ASCgSFMGl8cVQntscdsdg4N5246prkoC-Vps2sF1Su1V9go

To claim this, I am signing this object:

@mitchellhuang
mitchellhuang / aws-alb.sh
Created December 28, 2018 23:22
AWS ELB Target Autoscaling Group
aws elbv2 create-target-group --name <target_group_name> --protocol HTTP --port 80 --vpc-id <vpc_id>
aws autoscaling attach-load-balancer-target-groups --auto-scaling-group-name <id_of_the_autoscaling_group> --target-group-arns "<new_target_group_arns>"