pmset option (https://github.com/Goles/Battery/issues/7), general improvements

Hello, this is a great script.

Just fixed some things to reflect best practices, and reorganized a bit.
As a side node [tip], http://mywiki.wooledge.org/BashGuide has been a great help to me.

This is a way to check for options, it's nicer:
```shell
# this would set the option as false
option=0

# later you can set to true
option=1

# and do this...
if ((option)); then
  # do something
fi
```

Cheers!