[prog] Programming for QA folks

Akkana Peck akkana at shallowsky.com
Fri Jun 15 21:45:29 UTC 2007


Anna Baik writes:
> shell scripting - specifically the Korn shell.  I guess Perl is the
> other option.

Can I ask why those two are the only languages being considered?

I think I remember "Learning the Korn Shell" to be a decent book;
I used it a long time ago when I had a job where management mandated
that ksh was the only programming option. You'll want to be very
up on your man page skills, though, because ksh (unless it's gotten
a lot more powerful since then) can't do that much on its own, so
you'll be spending a lot of time calling awk or perl to do the
harder bits.

I didn't like "Learning Perl" at all, but that was partly because
I wasn't using it to learn programming from scratch, but as a
reference, since I already knew plenty of other languages and
just needed the Perlish way to do things. "Learning Perl" isn't
complete enough to be useful for that, but I've heard from a few
beginners who have used it and liked it, so it might be okay as
a getting-started guide.

If you decide that Python is an option, I can recommend "Python
Essential Reference" from New Riders.
 
> I'm not sure whether or to try learning Perl - I get the impression
> that although powerful it can be a bit hard to learn.  Also, I think
> (but am not sure) that it would be more likely that any future testers
> would already know shell scripting but might not know Perl - so that
> would also be a reason to write stuff in Korn shell.  On the other

I would think that people would be more likely to know either bash
or perl than to know ksh. I've only had one job ever that used ksh,
and most Linux systems don't even have it installed by default,
whereas sh/bash scripts are everywhere.

Basic Perl isn't that hard to learn, but it's a very rich language
(I'm sure you've heard that the motto is "There's more than one way
to do it") so getting to the point where you can not only write simple
code, but understand code your co-workers wrote, is a bit harder.

But it does have the advantage over sh, ksh and bash that it's a
self contained language: with shell scripts, you have to get good at
all the basic Linux commands and using pipelines (awk | sed | grep | ...)
whereas in a full-fledged language like Perl or Python, you can do
most things and don't need to use shell commands. On the other hand,
knowing lots of details about obscure shell command options can be
useful too.

> hand, I might be totally wrong and it might be *more* likely they'd
> know Perl, not less!

Perl is fairly ubiquitous, and it's also a useful resume-building
skill (as are Python and bash).

-- 
    ...Akkana
    "Beginning GIMP: From Novice to Professional": http://gimpbook.com


More information about the Programming mailing list