aboutsummaryrefslogtreecommitdiffstats
path: root/identity
diff options
context:
space:
mode:
Diffstat (limited to 'identity')
-rw-r--r--identity/identity.go5
-rw-r--r--identity/version.go8
2 files changed, 6 insertions, 7 deletions
diff --git a/identity/identity.go b/identity/identity.go
index d6504c52..bf0e853c 100644
--- a/identity/identity.go
+++ b/identity/identity.go
@@ -13,7 +13,6 @@ import (
"github.com/MichaelMure/git-bug/entity"
"github.com/MichaelMure/git-bug/repository"
- "github.com/MichaelMure/git-bug/util/git"
"github.com/MichaelMure/git-bug/util/lamport"
"github.com/MichaelMure/git-bug/util/timestamp"
)
@@ -40,7 +39,7 @@ type Identity struct {
versions []*Version
// not serialized
- lastCommit git.Hash
+ lastCommit repository.Hash
}
func NewIdentity(name string, email string) *Identity {
@@ -357,7 +356,7 @@ func (i *Identity) Commit(repo repository.ClockedRepo) error {
return err
}
- var commitHash git.Hash
+ var commitHash repository.Hash
if i.lastCommit != "" {
commitHash, err = repo.StoreCommitWithParent(treeHash, i.lastCommit)
} else {
diff --git a/identity/version.go b/identity/version.go
index 2359bd11..8b6a7c24 100644
--- a/identity/version.go
+++ b/identity/version.go
@@ -6,11 +6,11 @@ import (
"fmt"
"strings"
+ "github.com/pkg/errors"
+
"github.com/MichaelMure/git-bug/repository"
- "github.com/MichaelMure/git-bug/util/git"
"github.com/MichaelMure/git-bug/util/lamport"
"github.com/MichaelMure/git-bug/util/text"
- "github.com/pkg/errors"
)
const formatVersion = 1
@@ -45,7 +45,7 @@ type Version struct {
metadata map[string]string
// Not serialized
- commitHash git.Hash
+ commitHash repository.Hash
}
type VersionJSON struct {
@@ -174,7 +174,7 @@ func (v *Version) Validate() error {
// Write will serialize and store the Version as a git blob and return
// its hash
-func (v *Version) Write(repo repository.Repo) (git.Hash, error) {
+func (v *Version) Write(repo repository.Repo) (repository.Hash, error) {
// make sure we don't write invalid data
err := v.Validate()
if err != nil {