diff options
author | Máximo Cuadros <mcuadros@gmail.com> | 2017-06-18 12:15:40 +0200 |
---|---|---|
committer | Máximo Cuadros <mcuadros@gmail.com> | 2017-06-18 12:15:40 +0200 |
commit | abb9ec0f3efea571b7f19b7391eb7c152c899f45 (patch) | |
tree | 703bcd8caf958007e90d6694e5225084b3ddfdb5 /storage/filesystem/internal/dotgit/writers.go | |
parent | bf3a92052f715c507ace0cb9f2b7fb358f623abc (diff) | |
download | go-git-abb9ec0f3efea571b7f19b7391eb7c152c899f45.tar.gz |
*: upgrade to go-billy.v3, merge
Diffstat (limited to 'storage/filesystem/internal/dotgit/writers.go')
-rw-r--r-- | storage/filesystem/internal/dotgit/writers.go | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/storage/filesystem/internal/dotgit/writers.go b/storage/filesystem/internal/dotgit/writers.go index 0d2747f..2407c58 100644 --- a/storage/filesystem/internal/dotgit/writers.go +++ b/storage/filesystem/internal/dotgit/writers.go @@ -10,7 +10,7 @@ import ( "gopkg.in/src-d/go-git.v4/plumbing/format/objfile" "gopkg.in/src-d/go-git.v4/plumbing/format/packfile" - "gopkg.in/src-d/go-billy.v2" + "gopkg.in/src-d/go-billy.v3" ) // PackWriter is a io.Writer that generates the packfile index simultaneously, @@ -36,7 +36,7 @@ func newPackWrite(fs billy.Filesystem) (*PackWriter, error) { return nil, err } - fr, err := fs.Open(fw.Filename()) + fr, err := fs.Open(fw.Name()) if err != nil { return nil, err } @@ -130,7 +130,7 @@ func (w *PackWriter) Close() error { } func (w *PackWriter) clean() error { - return w.fs.Remove(w.fw.Filename()) + return w.fs.Remove(w.fw.Name()) } func (w *PackWriter) save() error { @@ -148,7 +148,7 @@ func (w *PackWriter) save() error { return err } - return w.fs.Rename(w.fw.Filename(), fmt.Sprintf("%s.pack", base)) + return w.fs.Rename(w.fw.Name(), fmt.Sprintf("%s.pack", base)) } func (w *PackWriter) encodeIdx(writer io.Writer) error { @@ -282,5 +282,5 @@ func (w *ObjectWriter) save() error { hash := w.Hash().String() file := w.fs.Join(objectsPath, hash[0:2], hash[2:40]) - return w.fs.Rename(w.f.Filename(), file) + return w.fs.Rename(w.f.Name(), file) } |