Initial commit

This commit is contained in:
Robin Steinberg 2024-04-07 20:56:24 +02:00
commit ff09a81c76
2 changed files with 20 additions and 0 deletions

13
mp3convert Executable file
View File

@ -0,0 +1,13 @@
#!/bin/bash
FLAC="$1"
OUT_DIR="mp3"
# get filename without extension
FILENAME="${FLAC##*/}"
# make filename with .mp3 extension
MP3="./${OUT_DIR}/${FILENAME%.flac}.mp3"
mkdir -p "$OUT_DIR"
if [[ ! -f "$MP3" ]]; then
ffmpeg -i "$FLAC" -c:a libmp3lame -b:a 320K -map a:0 "$MP3"
fi

7
tidalconvert Executable file
View File

@ -0,0 +1,7 @@
#!/bin/bash
mkdir -p flac
mv *.flac flac/
# call mp3convert on every file inside the flac directory
find flac -name '*.flac' -exec bash -c 'mp3convert "$1"' _ {} \;