For each different folder how to make a different .iso?

I have 12 folders

one
two
three
four
...

I wish to make something like this

one.iso
two.iso
...

but I don't know what command can I use. Any suggestion?

with Mkisofs you can use

mkisofs –o backup.iso /home/tin/Documents/backup

but this command is only for 1 folder: 1 iso file but I want 12 folders:12 iso files


In the comments I told you to run:

for d in */; do
    mkisofs -o "$d.iso" "$d"
done

This created hidden files .iso in each of the directory, because inside the loop, $d contains a trailing slash, and evaluates to one/.iso instead of the expected one.iso.

So, please delete these files first:

rm */.iso

Now (and next time) you can do the right thing directly:

Go to the parent directory of your 12 directories and make a loop:

for d in */; do
    mkisofs -o "${d%/}.iso" "$d"
done

--> ${d%/} removes the trailing slash.

The iso files will be next to the directories named like

one.iso
two.iso
...