• 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: Why root?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Why root?


  • Subject: Re: Why root?
  • From: John Delacour <email@hidden>
  • Date: Fri, 2 Aug 2002 21:54:27 +0100

At 12:41 pm -0700 2/8/02, Christopher Nebel wrote:

(What do you mean "BBEdit takes you to the user directory"? How can you tell?)

--Chris Nebel
AppleScript Engineering

By typing 'ls' in a new BBEdit shell window, hitting the enter key and getting a list of items in my user directory, precisely as happens in the Terminal window.

Or by typing 'set' ditto.

If a user didn't have read permission for /, they'd get an empty result, because "ls" returns 0

Quite so, but why should you take everybody to a directory that nobody's expecting to end up in? I log in to the system as jd, so I expect to be taken to users/jd. I'm no unix-head but from the little I have read, that's what a unix head would expect.

And if in BBEdit I type 'sh<ENTER>' before I type 'set<ENTER>' I get this in the list:

PWD=/Users/jd

so what am I to make of your statement that

the "sh" process that it invokes, inherits the working directory of its parent, and the Finder launches everything with a working directory of "/".

and in a new Terminal window;

Welcome to Darwin!
[localhost:~] jd% sh
localhost% PWD
/Users/jd
localhost% pwd
/Users/jd
localhost%

JD
_______________________________________________
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.

  • Follow-Ups:
    • Re: Why root?
      • From: Christopher Nebel <email@hidden>
    • Re: Why root?
      • From: Mr Tea <email@hidden>
References: 
 >Re: Why root? (From: Christopher Nebel <email@hidden>)

  • Prev by Date: Trim?
  • Next by Date: Log
  • Previous by thread: Re: Why root?
  • Next by thread: Re: Why root?
  • Index(es):
    • Date
    • Thread