This is something I started a while back: using code authored by my then-lover, John who I eventually married. It’s still in a state of experimentation because it’s highly limiting. I’m thinking about inserting prose. what’s missing is the wonderful color that’s generated when John works on transparent screens, and this is how it started. A friend of his at work sent me a photo of John standing in front of a wall of colorful code. I extracted words from the code and sent him a poem. Anyway, Sara, your lesson reminded me of the folder I had sitting on my hard drive, and how I wanted to explore language and expression and artistry with code. I’m posting two things I wrote today. (It turns out I can’t post highlighted/grayed out text. I’m going back to bold the text that’s displayed.)


Mother died today. She keeps dying. I resurrect her. 




# Script runs in cron to check for heartbeat syslog messages from Solarwinds

# Send alarm if no alerts in 15 mins



use Time::Piece;

use Time::Seconds;


#if (-e “/scripts/HBFAIL”) {




open (LOG, “>>/var/log/heartbeat”) or die;


#load last messages from syslog and check messages.0 for file rollover

my @msgs = `grep “nc-solar1 %OrionAlertEngine: Heartbeat” /var/log/messages`;

if ($#msgs < 1) {

@msgs = `grep “nc-solar1 %OrionAlertEngine: Heartbeat” /var/log/messages.0`;


my $last = pop(@msgs);

chomp $last;

#Sep 19 15:30:46 nc-solar Sep 19 2007 03:31:39 nc-solar %OrionAlertEngine: Heartbeat

#L: Oct  4 21:21:59 nc-solar Oct 04 2007 09:22:42 nc-solar %OrionAlertEngine: Heartbeat

#print “L: $lastn”;

if ($last =~ /^(S+s+d+s+S+)/) {

$sys = $1;


else {

$sys = “Jan 01 01:01:01”;


#print “Sys: $sysn”;



my $timenow = localtime(time);

my $yr = $timenow->year;

$sys = $sys . ” ” . $yr;

#print “Sys: $sysn”;

my $lastmsg = Time::Piece->strptime($sys, “%b %d %H:%M:%S %Y”);

#adjust lastmsg for timezone


#print “heren”;

$lastmsg = $lastmsg – $timenow->tzoffset;


#print “here2n”;

my $secs = $timenow – $lastmsg;

#print “SEC: $secsn”;


#print $timenow->epoch;

#print “n”;

#print $lastmsg->epoch;

#print “n”;


#print $timenow->strftime().”n”;

#print $timenow->tzoffset.”n”;

#print “$timenow, $lastmsgn”;

#print “Secs: $secsn”;


print LOG “############################################n”;

print LOG “Syslog: $lastn”;

print LOG “NOW: $timenow, SYS: $lastmsgn”;

print LOG “Seconds: $secsn”;


if ($secs > 900) {


system(‘echo “HEARTBEAT FAILED” | mail -s “HEARTBEAT FAILED”’);

system(touch /scripts/HBFAIL’);












  1. sara lippmann

    OMG April I love this, and I love (envy!) that this was just sitting on your computer, ready to go! It’s devastating and honest, and what’s remarkable is how the emotion penetrates through the restraint and filter of another language. Code. I would love to see you submit this asap — in terms of suggestions: I wonder if there is a workaround the explanation of the first sentences. Perhaps instead of heartbeat, which is already in the story in such a resonant way, the title is “Mother died today” or “death in code” or something — it’s your story! so you’ll come up with it! — but if you can somehow get it into the title, then I think the code form speaks for itself and we wouldn’t need any other preface. Thank you for this powerful, evocative piece.

    • April Bradley

      Thank you so much for the suggestion, Sara. I’m terrible at titles typically, and this is an instance when the title can do so much work for the piece. Really, I wanted to post something and felt like I had dallied long enough. The code is sitting in a folder on my hard drive, not any of my fiddling around with it (I keep forgetting it’s there). I read through John’s code files a few hours ago after reading your lesson and thinking about my mother’s moment of death. Thanks for such an incredible workshop, Sara.

  2. Jenn Rossmann

    April, I love the way you’re using code here. I love the rhythms and loops, the ifs and thens — what you’ve done here feels tremendously poetic and interesting to me. Syntax like “lastmsg,” “echo,” and “send alarm if no alerts…” has an undeniable poignancy. (I write a lot of code for my dayjob, and prior to this prompt it had never occurred to me to see it this way. Even reading the prompt, I was like, “Well, okay, Sara, I *guess* that could work,” and you’ve shown me YES IT CAN because this is lovely.) I agree with Sara that the title might be more explicit than it needs to be. Thanks for sharing this. I dig it.

  3. April Bradley

    Jenn, I’m thrilled I’ve inspired you to look at your code differently. I hope you can do something creative/different with yours, if you want. Thank you so much for you lovely comment. I really didn’t know how this was going to go. Now I want to figure out where to send it.

  4. Todd Clay Stuart

    April, I LOVE that you used perl code in this fashion, elevating a common perl heartbeat routine to poetical heights! I always thought it bizarre that the epoch on Unix machines refers to January 1, 1970 on Unix machines. I guess that was about the birth of Unix so they called it the epoch. It’s such a great word. Die. Heartbeat. Epoch. Touch. Here. Now. Such poetical diction here. Nice work!

  5. Kristen Ploetz

    WOW! I would love to see the full version of this graphically because it would be ASTOUNDING. I love pieces like this SO MUCH. It does not take a code writer to understand what is happening here, which is the essential beauty of it. I think the only thing I would want more of somehow–not even that much, maybe a few more lines of code–are some really intense body words as verb or noun. It’s so creative.

  6. Meg Tuite

    April! This is phenomenal! I love those first three sentences that move into the code. She is revived again and again. It’s eerie and it penetrates!
    Absolutely inimitable! LOVE LOVE LOVE! send it out, please!

Submit a Comment

Pin It on Pinterest