Skip to content

Instantly share code, notes, and snippets.

@jorgehatccrma
jorgehatccrma / awk1liners.md
Created April 12, 2018 18:20
AWK one liners

HANDY ONE-LINE SCRIPTS FOR AWK

Based on this gist compiled by Eric Pement - eric [at] pement.org

USAGE:

awk '/pattern/ {print "$1"}'    # standard Unix shells

FILE SPACING:

@jorgehatccrma
jorgehatccrma / recursive-resample.sh
Last active June 29, 2023 14:48
Recursively resample a bunch of audio files in a directory, using sox
#!/bin/bash
# A simple script to recursively resample a bunch of files
# in a directory. Only certain file extensions (mp3, aac,
# flac, wav) are considered.
#
# It takes 2 command line options: `indir` and `outdir`.
# The destination (`outdir`) is relative to the current
# directory of where you were when the script was run.
#