4 ms·
> arcane and bizarre command-line syntax It is not arcane, you just have to read docs, like for every command line tool. Different cli applications have differ
by kukx 6y ago
> arcane and bizarre command-line syntax
It is not arcane, you just have to read docs, like for every command line tool. Different cli applications have different syntaxes usually influenced by their domains, eg compare find, tcpdump, iptables, cut, docker.
- dTal 6y agoNo, it is arcane and bizarre. No other command line tool uses dd's syntax.
- hutzlibu 6y agoExample? I used dd a lot to burn images on USB. And that command is simple as expected.
- dTal 6y agoI can't provide an example of something which doesn't exist, i.e. another program with dd's syntax. I didn't say it wasn't simple. But it is very weird.
- moistbar 6y agoWhat's weird about a syntax as straightforward as 'command name' 'input file' 'output file'? How exactly would you do it differently?
- remram 6y agoIf it were `dd input output` or `dd input -o output` no one would be claiming it's unique and bizarre. However the actual syntax is `dd if=input of=output` which is unique and (arguably) bizarre.
- moistbar 6y agoUnique, yes, and I'd even go as far as to say it's somewhat out of place on a Unix-like OS, but I have an easier time remembering "infile, outfile, block/batch size" than, say, arguments for tar due to its simplicity. I wouldn't call it bizarre because it's extremely straightforward.
- JasonFruit 6y agoI think what people see as weird is `dd bs=1024 if=/dev/sr0 of=/home/jason/sr0.iso`, instead of `dd --block-size 1024 --in-file /dev/sr0 --out-file /home/jason/sr0.iso`. It's a bit non-standard, but it's really not bad.
- kukx 6y ago> "no other ..." Do you realize that anyone can make a cli tool with whatever syntax they like? :) Also, see "man xm", which uses quite similar approach. And there are probably many other examples.
- mmcgaha 6y agoI really love when I can learn a tool and use it basically forever. In the case of DD, I have been using it since the 90s, and my printed URM from April 1985 lists dd with syntax that is still relevant today. So even if it doesn't fit the normal mold, I only had to learn it once.
- dfox 6y agoBoth dd's name and its command line syntax is intentionally arcane and bizarre and originally meant as a joke ;) The tool is originally meant to do various conversions of formats of data on 8-track tapes and both its name and syntax is reference to (arguably less bizarre) syntax used by IBM's JCL to produce contents of tapes that need that kind of conversion to be usable on unix.
- kukx 6y agoDefine arcane. You can type "man dd" and acquire the required knowledge, it is not hidden. Whatever the intention was the syntax is simple and pleasant to use, at least for me ;)
- colejohnson66 6y agoIt’s not arcane in the sense of “unknown”, but arcane in the sense of “bizarre” or “why is it like this?” Almost every other Unix/Linux tool would use `--if {if}` not `if={if}`.
- vitno 6y agoThe "originally meant as a joke" belief is derived from an Eric Raymond quote in the Jargon File, not the tool makers.