Update PhutilInteractiveEditor to allow specifying a "task message" which will be displayed just prior to launching the user's editor.
Refs T3271
Differential D21700
Display informative message when arc launches an editor cspeckmim on Jul 20 2021, 9:58 PM. Authored by Tags None Referenced Files
Subscribers
Details
Update PhutilInteractiveEditor to allow specifying a "task message" which will be displayed just prior to launching the user's editor. Refs T3271 I ran several arc diff commands in varying states to invoke my editor and verified that it printed out the text indicating that my editor was being launched.
Diff Detail
Event Timeline
Comment Actions Maybe the output could be two separate lines:
Then neither part needs to care about the other part, and things are likely more translatable and such. In this mode, it might also be helpful to print a success message ("Edit completed.")? I'm on the fence about this, but it might make debugging user reports easier since you can tell if they made it through the editing part or not -- not sure how much confusion/ambiguity you've run into in practice. Comment Actions
Yea that works a lot better. Though I'm on the fence about the order of the two messages. Logically my brain wants the "Launching..." message to be second but I don't think it really matters
Yea I could add that too. Is there any precedent for nested/indented messages? Something like Launching editor ("nano")... Supply commit message for uncommitted changes, then save and exit. Edit completed. I don't think I've run into this issue at all, but saw T3271 referenced from PHI1667 and figured this would be a good simple task to try out. Comment Actions There a bit of fancier indent/formatting stuff in some of the newer code (e.g., in ArcanistRefView->newLines()) but it hasn't really generalized into something you could easily apply here yet. I think this is fine for now and we could revisit it to make it fancier later on if the newest display stuff gets generalized a bit.
|