aboutsummaryrefslogtreecommitdiff
path: root/go/weed/export.go
diff options
context:
space:
mode:
authorChris Lu <chris.lu@gmail.com>2014-08-25 11:37:00 -0700
committerChris Lu <chris.lu@gmail.com>2014-08-25 11:37:00 -0700
commit4c58cef24aa81c08f3df0b3d8bbaede9e54bfa0c (patch)
tree21b0915dbc29c15766253c6486b202dcb1c67196 /go/weed/export.go
parentaac5fa49de28504f12e283f5fb22f22a1044c676 (diff)
downloadseaweedfs-4c58cef24aa81c08f3df0b3d8bbaede9e54bfa0c.tar.xz
seaweedfs-4c58cef24aa81c08f3df0b3d8bbaede9e54bfa0c.zip
a bit refactoring to prepare for volume format change and backward
compatibility.
Diffstat (limited to 'go/weed/export.go')
-rw-r--r--go/weed/export.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/go/weed/export.go b/go/weed/export.go
index 3f8ff85bb..f79ab1a5f 100644
--- a/go/weed/export.go
+++ b/go/weed/export.go
@@ -27,7 +27,7 @@ var cmdExport = &Command{
UsageLine: "export -dir=/tmp -volumeId=234 -o=/dir/name.tar -fileNameFormat={{.Name}}",
Short: "list or export files from one volume data file",
Long: `List all files in a volume, or Export all files in a volume to a tar file if the output is specified.
-
+
The format of file name in the tar file can be customized. Default is {{.Mime}}/{{.Id}}:{{.Name}}. Also available is {{.Key}}.
`,
@@ -100,7 +100,7 @@ func runExport(cmd *Command, args []string) bool {
var version storage.Version
err = storage.ScanVolumeFile(*exportVolumePath, *exportCollection, vid, func(superBlock storage.SuperBlock) error {
- version = superBlock.Version
+ version = superBlock.Version()
return nil
}, true, func(n *storage.Needle, offset int64) error {
nv, ok := nm.Get(n.Id)