This is the beginning of a series of articles where I develop a variation
on the classic lunar-lander game themed around the planet Mars.
To do this in three dimensions can be rather complicated, so in the spirit
of the original arcade game (that I became rather obsessed with, I should
admit), I'm going to tackle the simplified two-dimensional problem. more>>
The new second edition of Dave Taylor and Brandon Perry's classic Wicked Cool Shell
Scripts, published by No Starch Press, features a smorgasbord of favorite scripts and 23 brand-new ones.
Subtitled 101 Scripts for Linux, OS X, and UNIX Systems, Taylor
and Perry's guide
features a collection of useful, customizable and fun shell scripts more>>
You'll recall that in my last
article I shared a long, complex explanation for why
spam email catches my attention and intrigues me, perhaps more than it should.
Part of it is that I've been involved in email forever—I even wrote one of
the most popular old-school email programs back in the day. more>>
A project I'm involved with has made me think about how there are
always many solution paths for any given problem in the Linux universe. For
this other project, I wanted to cobble together a version of
grep that let
me specify proper regular expressions without having to worry about the
-E flag and get a context for the matches too.
In my last article, "Fancy
Tricks for Changing Numberic Base", I explored the surprising ability of the Linux shell to convert
numeric bases on the fly, including this sweet little snippet that converts
FF hexadecimal into decimal notation:
$ echo $(( 0xFF ))
In this article, I want to cover a more fundamental
aspect of shell scripting: working with command arguments.
I suspect that most shell scripts go through an evolution with their
command flags, a more>>
I must admit that I don't really follow basketball. But, I do like to engage
with folks at work, and every spring I've always felt a little left out
when my work colleagues fill out their NCAA March Madness basketball
brackets. If your office is like mine, it seems everyone gets
very excited to build their brackets and follow the basketball games and
play in an office pool.
For this article, I thought it would be beneficial to go back to some basics of
shell scripting and look at how functions work. Most script writers
probably eschew using functions because it's a bit antithetical to how
scripts tend to evolve, as a sequence of commands on the command line that
are captured in a file.
A reader wrote a letter to me (oh happy day!), and although I'm still
not entirely sure what she's trying to accomplish, it's an interesting
puzzle to try to tackle anyway. Here's what she asked:
In my last article, we began an exploration of date math by validating a given date
specified by the user, then explored how GNU date offers some slick math
capabilities, but has some inherent limitations, the most notable of which is
that it isn't on 100% of all Linux and UNIX systems.
Let's start with some homework. Go to Google (or Bing) and search
for "privacy is dead, get over it". I first heard this from Bill
Joy, cofounder of Sun Microsystems, but it's attributed to a number of
tech folk, and there's an element of truth to it. Put something on-line
and it's in the wild, however much you'd prefer to keep it under