Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!uunet!ora!jerry From: jerry@ora.com (Jerry Peek) Newsgroups: comp.unix.questions Subject: Re: ftp Summary: some versions have "macdef" in .netrc file Message-ID: <1991Jan16.125358.14231@ora.com> Date: 16 Jan 91 12:53:58 GMT References: Sender: jerry@ora.com (Jerry Peek) Distribution: na Organization: O'Reilly and Associates Inc., Cambridge, MA Lines: 29 In article garath@ais.org (Belgarath) writes: > 1) Is there a way to set up a file so when I ftp, I am automatically > set to binary and bell mode? Some versions let you put startup setups in your .netrc file. Here's a .netrc file under SunOS 4.1, for example: machine kumquat.xyz.edu login freddy password xxxxxxx macdef init cd "freddy 191" account yyyyyy binary machine uunet.uu.net login anonymous password freddy@kumquat.xyz.edu The "macdef init" line means that the commands after it, up to the empty line, will be run after the connection to the "kumquat.xyz.edu" machine is completed. The netrc(5) man page has details (on SunOS 4.1, at least). > 2) Will getting a text file with binary mode on cause problems when > trying to read it? That depends on the systems you're transferring the files between. I use ftp all the time to transfer both text and executable files between two identical Suns... no problem, because the files are stored the same way on both systems. --Jerry Peek, jerry@ora.com