Skip to content

Instantly share code, notes, and snippets.

Keybase proof

I hereby claim:

  • I am jamster on github.
  • I am jamster (https://keybase.io/jamster) on keybase.
  • I have a public key ASAwuGZk_gNiHGvS-Tx7v8qg9Ncqhr3tMQBgz9jMBs3PMAo

To claim this, I am signing this object:

BTW yum has last Redis too, remi repository at least.
$ sudo -i
$ yum list redis
$ redis.x86_64 2.6.13-1.el6.remi remi
But today we want compile redis from source (see http://redis.io/download)
$ yum install make gcc tcl
$ cd /usr/local/src
#!/bin/sh
#
# redis - this script starts and stops the redis-server daemon
#
# chkconfig: - 85 15
# description: Redis is a persistent key-value database
# processname: redis-server
# config: /etc/redis/redis.conf
# config: /etc/sysconfig/redis
# pidfile: /var/run/redis.pid
class Point
constructor: (@x = 0, @y = 0) ->
if isNaN(@x) or isNaN(@y)
throw new Error('Invalid coords')
add: (point) ->
@x += point.x
@y += point.y
subtract: (point) ->
@jamster
jamster / ab.rb
Created November 20, 2012 02:35 — forked from kylewlacy/ab.rb
Apache Bench Homebrew Formula
# Based on https://github.com/simonair/homebrew-dupes
# That repo seems to be dead, and I don't really feel like making a pull request.
require 'formula'
class Ab < Formula
homepage 'http://httpd.apache.org/docs/trunk/programs/ab.html'
url 'http://www.apache.org/dist/httpd/httpd-2.4.3.tar.bz2'
sha1 '0ef1281bb758add937efe61c345287be2f27f662'
depends_on 'libtool' => :build
@jamster
jamster / gist:3894881
Created October 15, 2012 19:53
Building a CentOS 6 Box for Vagrant
@jamster
jamster / gist:3796181
Created September 27, 2012 20:08 — forked from davist11/gist:1204569
Campfire sounds
56k: "https://123.campfirenow.com/images/56k.gif"
bueller: "anyone?"
clowntown: "https://123.campfirenow.com/images/clowntown.gif"
crickets: "hears crickets chirping"
dangerzone: "https://123.campfirenow.com/images/dangerzone.png"
deeper: "https://123.campfirenow.com/images/top.gif"
drama: "https://123.campfirenow.com/images/drama.jpg"
greatjob: "https://123.campfirenow.com/images/greatjob.png"
heygirl: ":sparkles::information_desk_person::sparkles:"
horn: ":dog: :scissors: :cat:"
@jamster
jamster / gist:3362954
Created August 15, 2012 19:39 — forked from saetia/gist:1623487
Clean Install – Mountain Lion OS X 10.8 DP3 Update 4
require 'pp'
def perms(s)
base = [s.downcase, s.upcase]
case s.downcase
when 'a'
base << '@'
when 'o'
base << '0'
when 'e'
@jamster
jamster / Results.txt
Created April 13, 2012 21:49
Finding Prime Palindrome in Pi
1
2 26 33
3 4 141
4 47 3993
5 24 46264
6 768 999999
7 647 1736371
8 3740 23911932
9 6586 398989893
10