Skip to content

Instantly share code, notes, and snippets.

@sorbits
sorbits / every
Last active July 4, 2024 03:28
Run «command» only every «number» time invoked
#!/usr/bin/env bash
progname=$(basename $0)
version="1.0 (2014-08-17)"
step=2
function create_hash {
openssl dgst -sha1 -binary <<< "$1" | xxd -p
}