From 39b119350096dee8c34d3aaa426c17105795caa9 Mon Sep 17 00:00:00 2001 From: Jonathan Chappelow Date: Mon, 25 Apr 2022 08:41:35 -0500 Subject: [PATCH] chainhash: bump to v2 This bumps the major module version for chaincfg/chainhash to v2. This is needed to resolve an ambiguous import issue with the same package existing in older revisions of the main btcd module. Users who import both a tagged revision of btcd prior to the chainhash module, as well as another module such as btcd that requires the chainhash module may be met with an ambiguous import error from the go tooling. --- chaincfg/chainhash/README.md | 6 ++++-- chaincfg/chainhash/go.mod | 2 +- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/chaincfg/chainhash/README.md b/chaincfg/chainhash/README.md index b7ddf19ef7..755ec6d5eb 100644 --- a/chaincfg/chainhash/README.md +++ b/chaincfg/chainhash/README.md @@ -3,7 +3,7 @@ chainhash [![Build Status](https://github.com/btcsuite/btcd/workflows/Build%20and%20Test/badge.svg)](https://github.com/btcsuite/btcd/actions) [![ISC License](http://img.shields.io/badge/license-ISC-blue.svg)](http://copyfree.org) -[![GoDoc](https://img.shields.io/badge/godoc-reference-blue.svg)](https://pkg.go.dev/github.com/btcsuite/btcd/chaincfg/chainhash) +[![GoDoc](https://img.shields.io/badge/godoc-reference-blue.svg)](https://pkg.go.dev/github.com/btcsuite/btcd/chaincfg/chainhash/v2) ======= chainhash provides a generic hash type and associated functions that allows the @@ -11,8 +11,10 @@ specific hash algorithm to be abstracted. ## Installation and Updating +To add the dependency to your module, edit your go.mod or: + ```bash -$ go get -u github.com/btcsuite/btcd/chaincfg/chainhash +$ go get -d github.com/btcsuite/btcd/chaincfg/chainhash/v2@latest ``` ## GPG Verification Key diff --git a/chaincfg/chainhash/go.mod b/chaincfg/chainhash/go.mod index 1d865254dd..bf8df621da 100644 --- a/chaincfg/chainhash/go.mod +++ b/chaincfg/chainhash/go.mod @@ -1,3 +1,3 @@ -module github.com/btcsuite/btcd/chaincfg/chainhash +module github.com/btcsuite/btcd/chaincfg/chainhash/v2 go 1.17