Tuesday, 10 July 2012

Why the GUI Will Never Kill the Sacred Command Line

By Caleb Garling

He called himself “MSP,” and he appeared out of nowhere, launching a one-man flame war against a sacred cow of hardcore computing: the command line.

The venue was TuxRadar, a news and reviews site that shines a spotlight on the Linux operating system and other open source software. The site had just published a piece in praise of the command line — where you interact with a computer by passing it line after line of text, rather than using a graphical user interface, or GUI. “The command line isn’t a crusty, old-fashioned way to interact with a computer, made obsolete by GUIs, but rather a fantastically flexible and powerful way to perform tasks,” the site said.

Then MSP appeared with his flame thrower. “There seem to be a number of obvious errors in the introduction to this article,” he wrote. “The command line is a crusty, old-fashioned way to interact with a computer, made obsolete by GUIs, but a small hardcore of people who refuse to move on still use it.”

As he likely expected, the Linux-happy commenters at TuxRadar didn’t take kindly to his “corrections.” Dozens vehemently defended the command line, insisting it still has a very important place in the world of computing. And they’re right. Though the average computer user has no need for a command line, it’s still an essential tool for developers and system adminstrators who require access to guts of our machines — and it’s not going away anytime soon.

“People drive cars with steering wheels and gas pedals. Does that mean you don’t need wrenches?” says Rob Pike, who was part of the team at Bell Labs that developed the UNIX operating system and now works at Google, where he oversaw the creation of the Go programming language.

Back in ’70s and early ’80s, if you used a computer, you used a command line. DOS — the disk operating system that runs atop IBM PCs — used a command line interface, and that’s what UNIX used too. But then came the Apple Macintosh and Microsoft Windows, and by the mid-’90s, most of us had moved to GUIs. The GUI is more effective when you’re navigating an operating system you’re not exactly familiar with, but also when you’re typing large amounts of text. Your word processor, for instance, uses a WYSIWYG, or what-you-see-is-what-you-get graphical interface.

“Try creating a complex document in a mark-up language using a text editor,” writes one commenter on TuxRadar. “It can be done, but generally using a graphical WYSIWYG interface is a far faster and accurate approach.”

GUIs have even reinvented the world of software development, beginning with tools like Visual Basic, before extending coding tasks to the average joe with new-age tools such as Scratch and Google’s App Inventor.

But among hardcore computer types — i.e., the audience reading TuxRadar — the command line persists. If you’re a developer or a sysadmin, there are times when it makes more sense to use the command line interface, or “shell,” built into operating systems like Linux and UNIX. “It depends on what you’re doing,” Pike tells Wired. “All computing, at some level, is abstraction and yet deep down beneath there are hardware instructions doing the job. It depends on the level you’re working at.”

In some cases, command line interfaces provide access to lower levels of a machine’s software and hardware. And they’re often easier to manipulate with “scripts,” mini text programs that automate processes for system adminstrators and others.

“Anyone insisting the command line is a relic of a by-gone time is hopelessly deluded,” argues another commenter in the Tuxradar debate. “I have a very nice [desktop] set up at home, with lots of graphical applications, but I just find it quicker to write scripts and use the shell than to hunt through menus to find what I want.”

But in other cases, geeks like command lines just because you have to know what you’re doing to use it. You have to know the commands. You can’t hunt and peck like you do with a GUI.

Pike calls the kerfuffle sparked by MSP a “sterile debate.” But MSP insists that the command line should disappear. The problem, he writes, is that GUIs just aren’t as effective as they should be. “When people using a particular system say ‘the command line is better because it can do things you can’t do in the GUI’ they are not talking about the strengths of the command line interface, but about the shortcomings in the GUI,” he says.

OK. Fine. But until the GUI evolves again, the command is here to stay.

No comments:

Post a Comment

RPM Tech Widget

Search Box

Blog Archive