Anacron

Here's a Linux utility that I recently learned about: Anacron

Simliar to cron, it runs tasks on a periodic basis, but it will ensure the task runs when the computer is on.

My use case is that I want my backup repository integrity check to run once a week on my laptop, but when a cron @weekly task is going fire (midnight on Sunday) my laptop's going to be turned off. Anacron to the rescue!

So what I did is set up an anacron task to run my backup check script once a week, and then set up cron to run anacron every 10 minutes:

*/10 * * * *  /usr/sbin/anacron -s -t $HOME/.anacron/tab -S $HOME/.anacron/spool

And here's what my anacrontab looks like:

SHELL=/bin/bash
HOME=/home/nick

# period  delay  job-id  command
# # (days)  (min)
7 0 backup-check  $HOME/bin/backup.check
read more

Reliably Redirecting With HTML

When redesigning my website and re-writing my static site generator Posty, I wanted to refactor the URLs for my blog posts but not leave anyone hanging when they had an old URL bookmarked. Since my website could be hosted somewhere that I don't have control over the webserver config, I had to figure out how to do this with HTML.

read more

Visualizing Web Design Evolution Using Git

My website here, as of the time of writing this, is still based on a design I made back in 2010, and is rendered using my static site generator that I haven't touched in nearly as long. The site's served its purpose pretty well, but it's kind of a mess; It's unreadable on mobile devices, the CSS causes some weird inconsistencies, and the static site generator is no where near my current standards. So since this is a personal project I have the liberty of throwing it all in the trash and starting over (and learning new things along the way!).

read more

North Bay Area Bike Tour Log

In April of this year, I attempted to bike the Katy Trail, but I forgot how unpredictable weather could be in Missouri that time of year and got rained out. While visiting with my parents waiting for my flight back to California, I decided to do a short bike tour in the San Francisco Bay Area where at the very least I wouldn't have to deal with rain.

read more