(MORE is less, but, well, less)
"more" is the original command,
less came later. (A quick google says that MORE was first included in MS-DOS 2.0, released in 1983, the same year less was developed.)
(MORE is less, but, well, less)
"more" is the original command, less came later. (A quick google says that MORE was first included in MS-DOS 2.0, released in 1983, the same year less was developed.)
I'm pretty sure pg predates more.
ls, mv, cp, cd, du are nice and short for commands you will be typing a lot.
You can get all up your high horse on how correct they are in DOS or not, they are not as short.
On Data Generals AOS/VS, only the beginning unique characters were require so f (filestatus) and that's even shorter than ls.
Don't forget "speed", the teco work-alike was was even *more* restricted and more cryptic. I actually managed to do useful things with it.
I'm pretty sure pg predates more.
Sure, but it's neither more nor less.
OK, so why use a new command like 'ls' instead of 'dir' which is world known for a Directory listing?
Or, using 'cp' instead of the universally understood 'copy' as in DOS ? And numerous more changes.
Wait until you discover that there is no
ren. Or that you can't quit
vi.
OK, so why use a new command like 'ls' instead of 'dir' which is world known for a Directory listing?
Or, using 'cp' instead of the universally understood 'copy' as in DOS ? And numerous more changes.
Wait until you discover that there is no ren. Or that you can't quit vi.
I don't understand why anyone struggles with vi, It's those other editors that use obtuse and non-intuitive commands.
I will bow to the wisdom of those who are programmers and systems administrators and use this stuff everyday. But GUIs took over from CLIs in most places. How can this be when the CLI is so superior? Well it is because all of those short commands and shortcuts have to be memorized to be efficient. And if you don't do it everyday you forget. And then you are searching help and FAQs and all that to get the job done and it is far less efficient.
The doctors and lawyers and yes the electrical engineers who use these computers as a tool to do their real job value the crutch that is a GUI. And snicker at the snobbery of those who recommend the CLI for everyone.
That is not to say that there aren't uses for everyone in the CLI. But it is hard to put to work on an occasional basis. The person who does a good GUI version of grep will be very popular. All the versions I have seen quickly lose generality in order to be "easier to use". Which strikes me as bad UI design rather than too much complexity, but then I haven't been able to come up with that magic version either.
N.B. you can use dir instead of ls if it's your preferred muscle memory:
alias dir=ls
Typing this in will only temporarily make it an alias (until you close the shell or logout). Add it to your login scripts (either .bashrc or .profile depending on your setup; think of them like user-specific AUTOEXEC.BAT) and it will become a default.
Make your computer your own and tell everyone else to stuff it!
You should have seen my old windows installs. It's a shame bb4win no longer works properly (Win10).
OK, so why use a new command like 'ls' instead of 'dir' which is world known for a Directory listing?
Or, using 'cp' instead of the universally understood 'copy' as in DOS ? And numerous more changes.
Just to answer these, `ls` is short for `list`, while you say `dir` might be a more correct name for this command, it's actually not, as `dir` implies directories, not files.
`cp` is just `copy`, but shorter. When you type commands for a living, removing those extra characters for very very common commands is a real time saver, such as `rm` for remove.
The shell is so powerful, proper input/output redirection, pipes, fifos, remote low latency low bandwidth consoles via ssh, etc... I even write software in `vim`, a command line editor with full syntax highlighting that I can use from anywhere in the world remotely on a slow dial-up connection. I even write and cross compile applications for Windows on Linux in a Linux shell. Really, the command line is king, and it's why the tutorials all start there.
After cp came scp and I don't even know what Microsoft forces their users to type for that one.. securecopy?
But that would break the 8 char limit for filenames so they would prolly wanna chuck in some underscore luvliness. sec_copy? Perfect.
Welcome to the Linux community, GlennSprigg.
It's nice to hear a new user ask 'why is it done this way?' instead of the ranty 'Linux is dumb. It didn't do what I expected. Giving up.'
I will bow to the wisdom of those who are programmers and systems administrators and use this stuff everyday. But GUIs took over from CLIs in most places. How can this be when the CLI is so superior? Well it is because all of those short commands and shortcuts have to be memorized to be efficient. And if you don't do it everyday you forget. And then you are searching help and FAQs and all that to get the job done and it is far less efficient.
The doctors and lawyers and yes the electrical engineers who use these computers as a tool to do their real job value the crutch that is a GUI. And snicker at the snobbery of those who recommend the CLI for everyone.
That is not to say that there aren't uses for everyone in the CLI. But it is hard to put to work on an occasional basis. The person who does a good GUI version of grep will be very popular. All the versions I have seen quickly lose generality in order to be "easier to use". Which strikes me as bad UI design rather than too much complexity, but then I haven't been able to come up with that magic version either.
The thing is.. as time goes on, the GUI changes and always changes when the user least needs it to. As gnif pointed out, the terminal is always there and works as expected and nobody would be so silly to mess around by daring to change it.
And snicker at the snobbery of those who recommend the CLI for everyone.
I don't think I've ever seen someone snicker because CLI was used instead of the GUI but I have seen the CLI users snicker at the GUI users. It's unprofessional and the few that do give the impression that it's a general user trait, reality though there are always a few aholes in every group.
That is not to say that there aren't uses for everyone in the CLI. But it is hard to put to work on an occasional basis.
??
I feel a lot of the CLI is better just comes down to it being easier to instruct on and it's also often more consistent. Run this command rather than:
what GUI are you using, what version, do you have a icon that looks like a bird, yea, click the little arrow, what just came up etc... WTF did you just click on??? Ummmm, was OK the ONLY button.... No I did not tell you to click on that.... WTF are you talking about, you click the button not me, next time 'Warning' appears don't click the Freakin OK button unless I tell you too...
CLI and GUI have different use cases.
While the CLI can do anything, you also must remember everything and read manuals
.
A GUI often displays all available program paths, with it you can choose if what you want to do matches with what you read on the screen.
You can explore a GUI. You can read a man. Not the other way.
I don't understand why anyone struggles with vi, It's those other editors that use obtuse and non-intuitive commands.
I believe it is because not all computer users have learned "proper" touch typing. (I myself took a whole year of typing class.)
vim is designed for touch typists and the others are not.
vim is also associative in that you can figure out commands on your own -- as if you are literally creating them on the spot -- once you understand the workflow. ce2/ anyone?
The person who does a good GUI version of grep will be very popular.
grep is intended for processing text and subsequently doing stuff with that text --
within the context that grep is being used in (AKA a shell). Why would I want a GUI to run privileged commands and how would I tell it take action on the results?
If Google Chrome wants to hog my MacBook Pro I will just pop on over to a shell and issue:
ps aux | grep Chrome | perl -nle'/(\d+)/;print$1' | xargs -n1 kill -9I did not take the time to learn to be lawyer or a doctor but if I wanted to do as they did .... well ... let's keep things in proper perspective here please. GUIs are fine but the command line is never going to go away, no matter how many times it is "replaced."
The person who does a good GUI version of grep will be very popular.
grep is intended for processing text and subsequently doing stuff with that text -- within the context that grep is being used in (AKA a shell). Why would I want a GUI to run privileged commands and how would I tell it take action on the results?
If Google Chrome wants to hog my MacBook Pro I will just pop on over to a shell and issue:
ps aux | grep Chrome | perl -nle'/(\d+)/;print$1' | xargs -n1 kill -9
I did not take the time to learn to be lawyer or a doctor but if I wanted to do as they did .... well ... let's keep things in proper perspective here please. GUIs are fine but the command line is never going to go away, no matter how many times it is "replaced."
Luke and Derek recently butted heads about grep..
I can't take the video titles seriously enough to watch. The first one says I am George Castanza and shallow women are laughing at me.
The second says I will be strong and bald if I stop using
cat and
grep and only use
awk.
I hope my point was not overlooked however. My point was that when you use something like
grep you are generally not even in the realm of being in a GUI in the first place ... other than to draw the window for your shell.
This is not about "my way is better than your way" ... there are always ways to reduce the amount of characters you type (a sport known as
golfing amongst hardcore hobbyist) ... the point is that the "UNIX shell way" allows you express yourself in a way that makes sense to you, or more importantly, your organization.
The person who does a good GUI version of grep will be very popular.
grep is intended for processing text and subsequently doing stuff with that text -- within the context that grep is being used in (AKA a shell). Why would I want a GUI to run privileged commands and how would I tell it take action on the results?
If Google Chrome wants to hog my MacBook Pro I will just pop on over to a shell and issue:
ps aux | grep Chrome | perl -nle'/(\d+)/;print$1' | xargs -n1 kill -9
I did not take the time to learn to be lawyer or a doctor but if I wanted to do as they did .... well ... let's keep things in proper perspective here please. GUIs are fine but the command line is never going to go away, no matter how many times it is "replaced."
Try...
pgrep Chrome
Works on both Mac and Linux.
kill doesn't need the -n1 on xargs.
Not to mention pkill, but I like to check the results first e.g. "pgrep Chrome | xargs ps"
You posted as I was editing my message to include pkill and explain it's maybe a little tooo dangerous
$ kill_all_humans
Affirmative - I poked one, it was dead.
The thing is.. as time goes on, the GUI changes and always changes when the user least needs it to. As gnif pointed out, the terminal is always there and works as expected and nobody would be so silly to mess around by daring to change it.
Except for GNU and their
ls printing "" around filenames which contain spaces
And then of course people flood their mailing list calling them the worst names and they go like "look, we did nothing wrong, there was a beta release, you could have tested it and reported your concerns earlier"
The thing is.. as time goes on, the GUI changes and always changes when the user least needs it to. As gnif pointed out, the terminal is always there and works as expected and nobody would be so silly to mess around by daring to change it.
Except for GNU and their ls printing "" around filenames which contain spaces
And then of course people flood their mailing list calling them the worst names and they go like "look, we did nothing wrong, there was a beta release, you could have tested it and reported your concerns earlier"
Release early and release often. For every one that bitches about what it doesn't do for them there are 9 more that are very happy they got in at the ground floor.