Skip to content

Instantly share code, notes, and snippets.

View henningjensen's full-sized avatar

Henning Jensen henningjensen

View GitHub Profile
@asux
asux / deploy.rb
Last active September 27, 2015 04:38
My typical multistaging deploy.rb for Vlad
require 'bundler/vlad'
require 'vlad/rvm'
set :default_stage, 'production'
set :shared_paths, {
'log' => 'log',
'system' => 'public/system',
'pids' => 'tmp/pids',
'sockets' => 'tmp/sockets',
@aslakhellesoy
aslakhellesoy / gitbox.sh
Created June 1, 2012 10:14
Set up a git remote in your DropBox
#!/bin/bash
# Call this script from a local git repo to set up a dropbox remote you can push and pull to
# I keep this script under ~/Dropbox/git/gitbox.sh
# Inspired from http://stackoverflow.com/questions/1960799/using-gitdropbox-together-effectively
PWD=`pwd`
PROJECT=`basename $PWD`
pushd $HOME/Dropbox/git
git init --bare $PROJECT.git
@johnnyreilly
johnnyreilly / GlobalizeUrls.cs
Last active October 10, 2015 06:58
A monkey patch for jquery.validate.js that allows validation to be internationalised
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Hosting;
using System.IO;
using System.Globalization;
namespace My.Helpers
{
@gnab
gnab / bindings.js
Last active December 28, 2015 23:29
KO numeric extension.
ko.bindingHandlers.number = {
update: function (element, valueAccessor, allBindings, viewModel, bindingContext) {
var value = ko.unwrap(valueAccessor());
valueAccessor = function () {
return value.toString().replace('.', ',');
};
ko.bindingHandlers.text.update(element, valueAccessor, allBindings, viewModel, bindingContext);
}
};
@ChaseFlorell
ChaseFlorell / Deploy-TeamCityBuildToOctopus.ps1
Last active September 5, 2020 08:48
a script for TeamCity to get git commits and pass them along to Octopus Deploy
# credit for getting me going in the right direction
# http://blogs.lessthandot.com/index.php/uncategorized/access-git-commits-during-a-teamcity-build-using-powershell/
# these properties should be entered into your configuration parameters section
$project = "%Octopus.Project%"
$deployTo = "%Octopus.DefaultEnvironment%"
$buildVersion = "%BuildVersion%"
$octopusApiKey = "%Octopus.BuildDeployBot.APIKey%"
$octopusServer = "%Octopus.Server.Url%"
@bobbychopra
bobbychopra / App.xaml.cs
Created June 8, 2012 17:42
Log4Net Configuration in WPF
using System.Windows;
using log4net;
namespace Namespace
{
/// <summary>
/// Interaction logic for App.xaml
/// </summary>
public partial class App : Application
{
@rolo
rolo / gist:1481128
Created December 15, 2011 13:44
Install Postgres 9.1, PostGIS and create PostGIS template on Ubuntu 11.10 Oneiric Ocelot
#!/bin/bash
#
# Install Postgres 9.1, PostGIS and create PostGIS template on a clean Ubuntu 11.10 Oneiric Ocelot box
# http://wildfish.com
# add the ubuntu gis ppa
sudo apt-get -y install python-software-properties
sudo add-apt-repository ppa:ubuntugis/ubuntugis-unstable
sudo apt-get update
@djq
djq / gist:2846196
Last active September 27, 2022 04:12 — forked from rolo/gist:1481128
Install Postgres 9.1, PostGIS 2.0.2 and PG Routing on Ubuntu 12.04 (Precise Pangolin)
#!/bin/bash
#
# Install Postgres 9.1, PostGIS 2.0 and pgRouting on a clean Ubuntu 12.04 install (64 bit)
# updated to PostGIS 2.0.1
# basics
apt-get install python-software-properties
apt-add-repository ppa:sharpie/for-science # To get GEOS 3.3.3
# install the following pacakages
@stevenkuhn
stevenkuhn / gist:5062660
Last active March 7, 2023 16:03
This PowerShell script generates release notes for Octopus Deploy that contain the GitHub commits and JIRA issues from the current build to the latest production release. It will also create the Octopus release based on the TeamCity build number.
#
# Assumptions
#
# 1. If you have a Octopus release deployed, say 1.0.0.73, there is a git
# tag set for that commit in GitHub that is "v1.0.0.73".
#
# 2. You have TeamCity label each successful build in GitHub with the format
# "v{build number}. Sidenote: it appears that TeamCity only labels the
# default branch, but not feature branches.
#
@Epigene
Epigene / Dokku v0.5.6 Rails App.md
Last active January 5, 2024 14:48
Knowledge-Base for getting a Rails5 app with Cable running on dokku v0.5.6

Dokku v0.5.6 Rails workflow

Straight to Maintenance

0. Set up Droplet

Initialize the droplet with dokku app pre-setup