Skip to content

Instantly share code, notes, and snippets.

View avh4's full-sized avatar

Aaron VonderHaar avh4

View GitHub Profile
Scenario Outline: Religious menus
Given the customer is "<Religion>"
When he asks for the menu
Then he should see pork selections if <Pork>
And he should see lamb selections if <Lamb>
And he should see veal selections if <Veal>
Scenarios:
| Religion | Pork | Lamb | Veal |
| Christian | Y | Y | Y |
#!/usr/bin/python
"""md5dir -- Recursive MD5 checksums for files which move around
Usage: md5dir [options] [directories]
Without options it writes an 'md5sum' file in each subdirectory
containing MD5 checksums for that directories files.
During this it outputs progress dots, and then prints out the names of
@avh4
avh4 / RichText.elm
Last active October 14, 2016 18:49 — forked from Janiczek/RichText.elm
-- the type aliases would be private
type RichText
= RichText (List Line)
type alias Line =
{ left : List (Attributes, String)
, center : List (Attributes, String)
, right : List (Attributes, String)
@avh4
avh4 / CountOpenSafariTabs.scpt
Created October 31, 2020 19:28 — forked from edenwaith/CountOpenSafariTabs.scpt
AppleScript: Count the number of open tabs in Safari
-- CountOpenSafariTabs.scpt
-- Author: Chad Armstrong
-- Date: 13 May 2016
-- Description: Count the number of open tabs in Safari
-- To run from CLI: osascript CountOpenSafariTabs.scpt
tell application "Safari"
--Variables
set winlist to every window
@avh4
avh4 / string-conversions.hs
Created February 17, 2021 19:36 — forked from dino-/string-conversions.hs
A handy illustration of converting between String, Text and ByteString in Haskell
#! /usr/bin/env stack
-- stack --resolver lts-12.14 script
{-# LANGUAGE OverloadedStrings #-}
{-
This is a handy illustration of converting between five of the commonly-used
string types in Haskell (String, ByteString, lazy ByteString, Text and lazy
Text).