TIL, 2017-03-31, We Have Monokai
- Delegate call to new instance of the object
Array.fillis destructive (why not just have
Array.takereturns an empty array if the array is empty.
Array.firstreturns nil if the array is empty. Reference
- I think I can use
Array.permutation. (I must have reimplemented them at some point when I could just have looked at the source.) Reference
- Breaking up longs strings to multiple lines. Reference
string = "line #1"\ "line #2"\ "line #3" p string # => "line #1line #2line #3"
- Just to clarify:
a ||= b means a = b when a == false (falsey).
Nokogiriapparently needs other things like
- To remove the ‘You have activated rake 0.9.0, but your Gemfile requires rake 0.8.7’ types of errors, you have to coerce the Gemfile version to the version that all of the gems want. Reference
- Meta TIL: To add rouge actual CSS to this freaking blog, I followed the instructions here. We have Monokai now!
- Another meta TIL: You can’t add plugins to Github pages. I’m seriously thinking about just building the page first then pushing after. But then again I won’t be able to have a blog for a few days so yeah.