Date: Tue, 8 Jul 2014 02:31:25 +0200 From: Polytropon <freebsd@edvax.de> To: Ralf Mardorf <ralf.mardorf@rocketmail.com> Cc: freebsd-questions@freebsd.org Subject: Re: [Bulk] Re: The name "grep" Message-ID: <20140708023125.f6b56faa.freebsd@edvax.de> In-Reply-To: <1404750481.19389.12.camel@archlinux> References: <20140707075443.d47ca06a.freebsd@edvax.de> <53BA4F77.60907@qeng-ho.org> <20140707104403.5a0694ff.freebsd@edvax.de> <53BA71A7.9040208@qeng-ho.org> <1404728392.19389.1.camel@archlinux> <53BA9EC0.9000201@qeng-ho.org> <20140707160528.7ecf9855.freebsd@edvax.de> <1404750481.19389.12.camel@archlinux>
next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, 07 Jul 2014 18:28:01 +0200, Ralf Mardorf wrote: > > > On Mon, 07 Jul 2014 14:21:04 +0100, Arthur Chance wrote: > > > dd [options] [ infile [ outfile ]] > > This way users by accident could mistake the infile with the outfile. > > We dislike to randomly screw up infile and outfile, so IMO it makes > sense to force if= and of= "operands". Because "man dd" says: The dd utility copies the standard input to the standard output. Those are the "files" being used when no options are provided. To override those defaults, if= and of= have to be supplied. It would be comparable to having a -i and -o option (or like many other programs do when _not_ using the defaults: -f, whereas the default is usually program-specific, e. g. tar's default is /dev/sa0, or $TAPE, if set). Additionally, the form "command infile(s) outfile" is also found in programs like cp or mv (or even ln), which do not require a specific option for defining what is input and what is output. Unlike JCL keyword parameters, we see positional parameters here, which urges us to differentiate OS/JCL from DOS/JCL at the next seizure of nostalgia. ;-) However, dd is one of the few programs that causes touble with traditional autocompleting shells, because '=' is a valid character for use within file names, whereas ' ' (space) is the standard delimiter character. % dd if=/dev/d[TAB] if=/dev/ not found % dd if=/dev/_ More intelligent shells however can deal with this. :-) -- Polytropon Magdeburg, Germany Happy FreeBSD user since 4.0 Andra moi ennepe, Mousa, ...
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20140708023125.f6b56faa.freebsd>