ChristoWolf / vagrant-story-randomizer

A tool for randomizing a binary of the PS1 game "Vagrant Story"
GNU General Public License v3.0
4 stars 0 forks source link

Improve error output of `psximager.Execute` #26

Closed ChristoWolf closed 1 year ago

ChristoWolf commented 1 year ago

Namely, only the output of the cmd command (e.g. error executing psxinject: exit status 1) is decorated, instead of the whole stderr of the actual psxinject command. For this, cmd.Stdout and cmd.Stderr should be readable instead just writing to their os equivalent readers. Can be reproduced using ExampleExecute in psxinject_test.go.

I first about doing all of this using a logger (preferably the one in the experimental slog package) or making this configurable, but then decided against that, because the whole psximager package is internal anyways.