etc
home
default
.config
.fonts
.local
scripts
append-urls-to-titles
clean-syncthing-conflicts
create-playlist
del-macos-folders
generate-playlists
hash-filenames
list-packages
prep-camera-photo
proverb
prune-free-space
record-screen
record-screen-no-audio
refresh-screens
remove-exif
restart-bluetooth
screenshot
standardize-music
titles-to-youtube-playlist
update-mirrors
wget-titles-from-urls
youtube-archive
youtube-archive-audio
youtube-audio
.bashrc
.profile
.tool-versions
.xprofile
.gitignore
packages.txt
preview.png
readme.md
42 lines
852 B
Bash
Executable File
42 lines
852 B
Bash
Executable File
#!/usr/bin/env sh
|
|
set -oux pipefail
|
|
|
|
# removes more modern codecs to just files that can fit on my mp3 player
|
|
|
|
count=`ls -1 *.M4A 2>/dev/null | wc -l`
|
|
if [ $count != 0 ]; then
|
|
rename M4A m4a *.M4A
|
|
fi
|
|
|
|
count=`ls -1 *.m4a 2>/dev/null | wc -l`
|
|
if [ $count != 0 ]; then
|
|
for i in *.m4a; do
|
|
ffmpeg -i "$i" "${i%.*}.ogg" && rm "$i"
|
|
done
|
|
fi
|
|
|
|
count=`ls -1 *.WEBM 2>/dev/null | wc -l`
|
|
if [ $count != 0 ]; then
|
|
rename WEBM webm *.WEBM
|
|
fi
|
|
|
|
count=`ls -1 *.webm 2>/dev/null | wc -l`
|
|
if [ $count != 0 ]; then
|
|
for i in *.webm; do
|
|
ffmpeg -i "$i" "${i%.*}.ogg" && rm "$i"
|
|
done
|
|
fi
|
|
|
|
count=`ls -1 *.OPUS 2>/dev/null | wc -l`
|
|
if [ $count != 0 ]; then
|
|
rename OPUS opus *.OPUS
|
|
fi
|
|
|
|
count=`ls -1 *.opus 2>/dev/null | wc -l`
|
|
if [ $count != 0 ]; then
|
|
for i in *.opus; do
|
|
ffmpeg -i "$i" "${i%.*}.ogg" && rm "$i"
|
|
done
|
|
fi
|
|
|