Path: utzoo!utgpu!water!watmath!clyde!att-cb!att-ih!gargoyle!oddjob!mimsy!chris From: chris@mimsy.UUCP (Chris Torek) Newsgroups: comp.bugs.4bsd Subject: Re: vi eats control-Ds in sourced files Message-ID: <10905@mimsy.UUCP> Date: 2 Apr 88 22:19:45 GMT References: <10817@mimsy.UUCP> <3900002@hpirs.HP.COM> Organization: U of Maryland, Dept. of Computer Science, Coll. Pk., MD 20742 Lines: 21 In article <3900002@hpirs.HP.COM> wk@hpirs.HP.COM (Wayne Krone) writes: >I have a different fix from Chris because I wanted to keep the .exrc >input the same as the interactive input (i.e., to map ctrl-D from >within vi you must precede the ctrl-D with ctrl-V so I reasoned input >from the .exrc file should also have a ctrl-V preceding the ctrl-D). >Is this line of reasoning incorrect? I would say that the reason for typing ^V^D interactively is that vi tries to emulate the Berkeley tty driver (with some notable exceptions). Since files are simpler than ttys, the file contents should be interpreted in the simplest possible manner, i.e., all the funny translations done for user input should be skipped. (After all, you got the data into the file by working through or around all those translations in the first place.) On the other hand, your fix makes `map' commands from `ex' mode work, (I would guess; I have not tried it) as long as one types ^V^D and not just ^D. Perhaps, then, both changes should be applied. -- In-Real-Life: Chris Torek, Univ of MD Comp Sci Dept (+1 301 454 7163) Domain: chris@mimsy.umd.edu Path: uunet!mimsy!chris