From 98085aad0eb01a3a9767f61fa5d36fb29809cc68 Mon Sep 17 00:00:00 2001 From: Rasmus Dahlberg Date: Sat, 2 Apr 2022 13:30:17 +0200 Subject: add backtrace on how to configure golang with cgit --- wiki/cgit-golang.md | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 wiki/cgit-golang.md (limited to 'wiki') diff --git a/wiki/cgit-golang.md b/wiki/cgit-golang.md new file mode 100644 index 0000000..5e67a7f --- /dev/null +++ b/wiki/cgit-golang.md @@ -0,0 +1,17 @@ +# Configure cgit repository to work with Go modules + +Are you seeing this error? + + $ go install git.sigsum.org/testing/cmd/hola@latest + go: git.sigsum.org/testing/cmd/hola@latest: unrecognized import path "git.sigsum.org/testing/cmd/hola": reading https://git.sigsum.org/testing/cmd/hola?go-get=1: 404 Not Found + +Remember to configure the cgit repository with [Go's meta tag][]. + +[Go's meta tag]: https://pkg.go.dev/cmd/go#hdr-Remote_import_paths + +## Backtrace + +This is where to look: + + root@getuid:~# rgrep go-import ~git/repositories + root@getuid:~# echo 'extra-head-content=' > ~git/repositories/testing.git/cgitrc -- cgit v1.2.3