iterative / gto

🏷️ Git Tag Ops. Turn your Git repository into Artifact Registry or Model Registry.
https://dvc.org/doc/gto
Apache License 2.0
142 stars 16 forks source link

Feature Request: Authors in `gto history` #345

Open abpwrs opened 1 year ago

abpwrs commented 1 year ago

Would it be possible to add an "author" column to the result of gto history?

Where "commit" events have the commit author as "author", and for all gto events ("assignment", and "registration") the "author" is the git tag author (might only work for annotated tags and not lightweight).

aguschin commented 1 year ago

Hi @abpwrs! Thanks for the feature request. I can implement this, but first let's come up with a decent CLI option for that.

I can implement something like

$ gto history --show default,author,email

default referencing to the default column set, so one could select any subset he likes.

WDYT - does it look right or you would suggest some other way to control that?

abpwrs commented 1 year ago

Hey @aguschin, that seems reasonable to me!

To clarify, if I were to do: $ gto history --show author it would only show the author column for each event w/o any other context, correct?

A couple suggestions/thoughts would be:

  1. to allow $ gto history --show all as a short-hand for all possible columns
  2. maybe using --format over --show (something closer to git log --format might be more intuitive for gto users that likely already know git)