Re: applescript shell script SCP?
Re: applescript shell script SCP?
- Subject: Re: applescript shell script SCP?
- From: Stan Cleveland <email@hidden>
- Date: Mon, 08 Dec 2008 19:28:44 -0800
- Thread-topic: applescript shell script SCP?
On 12/8/08 6:04 PM, "Mark J. Reed" wrote:
> On Mon, Dec 8, 2008 at 8:33 PM, Stan Cleveland <email@hidden> wrote:
>> property ruby : do shell script "which ruby" -- get path to active ruby
>
> Dumb question #1: what's the point of this? You can just do 'do shell script
> "ruby ..." ' - if that doesn't work, then neither will the "which".
Yes, that makes sense.
>> set resultText to do shell script (ruby & " -e \"require 'rubygems' ;
>> " & ¬
>
>> "require_gem 'net-sftp'
>
> require_gem? That's old school; I don't think it'll work on a modern version.
> Instead you just use -r, like for any other non-gem lib:
>
> ruby -rubygems -rnet-sftp -e \"Net::SFTP.start(" ...
I¹m no shell guru, that¹s for sure. I figured out something that worked a
few years back and ran with it. It still works.
I do appreciate your insights, Mark. As I implement the newer version of
Net-SFTP and write new code, I¹ll eliminate the "cruft."
Thanks,
Stan
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden