Fixes: f9ef6d48 ("usd/importer: specify formatting for logger to include timestamps, drop module"
Signed-off-by: Nishanth Aravamudan <email address hidden>
usd-merge: properly report back return codes on errors
As pointed out by Christian Ehrhardt, if `git tag` fails, the return
code from `usd-merge` is zero, which is incorrect and can lead to
wrapper scripts incorrectly detecting success.
Instead of
git commit-tree -m <string>
We put the commit message in a file and use
git commit-tree -F <tmpfile>
Now we are not converting the commit message to string at
all, allowing it to have non-utf-8 chars ini t.
Cleanup of 'run' and fix error when changelogs have non-utf8 output.
This wraps usage of subprocess.run with a 'run' method that has
the common defaults we use.
Also adds a 'decode_binary' method
for decoding and logging WARN if the decode fails to actually
be utf-8. Not sure if that is exactly what we want to do or not.
The changes here also make logging of the commands that are run
to output at debug level and logging failed commands and exit code.