Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!seismo!dalcs!lane From: lane@dalcs.UUCP (John Wright/Dr. Pat Lane) Newsgroups: comp.unix.questions Subject: Append file commands for Unix & ex/vi Message-ID: <2333@dalcs.UUCP> Date: Sun, 11-Jan-87 10:15:09 EST Article-I.D.: dalcs.2333 Posted: Sun Jan 11 10:15:09 1987 Date-Received: Sun, 11-Jan-87 22:42:46 EST Distribution: na Organization: Dept. of Math., Stats & C.S., Dalhousie University, Halifax, N.S., Canada Lines: 19 Keywords: append command unix ex vi Is there a way to append a range of text to a file from vi/ex (as opposed to 'w' which writes or over-writes)? Are there simple Unix commands to append files with syntax and action similar to 'cp' and 'mv'. I developed the following alii and I'm wondering if they are necessary: alias append cat !:1 >>!:2`test -d !:2 && echo /!:1` alias tack append !:1 !:2 && rm !:1 (I would accept suggestions on a better name for the latter!) Many thanks. -- John Wright ////////////////// Phone: 902-424-3805 or 902-424-6527 Post: c/o Dr Pat Lane, Biology Dept, Dalhousie U, Halifax, NS, Canada, B3H-1J4 Ean/Bitnet: lane@cs.dal.cdn Arpa: lane%cs.dal.cdb%ubc.csnet@csnet-relay.arpa Uucp:{seismo,watmath,utai,garfield}!dalcs!lane Csnet:lane%cs.dal.cdn@ubc.csnet