Skip to content

Instantly share code, notes, and snippets.

View tvwerkhoven's full-sized avatar

Tim van Werkhoven tvwerkhoven

  • ASML
  • Netherlands
View GitHub Profile
@tvwerkhoven
tvwerkhoven / xelatex-test.tex
Created October 29, 2010 10:57
Adaption of 'Beauty of LaTeX' by Dario Taraborelli (2008)
%!TEX TS-program = xelatex
%!TEX encoding = UTF-8 Unicode
% Dario Taraborelli (2008)
% The Beauty of LaTeX
% URL: http://nitens.org/taraborelli/latex
% Some rights reserved: CC-BY-SA
\documentclass[11pt,a4paper]{article}
\usepackage[dvipdfm, colorlinks, breaklinks, pdftitle={The Beauty of LaTeX},pdfauthor={Taraborelli, Dario}]{hyperref}
@tvwerkhoven
tvwerkhoven / newton.tex
Created October 29, 2010 10:59
Render of Newton's Principia in XeLaTeX
%!TEX TS-program = xelatex
%!TEX encoding = UTF-8 Unicode
% Tim van Werkhoven (2010)
% newton.tex: Render of Newton's Principia in XeLaTeX
% Some rights reserved: CC-BY-SA
\documentclass[11pt,a4paper]{article}
\usepackage[dvipdfm, colorlinks, breaklinks]{hyperref}
@tvwerkhoven
tvwerkhoven / fx33video.sh
Created April 5, 2010 19:50
Convert Panasonic FX33 videos
#!/bin/bash
#
# Simple mencoder call to convert video from the Panasonic Lumix FX33 to xvid
# with mp3 in an avi container and x264 with mp3 in a mkv container. Run as:
#
# ./fx33video <input.mov>
#
# ffmpeg info about FX33 videos:
# Stream #0.0(eng): Video: mjpeg, yuvj420p, 640x480 [PAR 0:1 DAR 0:1], 30.00
# tb(r)
@tvwerkhoven
tvwerkhoven / renamemp3.py
Created April 5, 2010 20:04
Recursively rename all files in a directory
#!/usr/bin/env python
# encoding: utf-8
#
# Recursively rename all files in a directory with the following rules:
# - Convert letters to lower case
# - Convert whitespace to underscore
#
# Used to clean up filenaming of mp3s
#
# Tim van Werkoven, 20090426 <t.i.m.vanwerkhoven@xs4all.nl>
@tvwerkhoven
tvwerkhoven / worddistance.pl
Created April 5, 2010 20:07
Find the word distance for each word, and signal words that are close together
#!/usr/bin/perl -w
#
# Find the word distance for each word, and signal words that are close
# together. Can be useful for reviewing written text (papers, essays,
# whatever) to see if you might need a thesaurus somewhere.
#
# Tim van Werkoven, 20090426 <t.i.m.vanwerkhoven@xs4all.nl>
# This file is licensed under the Creative Commons Attribution-Share Alike
# license versions 3.0 or higher, see
# http://creativecommons.org/licenses/by-sa/3.0/
@tvwerkhoven
tvwerkhoven / randmac.sh
Created April 5, 2010 19:59
Generate a random MAC address
#!/bin/bash
#
# Generate a random MAC address with a known vendor prefix from the nmap mac
# prefixes file.
#
# Tim van Werkoven, 20100405 <t.i.m.vanwerkhoven@xs4all.nl>
# This file is licensed under the Creative Commons Attribution-Share Alike
# license versions 3.0 or higher, see
# http://creativecommons.org/licenses/by-sa/3.0/