Updated for Rails 4.0.0+
-
Set up the
bower
gem. -
Follow the Bower instructions and list your dependencies in your
bower.json
, e.g.// bower.json
{
Updated for Rails 4.0.0+
Set up the bower
gem.
Follow the Bower instructions and list your dependencies in your bower.json
, e.g.
// bower.json
{
import time | |
import win32api, win32con | |
VK_CODE = {'left_arrow':0x25, | |
'spacebar':0x20, | |
'right_arrow':0x27} | |
def press(x): | |
win32api.keybd_event(VK_CODE[x], 0,0,0) | |
win32api.keybd_event(VK_CODE[x],0 ,win32con.KEYEVENTF_KEYUP ,0) |
#!/usr/bin/env python | |
from ctypes import CDLL | |
foo = "Fiesta" | |
bar = "Fiesta" | |
#Change foo with low level C | |
libc = CDLL('libc.so.6') | |
libc.strcpy(foo, "Nachos") |
#!/bin/bash | |
echo "Generating an SSL private key to sign your certificate..." | |
openssl genrsa -des3 -out myssl.key 1024 | |
echo "Generating a Certificate Signing Request..." | |
openssl req -new -key myssl.key -out myssl.csr | |
echo "Removing passphrase from key (for nginx)..." | |
cp myssl.key myssl.key.org | |
openssl rsa -in myssl.key.org -out myssl.key |
Using Python's built-in defaultdict we can easily define a tree data structure:
def tree(): return defaultdict(tree)
That's it!
Installation commands:
$ wget http://redis.googlecode.com/files/redis-2.4.8.tar.gz
$ tar xvfz redis-2.4.8.tar.gz
$ cd redis-2.4.8/
$ mkdir -p /opt/redis
$ make PREFIX=/opt/redis install
$ cp redis.conf /opt/redis/redis.conf
$ chown -R redis:redis /opt/redis
(lambda: | |
not globals().__setitem__('sys', __import__('sys')) | |
and not globals().__setitem__('this', sys.modules[globals()['__name__']]) | |
and not globals().__setitem__('time', __import__('time')) | |
and | |
#program | |
[setattr(this, k, v) for k,v in { | |
'set_color': (lambda c: w(['*', ' '][c])), | |
'abs': (lambda t: (t + (t >> 31)) ^ (t >> 31)), | |
'w': sys.stdout.write, |
var events = require('events'), | |
util = require('util'); | |
var MockReadWriteStream = helpers.MockReadWriteStream = function () { | |
// | |
// No need to do anything here, it's just a mock. | |
// | |
}; | |
util.inherits(MockReadWriteStream, events.EventEmitter); |
var events = require('events'), | |
util = require('util'); | |
var MockReadWriteStream = helpers.MockReadWriteStream = function () { | |
// | |
// No need to do anything here, it's just a mock. | |
// | |
}; | |
util.inherits(MockReadWriteStream, events.EventEmitter); |