How to dim (and un-dim) display in automator For those that are interested in the final script you can get it here

original question



I am trying to make a alarmclock script to wake me up. but I can't figure out how to change the screen brightness in automator.

I found a way to control brightness with the commandline. but I can't get it to work in automator


  I'm the original author of the code listed in this hint. I originally wrote it for two reasons: first, to adjust brightness automatically by location on my iBook G4, which had no ambient light sensor, and second, so I could have my laptop turn on the backlight when a long operation finished, providing a quiet form of notification I could use while at a seminar.
  http://sabi.net/nriley/software/brightness.zip is 4-way universal, 10.5+. I compiled it under 10.6 with:...
  (see full forum page )


but when I try to use 

brightness 0


or

brightness 1


I get an error in automator.


am I using the run shell script wrong?
could this be done easier in apple script?
is there a alltogether easyer way to do this?

I need to turn the brightness up and down in automator how is this done?

Update  I tried the apple script method you mentioned and it....showed the overlay that shows when the key is pressed but did nothing else
Where did you install the “brightness” command? Even if you've set up your PATH in the shell rc scripts, it may not take effect for these commands because Automator isn't run from a shell. (You can set environment for all programs including GUI using ~/.MacOSX/environment.plist, but I wouldn't recommend fiddling with PATH just for this.)

I suggest changing your Automator workflow to use the full path to where it's installed, e.g.

/usr/local/bin/brightness 1