I've done a few things with bash lately, mainly about audio files (sox batch scripts). I try to learn, I'm reading and reading and searching, but sometimes "simple" questions I have to address just lead me to some tons of lines, web pages, and eventually no answer. This is one of them :
I need to address file 1 of a given input folder ($1
) , and compare one of its parameters to file 1 of another given input folder ($2
).
By: "file 1", I mean : the first file that would be listed if you call the directory content; like :
for f in "$1"/*
do
echo $f
done
My goal is to compare, by pair, file n of folder $1
with file n of folder $2
, where "n" is the "position" of the file in the folder, doesn't matter if they're listed by name or whatever, as they will be listed the same way in folder $1
and folder $2
when I run the script.
Applescript lets me address file 4 of folder 1 in a simple way; would it be much complicated in a bash script, or I am totally missing a basic thing ?
Thanks very much in advance