Some do not use the json module directly so don't need import json.
Some needed to fallback to simplejson with no traceback if neither was installed
Fixes#1298
Some packages attempt to prompt the user for certain settings during
installation. Thus, this parameter sets the environment variable
$BATCH to 'yes', which forces package installation scripts to accept
default values for these interactive prompts. This should work for all
prompts that have a default value and aren't implemented through a
custom script (as this variable is built into the ports/package system).
FIXME: Package install should fail if it prompts and batch isn't set;
currently, the install hangs indefinitely.
TODO: Allow user to specify the answers to certain prompts.
I (github.com/mwpher) have NOT tested this with any packages besides
bsdstats. It's a small improvement, but not a complete answer to all
the complexities of package installation.