Skip to content

Instantly share code, notes, and snippets.

@AlexKrupa
AlexKrupa / shokz-openswim.fish
Last active November 27, 2023 20:47
Shokz OpenSwim — large audio file segmentation & tempo adjustment — Fish shell script
# Prepare a podcast or audiobook MP3 file to use on Shokz OpenSwim swimming headphones.
#
# It does 2 things:
# 1. Speeds up the tempo. I usually prefer listening to spoken content at 1.5x–2x.
# 2. Splits the file into equal-length segments to make rewind/fast-forward possible on the headphones.
# This is a workaround for lack of built-in fine-grained rewind/fast-forward controls on the headphones.
# The headphones can only do previous/next.
# Now imagine doing it accidentally on a several-hours long audiobook.
# That's why I wrote this script.
function shokz