Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!wuarchive!zaphod.mps.ohio-state.edu!rpi!sci.ccny.cuny.edu!phri!cmcl2!kramden.acf.nyu.edu!brnstnd From: brnstnd@kramden.acf.nyu.edu (Dan Bernstein) Newsgroups: comp.unix.shell Subject: Re: How to do file | hold file (now cp) Message-ID: <2118:Sep1306:38:3790@kramden.acf.nyu.edu> Date: 13 Sep 90 06:38:37 GMT References: <19911:Sep1113:47:2290@kramden.acf.nyu.edu> <13611@hydra.gatech.EDU> Organization: IR Lines: 19 In article <13611@hydra.gatech.EDU> gt0178a@prism.gatech.EDU (BURNS,JIM) writes: : in article <19911:Sep1113:47:2290@kramden.acf.nyu.edu>, brnstnd@kramden.acf.nyu.edu (Dan Bernstein) says: : > In article <1990Sep11.040043.14727@chinet.chi.il.us> les@chinet.chi.il.us (Leslie Mikesell) writes: : >> In article <15472:Sep1015:27:3190@kramden.acf.nyu.edu> brnstnd@kramden.acf.nyu.edu (Dan Bernstein) writes: : >> >Of course the editor should use write-over, as it's conceptually : >> >modifying the *same* file. cp is putting a *different* file into the : >> >name previously used for the original. : >> Ah, but cp should only replace the *contents of the file*. : > No. That is not what cp does. cp copies a file with one name into a new : > file with a different name. The shell's > is what you use to replace the : > contents of a file. : The following script demonstrates that neither cp or > change the inode of : the original file s (& therefore, both change the *contents* of the file - : this is std behavior on 3 systems): We're all aware of that. I'm arguing that the behavior for cp is unintuitive. ---Dan