Skip to content

Commit

Permalink
cmd/blobstash-uploader: set a user agent while doing a snapshot
Browse files Browse the repository at this point in the history
  • Loading branch information
tsileo committed Apr 4, 2019
1 parent 3615c6a commit 9c695ba
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion cmd/blobstash-uploader/blobstash-uploader.go
Expand Up @@ -12,6 +12,8 @@ import (
"a4.io/blobstash/pkg/filetree/writer"
)

const ua = "blobstash-uploader v1"

func usage() {
fmt.Printf("Usage: %s [OPTIONS] [FSNAME] [DIRPATH]\n", os.Args[0])
flag.PrintDefaults()
Expand Down Expand Up @@ -84,7 +86,7 @@ func main() {
}

// Make a snaphot/create a FS entry for the given tree
rev, err := ft.MakeSnapshot(m.Hash, fsName, snapMessage)
rev, err := ft.MakeSnapshot(m.Hash, fsName, snapMessage, ua)
if err != nil {
fmt.Printf("failed to create snapshot: %v\n", err)
os.Exit(1)
Expand Down

0 comments on commit 9c695ba

Please sign in to comment.