• 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
Invoking vi from apple script?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Invoking vi from apple script?


  • Subject: Invoking vi from apple script?
  • From: "Levan, Jerry" <email@hidden>
  • Date: Sun, 21 Apr 2002 18:51:21 -0400
  • Thread-topic: Invoking vi from apple script?

Doh!,

There seems to be some sort of confusion here...

Consider a droplet

on open (thefiles)
set afile to first item of thefiles
set afile to POSIX path of afile
--display dialog "--> " & (afile as text)
tell application "Terminal"
do script with command "vi " & (afile as text)
end tell
end open

I am trying to invoke "vi" by dropping a file on the icon.

It sorta works, Terminal pops open a window 25x80 and vi opens the appropriate file.

However, using the "j" or down arrow key will not scroll the file. Repeated use of
The j key will keep overwriting the last line.

The problem goes away if I manually resize the terminal window to be either larger or smaller, however if I resize
The window back to the original size the problem returns...

--Jerry
_______________________________________________
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: Running a stay open applet in OS X... :-(
  • Next by Date: Google and iTunes
  • Previous by thread: Re: Running a stay open applet in OS X... :-(
  • Next by thread: Re:Invoking vi from apple script?
  • Index(es):
    • Date
    • Thread