• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: mkdir in shell script
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: mkdir in shell script


  • Subject: Re: mkdir in shell script
  • From: Markian Hlynka <email@hidden>
  • Date: Mon, 23 Aug 2004 11:17:19 -0600

Have you tried mkdir -p? I'm not sure if that does what you want or not.

also, you could try checking mkdir's return value...

I have more information on this somewhere, but I'm not sure it didn't get lost in a crash.

Markin
On Aug 23, 2004, at 10:29, Chuck Soper wrote:

Hello,
I have a shell script build phase that uses rsync to copy data files to a sub-directory within my Resources directory in my bundle. Right now the script only copies files to the sub-directory, it doesn't create the sub-directory. Every time I clean and re-build I have to manually create the sub-directory.


What is the proper way to create a sub-directory via a shell script build phase? I'd like to write: if sub-directory doesn't exist then mkdir path. Can someone help me with this Unix command? (I think I could always call mkdir and have it error out 99% of the time, but that doesn't seem very clean to me.)
Chuck
_______________________________________________
xcode-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/xcode-users
Do not post admin requests to the list. They will be ignored.
_______________________________________________
xcode-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/xcode-users
Do not post admin requests to the list. They will be ignored.


References: 
 >mkdir in shell script (From: Chuck Soper <email@hidden>)

  • Prev by Date: mkdir in shell script
  • Next by Date: Relative Paths?
  • Previous by thread: mkdir in shell script
  • Next by thread: Re: mkdir in shell script
  • Index(es):
    • Date
    • Thread