View compr.sh
#!/usr/bin/env bash
# -*- coding: UTF-8 -*-
# compress all pdf files in a folder -- 2018 ckunte
for i in *.pdf; do gs -sDEVICE=pdfwrite -dCompatibilityLevel=1.4 -dPDFSETTINGS=/prepress -dNOPAUSE -dQUIET -dBATCH -sOutputFile=compr_$i $i; done
View w2p.bat
echo off
for %%X in (*.doc) do cscript.exe //nologo word2pdf.js "%%X"
View zsh.md
  1. Search for edit env in the Start menu search to find Edit environment variables for your account. Click on it.

  2. Click New... in User variables.. and in the following menu, enter:

     Variable name : SHELL
     Variable value: /usr/bin/zsh
    

    Press OK, and OK.

  3. Close and restart Cygwin Terminal, and it should start with zsh.

View fwpdf.py
#!/usr/bin/env python
# -*- coding: UTF-8 -*-
'''
2014 ckunte
'''
import os
import platform
platforms = os.walk('.').next()[1]
for platform in platforms:
View Makefile
# Makefile for backup and restore routines
# 2017 ckunte
# License: unlicense <unlicense.org>
SRCE=/Volumes/643
CPRJ=cproj
PPRJ=pproj
CREF=cref
PREF=pref
DEST=/Volumes/CK240
View scripting-replies.ahk
; Scripting replies in Outlook 2016 with AutoHotkey
; Hit Ctrl + Win + r to create a reply email (template) with salutation to sender's
; First Name from selected / opened email in Microsoft Outlook, which looks like this:
;
; Hi <FirstName>,
;
; Thank you for your email.
;
; <Signature appears here, if set-up in Outlook>
;
View fm1.sh
for f in *;
do sed '1i\
title: ' < $f > tmp_$f ;
mv tmp_$f $f ;
done
for f in *;
do sed '2i\
date: ' < $f > tmp_$f ;
mv tmp_$f $f ;
View cf.sh
#!/usr/bin/env zsh
autoload -U zmv
# Safety first: Always use -n switch to test changes before commit.
# Clean up file names in subdirectories and remove special characters
zmv -n '(**/)(*)' '$1${2//[^A-Za-z0-9.-]/_}'
# Replace spaces in filenames and folders with a hyphen
zmv -n '* *' '$f:gs/ /-'
View mackeyboard.ahk
; Emulate macOS behaviour w/ a Mac keyboard on Windows
; 2017 ckunte
;
; credits to @mattheath and @stroebjo the very many shortcuts
;
; NOTES
;
; ! = ALT
; ^ = CTRL
; + = SHIFT
View rentreceipt.tex
%!TEX TS-program = xelatex
%!TEX encoding = UTF-8 Unicode
\documentclass[a5paper,11pt]{article}
\usepackage{geometry}
\usepackage{numname,sistyle}
\SIthousandsep{,}
%
% Start entering rental details below:
%
\newcommand{\mfr}{April 2016} % Month from