Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!wuarchive!uunet!stanford.edu!agate!e260-1g.berkeley.edu!c60b-1eq From: c60b-1eq@e260-1g.berkeley.edu (Noam Mendelson) Newsgroups: comp.unix.questions Subject: Re: Changing directories in the background Keywords: cd background Message-ID: <1991May1.061341.6951@agate.berkeley.edu> Date: 1 May 91 06:13:41 GMT References: Sender: root@agate.berkeley.edu (Charlie Root) Distribution: comp.unix.questions Organization: University of California, Berkeley Lines: 15 In article gheim@eng.auburn.edu (Greg Heim) writes: >I just tried the following: > cd /new/dir & >by accident and my directory didn't change. Can anybody tell me what happens >internally here? If cd is run in the background, the newly spawned process gets the new cwd, not your shell. Each process has its own cwd. The process that's spawned is terminated immediately (I would hope), so there's no harm done. -- +==========================================================================+ | Noam Mendelson ..!ucbvax!web!c60b-1eq | "I haven't lost my mind, | | c60b-1eq@web.Berkeley.EDU | it's backed up on tape | | University of California at Berkeley | somewhere." |