SIGNIFICANT BITS

June 2007

by Sean N. Henderson

I'm a command-line warrior. I used to try and deny this, but after writing a bunch of batch files this month at my job, I realize it's easier for me to write these than to hunt around the desktop or app, hoping some feature is present or implemented in a way my brain could comprehend.

So why persist in the art of the command-line in this day-and-age of hi-res desktop graphics? Maybe it's because I've got a modest background in programming. Maybe I listen to too much Man or Astroman? (http://www.astroman.com) Maybe I just like being labeled 'techie' because I still write DOS batch files.

@ECHO OFF IF NOT "%geek%"=="cool" ECHO Do not care...

For me, anything I can type, I can program, and hence repeat or schedule. Less so movements across an always-changing GUI environment such as MS Windows or GUI applications such as MS Office. (Or any office suite, for that matter.) e.g., MS Excel stopped recording macros referentially (by default) after version 5.0; this was a real productivity killer for me.

Batch Files and Scripting

One program I wrote this month at work was a DOS batch file (*.bat) that looked at a remote directory using FTP, listed some file sizes for verification, and then sent me an e-mail using 'blat.exe'. (http://www.blat.net) I then scheduled this program to run at 2 a.m. every weekday so that I could have the information handy in my e-mail for record-keeping. I also used some ports of some UNIX/Linux utilities to archive some Cold Fusion files periodically using 'zip.exe', since 'zipfldr.dll' in NT/XP doesn't support command-line usage and isn't otherwise script-able.

Start with the CLI

There's some thought, regarding teaching computing to adult beginners, that the command-line interface (CLI) may be easier to learn than the GUI. (http://www.osnews.com/story.php/6282/The-Command-Line--The-Best-Newbie-Interface/) Then, there's the operating-system aspect, and whether being good at the command-line predisposes one to certain operating systems. For us command-liners, UNIX/Linux is the tool of choice.

Using CLI applications

Say you just signed up for SDF (http://sdf.lonestar.org) and thought "now what?" Here's a list of some basics you can do on SDF or many UNIX/Linux systems:

Check your email using 'pine'. View your to-do list using 'todo'. Check yours or others' calendar using 'pal'. Edit your website using any number of text-editors. (e.g., 'vi', 'emacs', and 'pico'). Ditto for your gophersite. (What?! You don't have a Gopher page?) View an MS Word attachment someone sent using 'antiword'. Visit a website using 'lynx'. Archive some files using 'gzip' or 'tar'. Install various Web 2.0 applications. (If on SDF and signed up for MOTD, simply type 'motd -i wordpress' to have your own ad-free Wordpress blog. Same for Drupal and Coppermine.) Find out what everyone's supposed to be working on by typing 'grep "." /home/*/.plan'. Check your employee's, John Doe, project status by typing 'more /home/jdoe/.project'. On SDF and other systems, you can check the user forums on that system by typing 'bboard'. Or join a system chat using 'com'.

Next month I'll list some MS-DOS-based CLI applications. And yes, Puerto Rico was wonderful.



DacsGear!
Mugs and more, visit CafePress to order
 
 
© Danbury Area Computer Society, Inc. All Rights Reserved.
Web Site Terms & Conditions of Use