Question:
CLI (Command line interface) and GUI (Graphics user interface)?
ANSWERS
2011-05-07 05:56:42 UTC
what are some actual examples of what kind of tasks where using the CLI is better than using the GUI.
Three answers:
JoelKatz
2011-05-07 06:04:42 UTC
You have a directory with 50 other directories in it. You want to compress the files in each sub-directory into their own ZIP files named with the name of the subdirectory (plus .zip). That will take me about 2 minutes with a CLI. How long would that take you with a GUI?



You have 50 Linux boxes all set up to let you SSH in by key. You have the names of the machines in a file, one name per line. You want to SSH into each box, extract its distribution release number, and produce a list of all machines running Fedora 12 or earlier. Again, that would take me about 2 minutes with a CLI. How long what that take you with a GUI?



You have a bunch of HTML files that might contain extra spaces at the end of each line. You want to search all the HTML files for lines that end in a space or tab and remove them. Again, 2 minutes with a CLI. How long with a GUI?



You have 30 TAR archives that might have the wrong permissions on some files or directories. You want all files to have normal file permissions and all directories to have normal directory permissions. In about 2 minutes, I can unpack, fix permissions, and repack all the archives. How long would that take with a GUI?



GUIs are good for reading mail, writing documents, browsing the web, and so on. But when you need to do something with a computer that nobody ever specifically designed something to do, GUIs are nearly useless.
Mechachomp
2011-05-07 12:59:02 UTC
sending a ping to a website, various diagnostic checks etc. and to confuse people who don't understand it, it's great for that.
Frank
2011-05-07 13:06:35 UTC
Tasks that have to be scripted or otherwise automated.


This content was originally posted on Y! Answers, a Q&A website that shut down in 2021.
Loading...