Add history support in rbt attach, and enhance JSON output.
Review Request #12164 — Created March 17, 2022 and submitted — Latest diff uploaded
This provides a couple of much-needed improvements to
It now supports
--attachment-history-id=, which allows for specifying
the ID of a file attachment history object that should own the file
attachment. This enables callers to replace file attachments, if they
know the ID, and to set up diffing.
That's perhaps more useful for automation, so to help with that, the
JSON output has been enhanced to provide a lot more information about
the resulting attachment. This includes:
- File attachment ID
- File attachment History ID
- Stored filename
- Download URL
- Review request URL
- Review UI URL
This should be enough for automated tooling to begin operating on the
Along with this, the
attached_file key in the JSON output is now
guaranteed to be an absolute path, which is better for automated tools.
rbt attachwith the new JSON output, with a combination of
Tested the payload with errors (invalid review request ID, filename).
Tested attaching with an attachment history ID and getting the new