Update converter.sh

This commit is contained in:
Dangrain 2024-10-15 22:11:07 +02:00 committed by GitHub
parent a270690a0e
commit 7ea1bd2ca2
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1,13 +1,11 @@
#!/bin/bash # Make a mp4s folder If It isn't already there
# Create the new folder if it doesn't exist
mkdir -p mp4s mkdir -p mp4s
# Loop through all .AVI files in the current directory # Looks for all .AVI files in the directory
for file in *.AVI; do for file in *.AVI; do
# Extract the base name of the file without the extension # Picks the names of .AVI files
base_name=$(basename "$file" .AVI) base_name=$(basename "$file" .AVI)
# Convert the file to .mp4 and place it in the mp4s folder # Places the files into the mp4s directory
ffmpeg -i "$file" -c:v libx264 -c:a aac "mp4s/${base_name}.mp4" ffmpeg -i "$file" -c:v libx264 -c:a aac "mp4s/${base_name}.mp4"
done done