• 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: Get current working directory
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Get current working directory


  • Subject: Re: Get current working directory
  • From: Kevin Walzer <email@hidden>
  • Date: Sun, 02 Oct 2005 14:56:26 -0400
  • Organization: WordTech Software

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

I usually do something like

POSIX path of (path to me)

This works if the script is running as an application--if you are
running it in Script Editor it will return
/Applications/AppleScript/Script\ Editor.app.

do shell script "pwd" doesn't work in my experience: it returns /, which
is what app bundles see as their directory.


Cheers,

Kevin Walzer, PhD
WordTech Software
http://www.wordtech-software.com
sw at wordtech-software.com

Thomas Vatter wrote:
| How do I get the name of the current working directory in Applescript?
| I have tried cd `dirname $0` without success.
|
| _______________________________________________
| Do not post admin requests to the list. They will be ignored.
| Applescript-users mailing list      (email@hidden)
| Help/Unsubscribe/Update your Subscription:
|
|
|
| This email sent to email@hidden
|
|
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (Darwin)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFDQC1ZJmdQs+6YVcoRAkqRAJ9XajgMsv3SPzl52O7dC3ws1r2WZwCfSX4s
gfij67hl/UVhdp1lRtmgDGY=
=AIn1
-----END PGP SIGNATURE-----
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Get current working directory (From: Thomas Vatter <email@hidden>)

  • Prev by Date: Re: Get current working directory
  • Next by Date: Re: Can't get name of Window 1 in Excel
  • Previous by thread: Re: Get current working directory
  • Next by thread: Re: Get current working directory
  • Index(es):
    • Date
    • Thread