This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- # download VIMAGE to a spare FreeBSD box | |
- unxz -T0 # uncompress | |
- mdconfig image.raw; mount # for editing | |
- sshd_enable | |
- devmatch_blacklist="virtio_random.ko" # avoid a bug | |
- PermitRootLogin | |
- /root/.ssh/authorized_keys | |
- umount; mdconfig -d | |
- xz -T0 -9 # compress edited image | |
- cp nginx/ # publish with any web server |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/src/router.c b/src/router.c | |
index 541c023..9ad79d4 100644 | |
--- a/src/router.c | |
+++ b/src/router.c | |
@@ -390,6 +390,7 @@ enum { | |
IOV_RA_ROUTES, | |
IOV_RA_DNS, | |
IOV_RA_SEARCH, | |
+ IOV_RA_PREF64, | |
IOV_RA_ADV_INTERVAL, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# lib/omniauth/facebook.rb | |
require 'httparty' | |
module Omniauth | |
class Facebook | |
include HTTParty | |
# The base uri for facebook graph API | |
base_uri 'https://graph.facebook.com/v2.3' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- test pass with CryptoJS v3.1.2 --> | |
<script src="rollups/tripledes.js"></script> | |
<script src="components/mode-ecb.js"></script> | |
<script> | |
/** | |
* Encrypt message by DES in ECB mode and Pkcs7 padding scheme | |
* | |
* NOTE: DES is weak, please use 3DES(Triple DES) or AES | |
* | |
* @param {String} message |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#import <Foundation/Foundation.h> | |
@interface KUtils : NSObject | |
+ (NSString *)getVersionInfo; | |
@end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# encoding: UTF-8 | |
Capistrano::Configuration.instance(:must_exist).load do | |
namespace :rails do | |
desc "Open the rails console on one of the remote servers" | |
task :console, :roles => :app do | |
hostname = find_servers_for_task(current_task).first | |
exec "ssh -l #{user} #{hostname} -t 'source ~/.profile && #{current_path}/script/rails c #{rails_env}'" | |
end | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# This script automatically sets the version and short version string of | |
# an Xcode project from the Git repository containing the project. | |
# | |
# To use this script in Xcode 4, add the contents to a "Run Script" build | |
# phase for your application target. | |
set -o errexit | |
set -o nounset |