Create ISO image from folder

moses19850

I wrote a script which creates and ISO image from a folder, but when the folder contains spaces, I get an error message. Can somebody please help me? I'm working with Mac OSX Mavericks and Terminal.

Thanks in advance.

Script:

#!/bin/sh
cd /Volumes/Daten/fake
for i in ./*; do hdiutil makehybrid -udf -joliet -iso -o /Volumes/Daten/test/$i ./*;done

error:

hdiutil: makehybrid: multiple sources specified
Gordon Davisson

Use double-quotes around all variable references (e.g. "$i") to prevent word splitting. BTW, it also looks like your script will fail if there's more than one item in /Volumes/Daten/fake, because the ./* at the end of the hdiutil command will try to include all of the items in each image, which will also fail. Finally, ./* is generally unnecessary; just use *. I think you want this:

#!/bin/sh
cd /Volumes/Daten/fake
for i in *; do
    hdiutil makehybrid -udf -joliet -iso -o "/Volumes/Daten/test/$i" "$i"
done

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

From Dev

Create subdomain from a folder, but deny folder access

From Dev

How to create a drawable from an image in assets folder?

From Dev

Create and then directly load an image from a folder inline with HTML

From Dev

How can i create a windows vagrant box from existing windows iso image

From Dev

Unable to boot from ISO image

From Dev

How to create an ISO image from a bunch of files on the file system?

From Dev

How can I create a bootable iso image from a bootable flash drive?

From Dev

Install Windows 7 from ISO image

From Dev

Unable to boot from ISO image

From Dev

Create a DVD Video ISO image from a directory

From Dev

Create iso image from folder via terminal commands

From Dev

Create a Random ISO Image Using dd

From Dev

How to create an ISO image from a bunch of files on the file system?

From Dev

How to create a mountable ISO image file

From Dev

How to upgrade Ubuntu from an ISO image

From Dev

Installing Matlab from an ISO image

From Dev

Delete image from folder

From Dev

How to create a drawable from an image in assets folder?

From Dev

Displaying image from a folder

From Dev

how to find iso image according to mounted folder?

From Dev

Create bootable RedHat iso from folder

From Dev

Create folder and store Image by camera

From Dev

How to burn an iso image from the command line

From Dev

How to Create ISO Image of installed Ubuntu 16.10

From Dev

How to mount an ISO image to a specific folder in Mac OS X?

From Dev

How to Create a Bootable ISO from Folder Directory?

From Dev

Create ISO from unetbootin?

From Dev

How to create an ISO disk image of an NVMe SSD?

From Dev

Create ISO from Linux image with verify

Related Related

HotTag

Archive