Permalink
Browse files

Do not print token.

  • Loading branch information...
1 parent e901c33 commit 1f7910f1506f94f6b574aba30d02152f6aaadd6c @AlekSi committed Mar 3, 2013
Showing with 1 addition and 2 deletions.
  1. +1 −2 nut/publish.go
View
@@ -45,15 +45,14 @@ func runPublish(cmd *Command) {
url, err := url.Parse("http://" + NutImportPrefixes["gonuts.io"])
FatalIfErr(err)
- url.RawQuery = "token=" + publishToken
-
for _, arg := range cmd.Flag.Args() {
b, nf := ReadNut(arg)
url.Path = fmt.Sprintf("/%s/%s/%s", nf.Vendor, nf.Name, nf.Version)
if publishV {
log.Printf("Putting %s to %s ...", arg, url)
}
+ url.RawQuery = "token=" + publishToken
req, err := http.NewRequest("PUT", url.String(), bytes.NewReader(b))
FatalIfErr(err)
req.Header.Set("User-Agent", "nut publisher")

0 comments on commit 1f7910f

Please sign in to comment.