• 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
passing shell script arguments?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

passing shell script arguments?


  • Subject: passing shell script arguments?
  • From: Star <email@hidden>
  • Date: Thu, 2 Oct 2003 15:48:55 -0400 (GMT-04:00)

Hello,

I have a rather lengthy shell script that acts upon a file path and posts results to a log file. I have been able to read this large shell script into a property and save it inside my applescript that way. The problem I am having though is that the arguments I am passing to the shell script are not being passed right. I am trying many logical ways that do not seem to work. The shell understands the shell script because it is asking for the arguments, it does not like the way I am passing them. After searching the list archives I am more confused than before as to what to try next. Please help, I'm close but stumped here. . .

The syntax is like this:


-- ATTEMPT 1
-- created posix path to file as variable and passed like this...
-- set DoScript to (myShellCode & " \"" & TestFile & " \"" & SR_FileLog) as string
= Result (sh: test_file log_file)

-- ATTEMPT 2
-- here I tried to make the posix path on the fly from the file reference like this....
--do shell script (myShellCode & space & POSIX path of TestFile & space & POSIX path of SR_FileLog)
= Result (sh: test_file log_file)

-- ATTEMPT 2
-- created posix path to file as variable and passed like this...
-- do shell script (myShellCode & " " & TestFile & " " & FileLog)
= Result (sh: test_file log_file)

Thanks, Patrick
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.

  • Prev by Date: Re: Write underlined text to a file
  • Next by Date: Create New Message script for Apple Mail
  • Previous by thread: Re: Write underlined text to a file
  • Next by thread: Re: passing shell script arguments?
  • Index(es):
    • Date
    • Thread