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
set DEAD " "; set LIVE "🌱"; set wid 21; set hei 21 | |
for cell in b(seq 2)r(seq $hei)c(seq $wid); set -g $cell $DEAD; end | |
set -g flip 1; set -g flop 2 | |
function show_board | |
for row in (seq $hei); for col in (seq $wid); set -l cell b{$flip}r{$row}c{$col}; echo -n $$cell | |
end; echo; end; end | |
set b1r10c10 $LIVE; set b1r10c11 $LIVE; set b1r10c12 $LIVE; | |
set b1r11c10 $LIVE; set b1r11c12 $LIVE; | |
set b1r12c10 $LIVE; set b1r12c11 $LIVE; set b1r12c12 $LIVE; | |
while true |
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
using System; | |
using System.Collections.Generic; | |
using System.Configuration; | |
using System.IO; | |
using System.Text; | |
using System.Threading; | |
using System.Xml; | |
using System.Xml.Serialization; | |
using System.Linq; | |
using domain; |
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
#set up the dir structure if it doesn't exist | |
set t ~/.trello; mkdir -p $t | |
function if_exist # we don't want to litter our code with ifs if a read model or events are not there yet. Return /dev/nul for empty | |
if test -e $t/$argv[1]; echo $t/$argv[1]; else; echo /dev/null; end | |
end | |
function list # provide lists from our tab delimited entries with filtering and line item numbers to make choices | |
set list $argv[1]; set column_to_show $argv[2]; set filter $argv[3]; set count 1 | |
cat (if_exist $list) | grep -e "$filter\$" | while read line | |
set -l line_items (string split \t $line) | |
echo $count\) $line_items[$column_to_show] |
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 | |
# | |
# An example hook script to make use of push options. | |
# The example simply echoes all push options that start with 'echoback=' | |
# and rejects all pushes when the "reject" push option is used. | |
# | |
# To enable this hook, rename this file to "pre-receive". | |
# check if back merges are happening from important branches | |
echo "checking for bad branch names" |
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
using System; | |
using System.Collections.Generic; | |
using System.IO; | |
using System.Threading; | |
using Messages; | |
using NUnit.Framework; | |
using Services; | |
using Test.SampleNamespace; | |
using TransactionStorage; | |
using System.Linq; |
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
var db = require('mongodb'), | |
server = new db.Server('alex.mongohq.com', 10053, {auto_reconnect: true}), | |
con = new db.Db('consentiment', server); | |
// callback: (err) | |
exports.connect = function(callback) { | |
con.open(function opened(err, db) { | |
if (err) return callback(err); | |
//return callback(false, db); | |
//return false; |