I'd like to access $user from the commandline to see what properties are available on it. I could sdpm($user)
in my code and go inspect it in my browser, but isn't there a way I can inspect it right from my terminal?
It looks like drush php
could be helpful here, according to http://blog.damiankloip.net/2015/drush-php, but when I use it and do dump -a $user
I get 'Unknown variable: $user'. That's probably obvious, so I probably need to load $user into the repl first (I'm guessing)... but how? That blog post shows how to load objects in D8, but how would I do this in D7 for $user???