Git Mailing List Archive mirror
 help / color / mirror / Atom feed
* Suggestion to provide a way for screenshots to be added to commit messages
@ 2023-05-05 14:51 Shafiq Jetha
  2023-05-05 15:23 ` rsbecker
  2023-05-06  9:01 ` Erik Cervin Edin
  0 siblings, 2 replies; 5+ messages in thread
From: Shafiq Jetha @ 2023-05-05 14:51 UTC (permalink / raw)
  To: git@vger.kernel.org

Hi all,
 
It would be nice if we could add images directly to commit messages via git. The reason for this is so that we can view the history and see real examples of important UI elements. Usually during a PR we provide screenshots so that people can see how the change affects UI elements, or to show the output of specific commands that might show specific data in specific scenarios. I can also see this being useful for people that work on projects where code produces some sort of visual output where words cannot accurately describe the changes (a picture is worth 1000 words, right?).
 
It would be great if this sort of an integration could be considered, and I know that this would mean updating the clients, specifically the command-based clients, to interpret these images and provide a way to render them or display a link to them in some fashion. There's also the question of whether to embed the images directly in the commit message or to link out to them and download them as artefacts of the repo. And then there is the everlasting question of whether or not a git repo should contain build artefacts at all (since it can be argued that an image is a build artefact).
Lots of things to consider but I hope that I have at least started a dialogue for this to be explored further.
 
Thank you all for your time.



^ permalink raw reply	[flat|nested] 5+ messages in thread

* RE: Suggestion to provide a way for screenshots to be added to commit messages
  2023-05-05 14:51 Suggestion to provide a way for screenshots to be added to commit messages Shafiq Jetha
@ 2023-05-05 15:23 ` rsbecker
  2023-05-06  9:01 ` Erik Cervin Edin
  1 sibling, 0 replies; 5+ messages in thread
From: rsbecker @ 2023-05-05 15:23 UTC (permalink / raw)
  To: 'Shafiq Jetha', git

On Friday, May 5, 2023 10:51 AM, Shafiq Jetha wrote:
>It would be nice if we could add images directly to commit messages via
git. The
>reason for this is so that we can view the history and see real examples of
important
>UI elements. Usually during a PR we provide screenshots so that people can
see how
>the change affects UI elements, or to show the output of specific commands
that
>might show specific data in specific scenarios. I can also see this being
useful for
>people that work on projects where code produces some sort of visual output
where
>words cannot accurately describe the changes (a picture is worth 1000
words, right?).
>
>It would be great if this sort of an integration could be considered, and I
know that
>this would mean updating the clients, specifically the command-based
clients, to
>interpret these images and provide a way to render them or display a link
to them in
>some fashion. There's also the question of whether to embed the images
directly in
>the commit message or to link out to them and download them as artefacts of
the
>repo. And then there is the everlasting question of whether or not a git
repo should
>contain build artefacts at all (since it can be argued that an image is a
build
>artefact).
>Lots of things to consider but I hope that I have at least started a
dialogue for this to
>be explored further.

My team has a similar use case. We adopted a few ticket systems - depending
on our git upstream - including Jira and GitHub Issues. Both provide the
capability to upload images and have discussions during the PR referencing
the original ticket via the commit content. The commit comment simply needs
to reference the issue through the integration provided by the ticket
systems. Something like this might solve your need and is off the shelf.

--Randall


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Suggestion to provide a way for screenshots to be added to commit messages
  2023-05-05 14:51 Suggestion to provide a way for screenshots to be added to commit messages Shafiq Jetha
  2023-05-05 15:23 ` rsbecker
@ 2023-05-06  9:01 ` Erik Cervin Edin
  2023-05-06 11:54   ` Teng Long
  1 sibling, 1 reply; 5+ messages in thread
From: Erik Cervin Edin @ 2023-05-06  9:01 UTC (permalink / raw)
  To: Shafiq Jetha; +Cc: git@vger.kernel.org

On Fri, May 5, 2023 at 4:56 PM Shafiq Jetha <shafiq.jetha@benevity.com> wrote:
>
> It would be nice if we could add images directly to commit messages via git.

Maybe something similar to what git notes does 🤔
Then again, maybe it's easier to just do this differently.
Like keeping track of this using a markdown wiki in the repository and
just storing the images as a part of the project instead

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Suggestion to provide a way for screenshots to be added to commit messages
  2023-05-06  9:01 ` Erik Cervin Edin
@ 2023-05-06 11:54   ` Teng Long
       [not found]     ` <xmqqpm7drvz7.fsf@gitster.g>
  0 siblings, 1 reply; 5+ messages in thread
From: Teng Long @ 2023-05-06 11:54 UTC (permalink / raw)
  To: erik; +Cc: git, shafiq.jetha

Erik Cervin Edin <erik@cervined.in> writes:

>Maybe something similar to what git notes does 🤔
>Then again, maybe it's easier to just do this differently.
>Like keeping track of this using a markdown wiki in the repository and
>just storing the images as a part of the project instead

git notes subcommand can save binary file in note message.
We can find some clues in git-notes.txt and t3304-notes-man.sh.
By default, the file specified by `-F` will do stripspace for
the whole file content, for example, if the binary file contains
consecutive newlines it will be compressed into only one, in
another word, the binary file which recover from this like note
message will become corrupt, so I made patch[1] to support an option
`--[no-]stripspace` will solve this.

I'm not sure the scenario of using git note to save the binary is
suitable, but the above context may give some ideas, maybe.

Thanks.

[1] https://public-inbox.org/git/20063beab1893535f03e13b75058d501ed9f2faa.1682671758.git.dyroneteng@gmail.com/

^ permalink raw reply	[flat|nested] 5+ messages in thread

* RE: Suggestion to provide a way for screenshots to be added to commit messages
       [not found]     ` <xmqqpm7drvz7.fsf@gitster.g>
@ 2023-05-08 14:19       ` Shafiq Jetha
  0 siblings, 0 replies; 5+ messages in thread
From: Shafiq Jetha @ 2023-05-08 14:19 UTC (permalink / raw)
  To: Junio C Hamano, Teng Long; +Cc: erik@cervined.in, git@vger.kernel.org

Yes! This is exactly what I had it mind. It would require a lot of organisation but I think it could work really, really well if implemented like this.

-----Original Message-----
From: Junio C Hamano <jch2355@gmail.com> On Behalf Of Junio C Hamano
Sent: Saturday, May 6, 2023 3:28 PM
To: Teng Long <dyroneteng@gmail.com>
Cc: erik@cervined.in; git@vger.kernel.org; Shafiq Jetha <shafiq.jetha@benevity.com>
Subject: Re: Suggestion to provide a way for screenshots to be added to commit messages

[You don't often get email from gitster@pobox.com. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]

Teng Long <dyroneteng@gmail.com> writes:

> I'm not sure the scenario of using git note to save the binary is 
> suitable, but the above context may give some ideas, maybe.

A project could choose to store its commit log message in some arbitrary binary format, encoded to be safe when displayed as text by accident (e.g. "Content-type: text/html" with quoted-printable, or something silly like that) when shown in plain vanilla "git log".

Then repository viewers can be taught to render such a "rich" log message in any way it wants.  I do not know if authors of "gitk"
(bundled with us) or "tig" (not provided by us) are interested in doing so to their ware, but there are tons of GUI Clients out there
(https://git-scm.com/downloads/guis) and authors of some of them may be enticed to add such a new feature ;-)


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2023-05-08 14:20 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-05-05 14:51 Suggestion to provide a way for screenshots to be added to commit messages Shafiq Jetha
2023-05-05 15:23 ` rsbecker
2023-05-06  9:01 ` Erik Cervin Edin
2023-05-06 11:54   ` Teng Long
     [not found]     ` <xmqqpm7drvz7.fsf@gitster.g>
2023-05-08 14:19       ` Shafiq Jetha

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).