Skip to content

Instantly share code, notes, and snippets.

View wimstockman's full-sized avatar

Wim Stockman wimstockman

View GitHub Profile
@wimstockman
wimstockman / groff-install-font
Created January 27, 2020 10:53 — forked from torbiak/groff-install-font
Install ttf and otf fonts for use with groff
#!/usr/bin/env bash
# groff-install-ttf converts a TrueType (ttf) or OpenType (otf) font to a
# Printer Font ASCII (pfa) font and a groff font (ditroff) and installs them to
# groff's site-font directory.
#
# Requires fontforge.
#
# You're the best, Peter Schaffter, but contrary to the verbose and
# difficult-to-follow http://www.schaffter.ca/mom/momdoc/appendices.html#fonts,
# the t42 file doesn't seem to be necessary, at least with recent versions of
@wimstockman
wimstockman / awk_tips_trickd.txt
Created March 10, 2018 07:55
Awk tips and tricks
//multidimensional arrays in gawk
for (i in arr) for (j in arr[i])
print i,j, arr[i][j]