Skip to content

Instantly share code, notes, and snippets.

[
{
"step": 1,
"time_offset": 0,
"movements": [[123, 31], [321,22], [null, null], [99, 99]],
"actions": [
{"time_offset": 4032, "input_type": "keyboard", "value": "spacebar"},
{"time_offset": 8944, "input_type": "mouse", "value": [123,321]}
],
"distance": 3245
@findchris
findchris / gist:9985704
Created April 5, 2014 00:26
Run a single schema migration
class OneOff < ActiveRecord::Migration
def connection
ActiveRecord::Base.establish_connection("whatever_#{Rails.env}").connection
end
def up
puts 'up'
end
[
{
"step": 1,
"repeat_index": 0,
"time_offset": 0,
"movements": [[x1, y1], [x2,y2], ..., [null, null], [x99, y99], ...],
"actions": [
{"time_offset": 4032, "input_type": "keyboard", "value": "spacebar"},
{"time_offset": 8944, "input_type": "mouse", "value": [123, 321]}
],
@findchris
findchris / 11-7-13 hash_key counts
Last active December 27, 2015 03:19
hash_key counts
'2427:4::2013-11-05' => 1
'2280:4::2013-11-05' => 2
'2638:4::2013-11-06' => 2
'1422:1:257:2013-11-06' => 2
'2660:4::2013-11-07' => 2
'2332:4::2013-11-05' => 2
'2623:4::2013-11-05' => 2
'1344:4::2013-11-05' => 2
'2624:4::2013-11-05' => 2
'2486:4::2013-11-05' => 2
@findchris
findchris / gist:6347630
Created August 26, 2013 22:53
JiWire redirect URL source
<!DOCTYPE html>
<head>
<meta charset="utf-8" />
<meta name="viewport" content="initial-scale=1.0, maximum-scale=1.0, width=device-width" />
<meta name="apple-mobile-web-app-capable" content="yes"/>
<link href="http://local.jiwire.com/jwindr.jiwire.com/current/css/a4a/selectablemedia/110/style.css" rel="stylesheet" type="text/css" />
<script src="http://local.jiwire.com/jwindr.jiwire.com/current/js/jquery-1.8.2.min.js" type="text/javascript"></script>
<style>
.finish_hide { position:absolute;z-index:5000;top:190px;width:100%;height:220px; margin:0 auto; visibility:hidden;}
@findchris
findchris / gist:6346961
Created August 26, 2013 21:37
Today's pingdom server IPs
> wget --quiet -O- https://www.pingdom.com/rss/probe_servers.xml | perl -nle 'print $1 if /IP: (([01]?\d\d?|2[0-4]\d|25[0-5])\.([01]?\d\d?|2[0-4]\d|25[0-5])\.([01]?\d\d?|2[0-4]\d|25[0-5])\.([01]?\d\d?|2[0-4]\d|25[0-5]));/'
95.141.32.46
95.211.217.68
91.109.115.41
83.170.113.210
188.138.118.144
174.34.224.167
72.46.140.106
76.72.172.208
184.75.210.226
$ ./sbt assembly
Detected sbt version 0.12.3
[info] Loading project definition from /Users/chris/code/swagger-codegen/project
[info] Set current project to swagger-codegen (in build file:/Users/chris/code/swagger-codegen/)
[warn] Credentials file /Users/chris/.ivy2/.credentials does not exist
[info] ApiExtractorTest:
[info] ApiExtractor
[info] - should verify the deserialization of the store api
[info] ModelSerializationTest:
[info] - should deserialize a model
{
"steps":[
{
"controls":[
{
"name":"swf 1",
"x":157.5,
"y":102,
"preload_urls":[
"swf_url"
@findchris
findchris / activity.json
Created September 12, 2012 22:42 — forked from astein/activity.json
Engagement Servering JSON Specs
{
"version":"3.1",
"type":"AS",
"width":750,
"height":500,
"interactive_url":"http://media.socialvi.be/debug/3.1/com/socialvibe/tools/builder/BuilderEngagementModule.swf",
"config_json": {"type":"wizard","foregroundLayer":{"backgroundEnabled":true,"controls":[],"foregroundEnabled":true,"panelName":"foreground"},"wizard":{"templateClass":"com.socialvibe.tools.wizard.templates::ExternalPlayerTaggedTemplate","stepTemplateMap":{"step 1":"com.socialvibe.tools.wizard.templates::ExternalPlayerTaggedStep"}},"self_serve_url":"https://zynga.socialvibe.com/","steps":[{"backgroundEnabled":true,"controls":[{"height":295,"controlClass":"com.socialvibe.core.ui.controls::SVIFrame","url":"http://player.ebuzzing.com/xtst/ifr/playern_ifr.php?parametre=723580&vielnk=getUrlAsIframe(http%3A%2F%2Fpartners.socialvi.be%2Ftags%2Ftrack_interaction%3Finteraction%3Dvideo_completed)","scrollbars":false,"name":"iframe 1","x":156,"y":100,"width":435},{"controlClass":"com.socialvibe.core.ui.controls::SVButton","width":100,"action
~# cat /proc/meminfo
MemTotal: 7864548 kB
MemFree: 3046728 kB
Buffers: 1345184 kB
Cached: 1408600 kB
SwapCached: 0 kB
Active: 3750776 kB
Inactive: 653648 kB
Active(anon): 1650688 kB
Inactive(anon): 156 kB