Skip to content

Instantly share code, notes, and snippets.

Challenging Intro
Glora with Fritz Perls:
confrontational interaction: (3:18)
Getting closer: (1:18)
roundand /
Last active December 4, 2018 12:31
Doing a command-line demo of the karate API test framework using pre-compiled JARs

Not interested in this as Java, so followed isntruction in

  • Ensure Java installed
  • Download karate jar file as described, and rename to karate.jar
  • Download following files into the same directory:
    • cats-mock.fearure
    • cats-test.feature
    • cats.html
  • Open console in directory, and start server with java -jar karate.jar -m cats-mock.feature -p 8080 &
  • Open cats.html as a file link in a web browser, and experiment
roundand / SketchSystems.spec
Created August 3, 2018 13:22
My Awesome Sketch
My Awesome Sketch
First State
some event -> Second State
Second State
roundand / makefile
Last active December 19, 2017 07:37
Generating ad-hoc GOPATH and relative working directory from current working directory
xyz = $(shell expr '/home/fn/go/fred' : '\(.*go/\)')
XGP=$$(expr '/home/fn/go/fred' : '\(.*go/\)'); \
echo XGP $$XGP; \
export XWD=$$(expr '/home/fn/go/fred' : '.*/go/\(.*\)'); \
echo XWD $$XWD; \
echo xyz $(xyz)
roundand / Dockerfile
Created December 4, 2017 23:16
godog Dockerfile
FROM golang
RUN go get
WORKDIR /go/godog
CMD ["godog"]
roundand /
Last active October 1, 2017 11:33
Minimal Busybox-compatible echo server (also good for Alpine)

Using nc (aka netcat) as a commonly available solution (but this syntax only tested for Alpine):

nc -lkp 8088 -e /bin/cat


  • -l for listen
  • -k to keep running for multiple calls (unavailable on busybox)
  • -p for port parameter
  • -e for program to execute (in the absence of a filename, cat echoes stdin to stdout)
roundand /
Last active July 27, 2017 19:29
Vim cheatsheet

Search and Replace

:s/pattern/string/ Replace pattern with string on line

:%s/pattern/string/ Replace pattern with string throughout document


g Global. Replace all c Confirm i case-insensitive

Copy and Paste

roundand / echoDump.go
Last active December 14, 2016 15:56
echoDump can bind to any hostname and port, and responds to all accepted queries by echoing a dump of the incoming request.
// echoDump is a minimal "echo" server that responds with a dump of the incoming request.
// (Based on
package main
import (
roundand / AsyncEvents
Created June 13, 2014 14:29
Demonstration of Async Event processing in PowerShell v2
# Illustration (based on concepts in
# and code nicked from an answer in
# )
roundand / replaceTokens.linq
Last active August 29, 2015 13:57
linqPad demo of c# Regex extension method to replace tokens in a string using a token / value dictionary
<Query Kind="Program" />
// define regex to match $-delimited tokens, eg $name$
static Regex toke = new Regex(@"\$(\w+)\$", RegexOptions.Compiled);
static void Main()
string input = @"Dear $name$, as of $date$ your balance is $amount$";
var args = new Dictionary<string, string>(StringComparer.OrdinalIgnoreCase);
args.Add("name", "Mr Smith");