From db018882ed2519538900b3c8fb128cdc4c6fa71c Mon Sep 17 00:00:00 2001 From: Jeremy Rand Date: Fri, 18 Jun 2021 00:07:10 +0000 Subject: [PATCH 1/2] readme: specify module path in go mod init command Fixes error: go: cannot determine module path for source directory /home/redfish/foo/ncdns (outside GOPATH, module path must be specified) Fixes #141 --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 7f4c399..0b1604f 100644 --- a/README.md +++ b/README.md @@ -112,7 +112,7 @@ Option B: Using Go build commands with Go modules (works on any platform with Ba 2. Run the following in the ncdns directory to set up Go modules: ~~~ - go mod init + go mod init github.com/namecoin/ncdns go mod edit -replace github.com/coreos/go-systemd=github.com/coreos/go-systemd/v22@latest -replace github.com/namecoin/x509-compressed=../x509-compressed go mod tidy ~~~ From 352b173e1396c27aefa3d3feea39b80fb6d722af Mon Sep 17 00:00:00 2001 From: Jeremy Rand Date: Fri, 18 Jun 2021 00:12:36 +0000 Subject: [PATCH 2/2] Cirrus: Specify module path in "go mod init" This makes Cirrus match the README. --- .cirrus.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.cirrus.yml b/.cirrus.yml index b9381b6..66c13dd 100644 --- a/.cirrus.yml +++ b/.cirrus.yml @@ -29,14 +29,14 @@ task: - cd ../ - git clone https://github.com/namecoin/x509-compressed.git - cd x509-compressed - - go mod init + - go mod init github.com/namecoin/x509-compressed - go mod tidy - go generate ./... - go mod tidy - go install -v ./... fetch_script: - cd $(go env GOPATH)/src/github.com/"$CIRRUS_REPO_FULL_NAME" - - go mod init + - go mod init github.com/"$CIRRUS_REPO_FULL_NAME" - go mod edit -replace github.com/coreos/go-systemd=github.com/coreos/go-systemd/v22@latest -replace github.com/namecoin/x509-compressed=../x509-compressed - go mod tidy lint_script: @@ -109,14 +109,14 @@ task: - cd ../ - git clone https://github.com/namecoin/x509-compressed.git - cd x509-compressed - - go mod init + - go mod init github.com/namecoin/x509-compressed - go mod tidy - go generate ./... - go mod tidy - go install -v ./... fetch_script: - cd $(go env GOPATH)/src/github.com/"$CIRRUS_REPO_FULL_NAME" - - go mod init + - go mod init github.com/"$CIRRUS_REPO_FULL_NAME" - go mod edit -replace github.com/coreos/go-systemd=github.com/coreos/go-systemd/v22@latest -replace github.com/namecoin/x509-compressed=../x509-compressed - go mod tidy # Get the test suite @@ -165,14 +165,14 @@ task: - cd ../ - git clone https://github.com/namecoin/x509-compressed.git - cd x509-compressed - - go mod init + - go mod init github.com/namecoin/x509-compressed - go mod tidy - go generate ./... - go mod tidy - go install -v ./... fetch_script: - cd $(go env GOPATH)/src/github.com/"$CIRRUS_REPO_FULL_NAME" - - go mod init + - go mod init github.com/"$CIRRUS_REPO_FULL_NAME" - go mod edit -replace github.com/coreos/go-systemd=github.com/coreos/go-systemd/v22@latest -replace github.com/namecoin/x509-compressed=../x509-compressed - go mod tidy build_script: