Skip to content

Instantly share code, notes, and snippets.

@jbenet
jbenet / simple-git-branching-model.md
Last active April 9, 2024 03:31
a simple git branching model

a simple git branching model (written in 2013)

This is a very simple git workflow. It (and variants) is in use by many people. I settled on it after using it very effectively at Athena. GitHub does something similar; Zach Holman mentioned it in this talk.

Update: Woah, thanks for all the attention. Didn't expect this simple rant to get popular.

@mweibel
mweibel / passport-mock.js
Last active December 5, 2022 03:33
Mock passport.js with an own strategy
/**
* Author: Michael Weibel <michael.weibel@gmail.com>
* License: MIT
*/
var passport = require('passport')
, StrategyMock = require('./strategy-mock');
module.exports = function(app, options) {
// create your verify function on your own -- should do similar things as
@mrjoes
mrjoes / ckedit.py
Created March 18, 2013 19:04
Flask-Admin and CKEditor WYSIWYG textarea integration. Basically, all you have to do: 1. Create new wtforms widget which will emit 'ckeditor' class 2. Make new wtforms field which will use this widget 3. Create new jinja2 template, which includes ckeditor javascript 4. Tell flask-admin to use new field and new template
from flask import Flask
from flask.ext.sqlalchemy import SQLAlchemy
from flask.ext import admin, wtf
from flask.ext.admin.contrib import sqlamodel
app = Flask(__name__)
app.config['SECRET_KEY'] = '123456790'
app.config['SQLALCHEMY_DATABASE_URI'] = 'sqlite:///test.sqlite'
db = SQLAlchemy(app)
@pirj
pirj / Gemfile
Created August 16, 2012 15:38
Sinatra + Omniauth
source 'https://rubygems.org'
gem 'thin'
gem 'eventmachine', '1.0.0.rc.4'
gem 'sinatra'
gem 'sinatra-contrib', :require => 'sinatra/contrib'
gem 'sinatra-flash', :require => 'sinatra/flash'
gem 'rack-protection'
@fairchild
fairchild / Gemfile
Created December 7, 2011 09:58
An example sinatra omniauth client app
source :rubygems
gem 'sinatra'
gem 'json'
gem 'omniauth'
gem 'omniauth-oauth2'
gem 'omniauth-github'
# gem 'omniauth-att', :path => File.expand_path("./../../omniauth-att", __FILE__)
gem 'thin'