On this page, I collect both frequently and rarely used commands.

{{ toc }}

## Join PDF Files With Ghostscript

    gs -dSAFER -dBATCH -dNOPAUSE -sDEVICE=pdfwrite -sOUTPUTFILE=out.pdf 1.pdf 2.pdf 3.pdf

Last tested with gs 10.0.0 on 18 Nov 2022.

## Resize Window on macOS

    osascript -e 'tell app "Firefox" to set bounds of front window to {0, 0, 1200, 720}'

Last tested on macOS 15.3.2 on 19 Feb 2026.