This file contains 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
from extensions import db | |
class Base(object): | |
def save(self): | |
db.session.add(self) | |
db.session.commit() |
This file contains 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
require 'mina/bundler' | |
require 'mina/rails' | |
require 'mina/git' | |
require 'mina/rvm' # for rvm support. (http://rvm.io) | |
set :domain, 'esdb.cn' | |
set :identity_file, '/User/somebody/.ssh/somebody.pem' | |
set :deploy_to, '/home/ubuntu/apps/xxx.com' | |
set :repository, 'ssh://git@bitbucket.org/somebody/xxx.com.git' | |
set :branch, 'master' |
This file contains 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
execute pathogen#infect() | |
filetype plugin indent on | |
syntax on | |
set nu | |
set tabstop=2 | |
set shiftwidth=2 | |
set softtabstop=2 | |
set expandtab |
This file contains 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
// Generated by gfwlist2pac | |
// https://github.com/clowwindy/gfwlist2pac | |
var domains = { | |
"vimcasts.org" : 1, | |
"vim.org" : 1, | |
"wenincode.com" : 1, | |
"amazonaws.com" : 1, | |
"codeception.com" : 1, | |
"opensuse.org" : 1, |
This file contains 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
set nocompatible " be iMproved | |
filetype off " required! | |
set nobackup | |
set nowritebackup | |
" Close bell | |
set vb t_vb= | |
set mouse=a |
This file contains 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
#include <OpenGL/gl3.h> | |
#include <GLUT/glut.h> | |
void init(){ | |
glClearColor(1.0, 1.0, 1.0, 0.0); | |
glMatrixMode(GL_PROJECTION); | |
gluOrtho2D(0, 200, 0, 150); | |
} | |
void lineSegment(){ |
This file contains 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
#include <Bridge.h> | |
#include <FileIO.h> | |
#include "DHT.h" | |
#define DHTPIN A0 | |
#define DHTTYPE DHT11 | |
#define SOUND A1 | |
#define LIGHT A2 | |
DHT dht(DHTPIN, DHTTYPE); | |
String getTempAndHum(); |
This file contains 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 | |
echo Building Google Protobuf for Mac OS X / iOS. | |
echo Use 'tail -f build.log' to monitor progress. | |
( | |
PREFIX=`pwd`/protobuf | |
mkdir ${PREFIX} | |
mkdir ${PREFIX}/platform |
NewerOlder