pkgin: use module.run_command to run stuff

This also fixes an issue where some console output for packages I was
installing was creating invalid JSON because it contained single-quotes.
pkgin: add stdout to error message when shell commands fail