Skip to content

Instantly share code, notes, and snippets.

View agh1's full-sized avatar

Andie Hunt agh1

View GitHub Profile
@agh1
agh1 / letter.sh
Created June 20, 2020 22:20
Markdown to HTML to PDF
#!/bin/bash
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
sourcefile=$1
if [ -z $1 ] ; then
if ! [ -f $DIR/letter.md ]; then
echo 'You must set up your letter as `letter.md` or specify a file name.'
exit 1;
fi
@agh1
agh1 / NavAdd.php
Last active April 27, 2017 15:42
A class to prepare the menu array for an extension to add additional items
<?php
/**
* A class to prepare the menu array for an extension to add additional items.
*
* Usage:
* function yourextension_civicrm_navigationMenu(&$menu) {
* $adder = new CRM_Utils_NavAdd($menu);
* $attributes = array(
* 'label' => ts('One thing'),