4 ms·
I'm not sure if you're joking or not, but this is entirely true. I'm sat here watching a data mining job. It's wasted time, largely brought on because the job d
by Lewisham 15y ago
I'm not sure if you're joking or not, but this is entirely true. I'm sat here watching a data mining job. It's wasted time, largely brought on because the job doesn't have unit tests, so I have no confidence it'll actually complete correctly, so I need to watch the log and see what its doing.
This not a good use of my time, and I hate seeing that console, and I feel bad for being on HN when I could be productive.
- paulbaumgart 15y ago./data_mining_job && growlnotify -m "Success!" || growlnotify -m "Failure :-(" (season with while, read and grep to taste)
- Lewisham 15y agoHah, if only it was so simple! The integrity of the job is the problem. It's been coded to failover problems (as the original data integrity its mining from isn't good), so it will happily do something stupid for hours. That's why I have to watch it, and make sure its not doing something stupid. Unit tests would ensure stupidity was not a possibility, and regressions could be tracked. Too late for that, unfortunately. So I watch.
- paulbaumgart 15y agoWhoops. Too late to edit, but a correction: growlnotify -m "Success! " (the space tells bash to treat the exclamation point as text)
- rcfox 15y agoOr just use \!
- deleted 15y ago[deleted]
- paulbaumgart 15y agoGood call. Though for multi-word messages, you'd have to do something like: growlnotify -m "$(echo Great\! Success\!)"
- qntm 15y agoFor arbitrary messages: sub escape { my $arg = shift; $arg =~ s/([^a-zA-Z0-9_])/\\$1/g; return $arg; }