Skip to content

Instantly share code, notes, and snippets.

View indrode's full-sized avatar
👻

Indro De indrode

👻
  • Cologne, Germany
View GitHub Profile
@indrode
indrode / gist:9859f4617149cedd099c
Last active August 29, 2015 14:03
Remove individual records from ES index
# copy zebralution_track_ids.txt to the current vsvn015 workspace
# e.g. vsvn015:/opt/simfy/app/simfy_production/releases/20140625084549
# then, on vsvn015 Rails console
ContentTools
process_ids_from_file('zebralution_track_ids.txt') do |id|
command = "curl -XDELETE 'http://localhost:9200/tracks_production/zebralution_track/#{id}'"
system(command)
@indrode
indrode / country_bitmap.txt
Last active December 21, 2015 08:29
Country code bitmap. I.e. 'allowed_today_in values' with corresponding countries.
## ZA
0 : []
1 : ["ww"]
2 : ["za"]
3 : ["ww", "za"]
4 : ["ng"]
5 : ["ww", "ng"]
6 : ["za", "ng"]
7 : ["ww", "za", "ng"]

Changes:

  • this version includes backport of Greg Price's patch for speedup startup http://bugs.ruby-lang.org/issues/7158 .

    ruby-core prefers his way to do thing, so that I abandon cached-lp and sorted-lf patches of mine.

  • this version integrates 'array as queue' patch, which improves performance when push/shift pattern is heavily used on Array.

    This patch is accepted into trunk for Ruby 2.0 and last possible bug is found by Yui Naruse. It is used in production* for a couple of months without issues even with this bug.

@indrode
indrode / 0-readme.md
Last active December 17, 2015 03:09 — forked from burke/0-readme.md

ruby-1.9.3-p327 cumulative performance patch for rbenv

This installs a patched ruby 1.9.3-p327 with various performance improvements and a backported COW-friendly GC, all courtesy of funny-falcon.

Requirements

You will also need a C Compiler. If you're on Linux, you probably already have one or know how to install one. On OS X, you should install XCode, and brew install autoconf using homebrew.

@indrode
indrode / package.json
Created February 22, 2013 16:35
This is the package.json for Talker-Hubot client. See http://lamentingrobot.com/hubot-talker for more info.
{
"name": "hosted-hubot",
"version": "2.4.6",
"author": "GitHub Inc.",
"keywords": "github hubot campfire bot",
"description": "A simple helpful Robot for your Company",
"licenses": [{
"type": "MIT",
"url": "http://github.com/github/hubot/raw/master/LICENSE"
}],
@indrode
indrode / guide.sh
Created January 16, 2013 22:52 — forked from teamon/guide.sh
# Install pow
$ curl get.pow.cx | sh
# Install powder
$ gem install powder
# See that firewall is fucked
$ sudo ipfw show
00100 0 0 fwd 127.0.0.1,20559 tcp from any to me dst-port 80 in <- THIS ONE!!!
65535 81005 28684067 allow ip from any to any
Have a history teacher explain this if they can.
Abraham Lincoln was elected to Congress in 1846.
John F. Kennedy was elected to Congress in 1946.
Abraham Lincoln was elected President in 1860.
John F. Kennedy was elected President in 1960.
Both were particularly concerned with civil rights.
Both wives lost a child while living in the White House.
Batch ID imported
=========================================
3000012273469 2012-10-25 08:41:25
3000012273300 2012-10-25 08:39:49
3000012271558 2012-10-25 08:38:50
3000012270550 2012-10-25 08:38:39
3000012269361 2012-10-25 08:38:18
3000012265173 2012-10-25 08:38:03
3000012264459 2012-10-25 08:35:53
3000012264357 2012-10-25 08:32:40
@indrode
indrode / gist:2883270
Created June 6, 2012 16:57 — forked from lucasfais/gist:1207002
Sublime Text 2 - Useful Shortcuts

Sublime Text 2 – Useful Shortcuts (Mac OS X)

General

⌘T go to file
⌘⌃P go to project
⌘R go to methods
⌃G go to line
⌘KB toggle side bar
⌘⇧P command prompt
@indrode
indrode / gist:1527881
Created December 28, 2011 13:05
Emoji
:+1:
:-1:
:airplane:
:art:
:bear:
:beer:
:bike:
:bomb:
:book:
:bulb: