14 ms·
Please explain how the command-line is pointless. If investing time into learning the ins and outs of a complicated system does not make you clever then please
by kichimi 6y ago
Please explain how the command-line is pointless. If investing time into learning the ins and outs of a complicated system does not make you clever then please explain to me what does make someone clever?
- oefrha 6y ago> please explain to me what does make someone clever? Dismissing other people’s work as awful, pointless on the Internet. Well, at least it makes you look clever, in certain eyes.
- user-the-name 6y ago"The command line" is not pointless. The current popular implementation of a command line, is, however, pointlessly complicated and esoteric for no real gain. It could be improved massively.
- kichimi 6y agoWhich one? Please explain how it's pointless. What is esoteric about typing which program you want to run?
- user-the-name 6y agoStandard unix shells. They contain a massive amount of complexity and obfuscation that only exists because that's how it was always done and nobody dares change it any longer.
- MaxBarraclough 6y agoLike what? Please be specific or we can't have a meaningful discussion. I use Bash a fair amount and I don't consider it overly complicated as a shell. There are some rough edges in Unix, like handling spaces in directories, and I'm no fan of Bash as a scripting language, but I wouldn't say the basic model of the Unix command-line interface is overly complicated.
- PeterisP 6y agoOne aspect of standard command line experience is that the various standard unix tools have different, incompatible "interfaces" (different switches for the same things, requiring multiple different memorizations) - the experience could be "unified" to a common standard and it would be better and simpler, without removing any actual functionality, but they can't be because that would break backwards compatibility and what people remember.
- MaxBarraclough 6y agoTrue, but in my experience it's not a great concern in practice. If you have to administer various different Unices then I could see this being a real pain-point, but GNU/Linux has taken over most of the world.
- lionkor 6y ago-v for verbose -o for outfile / output -f for file / infile -q for quiet there are already many of these, and for the others that arent so common between tools. Compilers will, inevitably, need switches that, say, a code editor doesnt need. You're right that, for example, `watch` has -n for "delay", and `htop` has -d, but then again those accept different types (seconds vs some other sub-second measurement).
- user-the-name 6y agoUnless it's -V for verbose. Or -i for infile. Or no flag for infile. Or no flag for outfile. Or...
- lionkor 6y agofair, there are commandline tools by third parties that dont conform. From reading your other comments, though, I can tell that you likely don't enjoy learning complicated systems in order to leverage them for your advantage. Just like the author of the article, you complain on and on, without displaying any sort of passion for the good things this complexity brings.
- PurpleFoxy 6y agoAgreed. There are so many annoyances like how you can’t use the standard shortcuts to copy and paste or how pasting text can insert a newline and run the command. If we rebuilt the command line today it would be massively better
- toomanybeersies 6y agoInterestingly enough these are both solved problems when using iTerm on macOS. Ctrl+C sends SIGINT, while CMD+C copies text, and running commands when a newline is pasted can be disabled.
- sergeykish 6y agoðɪ ˈɪŋɡlɪʃ ɪz pˈɔɪntləs. ɪt kəntˈeɪnz ɐ mˈasɪv ɐmˈaʊnt ɒv kəmplˈɛksɪti and ˌɒbfəskˈeɪʃən ðat ˈəʊnli ɛɡzˈɪsts bɪkˈʌz ðats hˌaʊ ɪt wɒz ˈɔːlweɪz dˈʌn and nˈəʊbɒdˌi dˈeəz tʃˈeɪndʒ ɪt ˌɛni lˈɒŋɡə Shell (just like language) is a medium. We use it to communicate our ideas, not because it is great or flawless.
- michaelt 6y agoI love the command line and use it all the time. But let's be honest, the design is pretty esoteric. You want to find a file containing a particular string? For some reason the tool is called 'grep'. The name is followed by '-r' then the search term, then the directory to start the search in. And it won't be long before you start encountering tools with such intuitive names as 'sed' and 'awk' and 'crontab' The tool for finding a file by name is better - that's called 'find' - except compared to grep the arguments are swapped: The directory to search is now the first parameter, not the last. Oh, to find the *.desktop files on your system you did a find on / ? Yes, the messages like "find: ‘/proc/19917/fd’: Permission denied" are normal, you should ignore them. It's easy, simply add 2>/dev/null to the command. Before you know it, the command line infects your brain and you start saying things like "sudo and nohup are perfectly good names"
- ywei3410 6y agoTo be honest the criteria for a beginner and someone who's used a tool for a while are different. You bet that `ls`/`cd` is a great name for me - it takes 2 characters and I don't have anything similar conflicting on the PATH. For a beginner? Not so much - `change-directory` and `list-directory` would probably be better. It's the same with regular expressions `^[A-Z0-9]{0, 3}$` is perfectly readable once you're reasonably familiar with the syntax. It's also true in other fields such as mathematics or music - the notation is quite good once you're proficient in it.
- kellyjprice 6y agoOh oh. I read the HN article about why it's called `grep`. g - global re - regex p - print https://en.wikipedia.org/wiki/Grep#:~:text=Its%20name%20comes%20from%20the,others%20such%20as%20OS%2D9 https://en.wikipedia.org/wiki/Grep#:~:text=Its%20name%20come....
- viceroyalbean 6y agoWhat do you mean by "current popular implementation of a command line"? The shell, common tools (e.g ls, cat, grep), command line interfaces for other programs?
- user-the-name 6y agoThe vaguely-standard Unix shells, yes.
- childintime 6y agoyes, that should have been obvious. if you ever used them, you know they do not scale beyond the basics. just try to imagine the language as the OS. if it were good enough, there would be no need to have different languages, and one would not have the horrible level of fragmentation and harmful shared state that characterizes today's dev environment. most people have become blind to this fact. then there is the problem of selection bias: the majority of developers in this business have tolerated an insane level of abuse. most are proud of their abilities, even if they can be characterized as "they know how to wade through layers upon layers of shit". it is often hard to have a discussion about this, because they take this as personal criticism. the situation we live can be described as a paradox: the Unix culture is at the same time both a pinnacle of OS design (from days gone by) and a steaming pile of shit with so many bad practices abound it is no use highlighting one (with the command-line just being a visible part). just pointing out the obvious.
- 0-_-0 6y agoNot using a complicated system when you don't have to.
- kichimi 6y agoNode.js is a command line program, intended for writing server side applications on headless servers.
- 0-_-0 6y agoThe command line is a layer of abstraction that could be made unnecessary for programming. You could program in Turbo Pascal without a command line in the 90s
- jorams 6y agoWhat would be the layer below it? It's certainly not GUIs, which are a significantly more complex layer of abstraction.
- 0-_-0 6y agoIt's definitely GUIs, which is much easier to use for beginners (we're talking about beginners here, not people who have been using command lines exclusively for the last 20 years)
- kichimi 6y agoIn one statement you just revealed your age and experience level. The general trend in programming has been moving TOWARDS command line interfaces, not away from it. Mac OS didn't even have a built in command line until 2001. Microsoft Windows in the last few years has had its command line functionality enhanced, to the point that the GUI only Server versions of Windows have been stripped back, and now there are CLI only versions of Windows Server. You can do more now in a command line than ever before, you can do more now in a command line than you could in 2001. "Everything should have a GUI alternative" has been tried and it has failed. Almost all computer efforts through the 1990s were focused on making everything GUI only.