~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
2 2

[PATCH git.sr.ht] Warn when we'd submit duplicate-basename manifest

Details
Message ID
<20200912212053.4onh37x4pp2m7r5o@nabtop.nabijaczleweli.xyz>
DKIM signature
pass
Download raw message
Patch: +7 -1
---
 gitsrht-update-hook/submitter.go | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/gitsrht-update-hook/submitter.go b/gitsrht-update-hook/submitter.go
index e50174c..5c96857 100644
--- a/gitsrht-update-hook/submitter.go
+++ b/gitsrht-update-hook/submitter.go
@@ -162,6 +162,12 @@ func (submitter GitBuildSubmitter) FindManifests() (map[string]string, error) {

	manifests := make(map[string]string)
	for _, file := range files {
		basename := path.Base(file.Name)
		if _, ok := manifests[basename]; ok {
			log.Printf("Not submitting duplicate manifest %s [%s]\n", file.Name, basename)
			continue
		}

		var (
			reader  io.Reader
			content []byte
@@ -175,7 +181,7 @@ func (submitter GitBuildSubmitter) FindManifests() (map[string]string, error) {
		if !utf8.Valid(content) {
			return nil, errors.Wrap(err, "manifest is not valid UTF-8 file")
		}
		manifests[path.Base(file.Name)] = string(content)
		manifests[basename] = string(content)
	}
	return manifests, nil
}
-- 
2.20.1
Details
Message ID
<C5N8VW4HT9VQ.1TYZZUN57FK6C@homura>
In-Reply-To
<20200912212053.4onh37x4pp2m7r5o@nabtop.nabijaczleweli.xyz> (view parent)
DKIM signature
pass
Download raw message
Thanks!

To git@git.sr.ht:~sircmpwn/git.sr.ht
   5dae4f3..0c45d64  master -> master

[git.sr.ht/patches] build failed

builds.sr.ht
Details
Message ID
<C5RK2GLLTHUP.1J86VQ50C2XTQ@cirno2>
In-Reply-To
<20200912212053.4onh37x4pp2m7r5o@nabtop.nabijaczleweli.xyz> (view parent)
DKIM signature
missing
Download raw message
git.sr.ht/patches: FAILED in 23m7s

[Warn when we'd submit duplicate-basename manifest][0] from [наб][1]

[0]: https://lists.sr.ht/~sircmpwn/sr.ht-dev/patches/13899
[1]: mailto:nabijaczleweli@nabijaczleweli.xyz

✗ #304923 FAILED git.sr.ht/patches/alpine.yml    https://builds.sr.ht/~sircmpwn/job/304923
✗ #304924 FAILED git.sr.ht/patches/archlinux.yml https://builds.sr.ht/~sircmpwn/job/304924
✗ #304925 FAILED git.sr.ht/patches/debian.yml    https://builds.sr.ht/~sircmpwn/job/304925
Reply to thread Export thread (mbox)