From 7ea1bd2ca2990366de6d9f3ad4c23c6dabcb1a1e Mon Sep 17 00:00:00 2001 From: Dangrain Date: Tue, 15 Oct 2024 22:11:07 +0200 Subject: [PATCH] Update converter.sh --- converter.sh | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/converter.sh b/converter.sh index d8850f1..2eb2e08 100644 --- a/converter.sh +++ b/converter.sh @@ -1,13 +1,11 @@ -#!/bin/bash - -# Create the new folder if it doesn't exist +# Make a mp4s folder If It isn't already there 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 - # Extract the base name of the file without the extension + # Picks the names of .AVI files 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" done