-
Lua Script to Start, Unhide, and/or Auto-Arrange
I’m starting to try using HammerSpoon, which is driven by Lua, for automatically arranging my applications depending on application scenarios. I have 3 screens, including a MacBook Pro at Retina native resolution and a Seiki 4K display. I grabbed the names of the monitors from Display Menu‘s menu bar menu. I initially made the mistake…
-
Hammerspoon Lua Script – Split Windows 3×3
I’ve been using using Spectacle pretty heavily, but with a larger screen, I always felt like quadrants were a poor use of real estate, so I began to crack open the source code, which was pretty challenging to navigate because it’s a mix of JavaScript and Objective-C reminiscent of user interface programming from ages past.…
-
Pundit: NoMethodError (undefined method `verify_authorized’ for [WhateversController])
![Pundit: NoMethodError (undefined method `verify_authorized’ for [WhateversController])](https://thomaspowell.com/wp-content/uploads/2015/07/8729962194_b4cc81b2ee_z.jpg)
Sometimes, having done things several times before can make you miss the OBVIOUS. After adding after_action :verify_authorized to my ApplicationController to verify that Pundit was being used for authorization, I got the following error in rspec: 2) Jobs GET /jobs works! (now write some real specs) Failure/Error: get jobs_path NoMethodError: undefined method `verify_authorized’ for #…