THIS for a 2012 Macbook Air running HA directly installed. I was pulling my hair out trying to do this via the SSH add-on, since I saw the /sys/class/backlight directory. However, when I tried to execute via SSH, the console threw an ownership error. Tried to CHOWN - no luck even though I’m root (whut!) - further research indicated that it might be that the SSH add-on is locked to it’s own container environment (more here) -
After reading about this, I simply went over to my Air and typed in the command
echo 0 | tee /sys/class/backlight/*/brightness
WIN. Thanks Dan for your concise but accurate post. There was no grub.cfg file on my system that I could find - this did the trick for me. Screen off, happy guy here. Thanks @dglwilkins