Bash Remove Extension
- Previous: Nginx + Cloudflare SSL
- Next: “The Secret Loves of Geek Girls”
I can't imagine me ever needing this again, but it does highlight bash's ability to strip extensions.
To convert avis to mkv's and update language from unknown to english:
for i in *.avi; do
mkvmerge -o "${i%.avi}.mkv" "$i" \
&& mkvpropedit "${i%.avi}.mkv" --edit track:a1 \
--set language=rus --edit track:a2 --set language=eng;
done
- Previous: Nginx + Cloudflare SSL
- Next: “The Secret Loves of Geek Girls”