~sircmpwn/sr.ht-dev

This thread contains a patchset. You're looking at the original emails, but you may wish to use the patch review UI. Review patch
3 2

[PATCH sr.ht-docs] git.sr.ht: add section about referencing todo tickets

Details
Message ID
<20211120133749.41691-1-robin@jarry.cc>
DKIM signature
missing
Download raw message
Patch: +65 -0
It is now possible to reference tracker tickets in git commit messages.
Describe how it works.

Signed-off-by: Robin Jarry <robin@jarry.cc>
---
 git.sr.ht/index.md | 65 ++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 65 insertions(+)

diff --git a/git.sr.ht/index.md b/git.sr.ht/index.md
index 3ca034ba320a..4d693df6922f 100644
--- a/git.sr.ht/index.md
+++ b/git.sr.ht/index.md
@@ -144,6 +144,71 @@ to send the new version. Update the **patchset revision** field on step two when
you get there &mdash; set it to the number of patchset versions you've sent so
far.

# Referencing tickets in git commit messages

If your source repository is linked to a [project](../hub.sr.ht/), you may
interact with [todo.sr.ht](../todo.sr.ht/) tickets via specific git commit
[trailers](https://git-scm.com/docs/git-interpret-trailers). The trailer values
must be valid URLs to tickets. Any other value will be ignored. A comment will
be inserted in the referenced tickets with a back-link to the git commit.

Example:

> [~jdoe](https://sr.ht/~jdoe) <b>UNRESOLVED</b> -> <b>FIXED</b>       <i>9 seconds ago</i>
>
> *Referenced this ticket with commit [ffbadcaca0](https://git.sr.ht/~jdoe/foobar/commit/ffbadcaca0)*.

<div class="alert alert-info">
  <strong>Note:</strong>
  You must have comment and triage access to the bug tracker, otherwise the
  trailers will be ignored.
</div>

The following trailers are supported:

## Fixes

If the ticket is unresolved, it will be resolved with the `FIXED` resolution.
If it is already resolved, only a comment will be inserted.

Example:

```
build: work around gcc 4.2 bug

Fix build with ancient gcc.

Fixes: https://todo.sr.ht/~jdoe/foobar/666
Signed-off-by: John Doe <john@doe.io>
```

## Implements

If the ticket is unresolved, it will be resolved with the `IMPLEMENTED`
resolution. If it is already resolved, only a comment will be inserted.

Example:

```
foo: add support for yaml config files

Implements: https://todo.sr.ht/~jdoe/foobar/1337
Signed-off-by: John Doe <john@doe.io>
```

## References

The ticket status will not be changed, only a comment will be inserted.

Example:

```
foo: add missing docs for yaml config

References: https://todo.sr.ht/~jdoe/foobar/1337
Signed-off-by: John Doe <john@doe.io>
```

# Attaching files to releases

git.sr.ht allows you to attach files, such as executables (aka binaries), PGP
-- 
2.34.0.rc2.3.g21d73fb69d7a

[PATCH sr.ht-docs v2] git.sr.ht: add section about referencing todo tickets

Details
Message ID
<20211121143556.53030-1-robin@jarry.cc>
In-Reply-To
<20211120133749.41691-1-robin@jarry.cc> (view parent)
DKIM signature
missing
Download raw message
Patch: +85 -0
It is now possible to reference tracker tickets in git commit messages.
Describe how it works.

Signed-off-by: Robin Jarry <robin@jarry.cc>
---
v1 -> v2:
    Added warning about the last 25 commits per push limitation.
    Added example of commit message.

NB: I could not test this patch. I cannot get the wiki to render
anything: https://man.sr.ht/~rjarry/sr.ht-docs/

 git.sr.ht/index.md | 85 ++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 85 insertions(+)

diff --git a/git.sr.ht/index.md b/git.sr.ht/index.md
index 3ca034ba320a..c321bf561c71 100644
--- a/git.sr.ht/index.md
+++ b/git.sr.ht/index.md
@@ -144,6 +144,91 @@ to send the new version. Update the **patchset revision** field on step two when
you get there &mdash; set it to the number of patchset versions you've sent so
far.

# Referencing tickets in git commit messages

If your source repository is linked to a [project](../hub.sr.ht/index.md), you
may interact with [todo.sr.ht](../todo.sr.ht/index.md) tickets via specific git
commit [trailers](https://git-scm.com/docs/git-interpret-trailers). The trailer
values must be valid URLs to tickets. Any other value will be ignored.
A comment will be inserted in the referenced tickets with a back-link to the
git commit.

For example, the following commit message:

```
build: work around gcc 4.2 bug

Fix build with ancient gcc.

Fixes: https://todo.sr.ht/~jdoe/foobar/666
Signed-off-by: John Doe <john@doe.io>
```

Will cause the following change on the referenced issue:

> [~jdoe](https://sr.ht/~jdoe) <b>UNRESOLVED</b> -> <b>FIXED</b>       <i>9 seconds ago</i>
>
> *Referenced this ticket with commit [badcaca0](https://git.sr.ht/~jdoe/foobar/commit/badcaca0)*.

<div class="alert alert-info">
  <strong>Note:</strong>
  You must have comment and triage access to the bug tracker, otherwise the
  trailers will be ignored.
</div>

<div class="alert alert-warning">
  <strong>Attention:</strong>
  Only the last 25 commits will be considered when pushing large series. Any
  referenced issue in a commit preceding the last 25 will be ignored. If you
  **really** need to push more than 25 commits for a single feature, do
  multiple 25 commits pushes.
</div>

The following trailers are supported:

## Fixes

If the ticket is unresolved, it will be resolved with the `FIXED` resolution.
If it is already resolved, only a comment will be inserted.

Example:

```
build: work around gcc 4.2 bug

Fix build with ancient gcc.

Fixes: https://todo.sr.ht/~jdoe/foobar/666
Signed-off-by: John Doe <john@doe.io>
```

## Implements

If the ticket is unresolved, it will be resolved with the `IMPLEMENTED`
resolution. If it is already resolved, only a comment will be inserted.

Example:

```
foo: add support for yaml config files

Implements: https://todo.sr.ht/~jdoe/foobar/1337
Signed-off-by: John Doe <john@doe.io>
```

## References

The ticket status will not be changed, only a comment will be inserted.

Example:

```
foo: add missing docs for yaml config

References: https://todo.sr.ht/~jdoe/foobar/1337
Signed-off-by: John Doe <john@doe.io>
```

# Attaching files to releases

git.sr.ht allows you to attach files, such as executables (aka binaries), PGP
-- 
2.34.0.rc2.3.g21d73fb69d7a

[PATCH sr.ht-docs v3] git.sr.ht: add section about referencing todo tickets

Details
Message ID
<20211128201212.219211-1-robin@jarry.cc>
In-Reply-To
<20211120133749.41691-1-robin@jarry.cc> (view parent)
DKIM signature
missing
Download raw message
Patch: +87 -0
It is now possible to reference tracker tickets in git commit messages.
Describe how it works.

Signed-off-by: Robin Jarry <robin@jarry.cc>
---
v2 -> v3:
    Tested rendering: https://man.sr.ht/~rjarry/sr.ht-docs/git.sr.ht/
    Adjusted ticket comment following the changes in hub.sr.ht v3 patch.

 git.sr.ht/index.md | 87 ++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 87 insertions(+)

diff --git a/git.sr.ht/index.md b/git.sr.ht/index.md
index 3ca034ba320a..ec281e47770e 100644
--- a/git.sr.ht/index.md
+++ b/git.sr.ht/index.md
@@ -144,6 +144,93 @@ to send the new version. Update the **patchset revision** field on step two when
you get there &mdash; set it to the number of patchset versions you've sent so
far.

# Referencing tickets in git commit messages

If your source repository is linked to a [project](../hub.sr.ht/index.md), you
may interact with [todo.sr.ht](../todo.sr.ht/index.md) tickets via specific git
commit [trailers](https://git-scm.com/docs/git-interpret-trailers). The trailer
values must be valid URLs to tickets. Any other value will be ignored.
A comment will be inserted in the referenced tickets with a back-link to the
git commit and its original author.

For example, the following commit message:

```
build: work around gcc 4.2 bug

Fix build with ancient gcc.

Fixes: https://todo.sr.ht/~arkanoid/foobar/666
Signed-off-by: John Doe <john@doe.io>
```

Will cause the following change on the referenced issue:

> [~arkanoid](https://sr.ht/~arkanoid) **UNRESOLVED -> FIXED** _9 seconds ago_
>
> _John Doe referenced this ticket with commit
> [badcaca0](https://git.sr.ht/~arkanoid/foobar/commit/badcaca0)_.

<div class="alert alert-info">
  <strong>Note:</strong>
  The user pushing the commit must have comment and triage access to the bug
  tracker, otherwise the trailers will be ignored. The commit author is only
  used in the inserted comment.
</div>

<div class="alert alert-warning">
  <strong>Attention:</strong>
  Only the last 25 commits will be considered when pushing large series. Any
  referenced issue in a commit preceding the last 25 will be ignored. If you
  <i>really</i> need to push more than 25 commits for a single feature, do
  it in multiple pushes.
</div>

The following trailers are supported:

## Fixes

If the ticket is unresolved, it will be resolved with the `FIXED` resolution.
If it is already resolved, only a comment will be inserted.

Example:

```
build: work around gcc 4.2 bug

Fix build with ancient gcc.

Fixes: https://todo.sr.ht/~arkanoid/foobar/666
Signed-off-by: John Doe <john@doe.io>
```

## Implements

If the ticket is unresolved, it will be resolved with the `IMPLEMENTED`
resolution. If it is already resolved, only a comment will be inserted.

Example:

```
foo: add support for yaml config files

Implements: https://todo.sr.ht/~arkanoid/foobar/1337
Signed-off-by: John Doe <john@doe.io>
```

## References

The ticket status will not be changed, only a comment will be inserted.

Example:

```
foo: add missing docs for yaml config

References: https://todo.sr.ht/~arkanoid/foobar/1337
Signed-off-by: John Doe <john@doe.io>
```

# Attaching files to releases

git.sr.ht allows you to attach files, such as executables (aka binaries), PGP
-- 
2.30.2

Re: [PATCH sr.ht-docs v3] git.sr.ht: add section about referencing todo tickets

Details
Message ID
<CG26AQW7I8ER.1AALWS3Z7JN58@taiga>
In-Reply-To
<20211128201212.219211-1-robin@jarry.cc> (view parent)
DKIM signature
fail
Download raw message
DKIM signature: fail
Thanks!

To git@git.sr.ht:~sircmpwn/sr.ht-docs
   6570673..48bdf47  master -> master
Reply to thread Export thread (mbox)