I also liked this: "... today might not be a good day, so let’s use it for something I have to do anyway."
The idea transfers well to coding. Maybe you're not feeling inspired today, but there's probably something mechanical that needs to happen to your project -- resolve a TODO, update the docs, triage a bug report. So do it, and even if that doesn't snap you back into the groove, at least you got that one thing done.