Skip to content

Instantly share code, notes, and snippets.

@mstapp
mstapp / post-receive
Created February 12, 2014 18:10
git post-receive hook to ping jenkins & start build
#!/bin/sh
#
# Simple git post-receive script: start Jenkins build
# ping Jenkins to kick off a build
# (specify IP)
curl -X POST -s http://10.x.x.x:8080/view/GUI/job/WebUI_Build/build?delay=0sec
@mstapp
mstapp / .gitconfig-Mac
Created February 12, 2014 18:16
My .gitconfig settings on OS X
#
# My common settings for Mac
# Currently using Sublime editor, perforce p4merge
[user]
name = Mike Stapp
email = xxx@xxx
[core]
editor = subl -n -w
@mstapp
mstapp / 1.js
Created March 9, 2014 18:22
blog - attach view to html
// attach to static html at element "#navbar-links"
var myview = new MyView( {el: $('#navbar-links')} );
// … find all gist scripts inside the ajax container
var $gists = $ajax_container.find('script[src^="https://gist.github.com/"]');
// if gist embeds are found
if( $gists.length ){
// update each gist
$gists.each(function(){
// we need to store $this for the callback
function add_stylesheet_once( url ){
$head = $('head');
if( $head.find('link[rel="stylesheet"][href="'+url+'"]').length < 1 )
$head.append('<link rel="stylesheet" href="'+ url +'" type="text/css" />');
}
@mstapp
mstapp / 1.js
Created March 16, 2014 02:46
blog - part 2 attach view to html
var App = new Backbone.Marionette.Application();
App.addRegions({
primaryRegion: "#primary-region",
});
#!/bin/bash
# CentOS rbenv system wide installation script
# Forked from https://gist.github.com/1237417
# Installs rbenv system wide on CentOS 5/6, also allows single user installs.
# Install pre-requirements
yum install -y gcc-c++ patch readline readline-devel zlib zlib-devel libyaml-devel libffi-devel openssl-devel \
make bzip2 autoconf automake libtool bison iconv-devel git-core
# Load balancer configuration
upstream exampleApp {
# Directs to the process with least number of connections.
least_conn;
# One failed response will take a server out of circulation for 20 seconds.
server 127.0.0.1:10080 fail_timeout=20s;
#server 127.0.0.1:10081 fail_timeout=20s;
#server 127.0.0.1:10082 fail_timeout=20s;
#server 127.0.0.1:10083 fail_timeout=20s;

Date: [date]

Between us [company name] and you [customer name].

Summary:

In short; neither of us will share any confidential information about each-other, by any means, with anyone else.

What’s confidential information?

Contract Killer

The popular open-source contract for web designers and developers by Stuff & Nonsense

  • Originally published: 23/12/2008
  • Revised date: 15/12/2013
  • Original post