mirror of
https://github.com/minio/mc.git
synced 2025-11-13 12:22:45 +03:00
Removing more dead code
This commit is contained in:
4
Godeps/_workspace/src/github.com/dustin/go-humanize/comma.go
generated
vendored
4
Godeps/_workspace/src/github.com/dustin/go-humanize/comma.go
generated
vendored
@@ -33,7 +33,7 @@ func Comma(v int64) string {
|
|||||||
j--
|
j--
|
||||||
}
|
}
|
||||||
parts[j] = strconv.Itoa(int(v))
|
parts[j] = strconv.Itoa(int(v))
|
||||||
return sign + strings.Join(parts[j:len(parts)], ",")
|
return sign + strings.Join(parts[j:], ",")
|
||||||
}
|
}
|
||||||
|
|
||||||
// Commaf produces a string form of the given number in base 10 with
|
// Commaf produces a string form of the given number in base 10 with
|
||||||
@@ -97,5 +97,5 @@ func BigComma(b *big.Int) string {
|
|||||||
j--
|
j--
|
||||||
}
|
}
|
||||||
parts[j] = strconv.Itoa(int(b.Int64()))
|
parts[j] = strconv.Itoa(int(b.Int64()))
|
||||||
return sign + strings.Join(parts[j:len(parts)], ",")
|
return sign + strings.Join(parts[j:], ",")
|
||||||
}
|
}
|
||||||
|
|||||||
2
Godeps/_workspace/src/github.com/shiena/ansicolor/ansicolor_windows.go
generated
vendored
2
Godeps/_workspace/src/github.com/shiena/ansicolor/ansicolor_windows.go
generated
vendored
@@ -308,7 +308,7 @@ func (cw *ansiColorWriter) Write(p []byte) (int, error) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if cw.state == outsideCsiCode {
|
if cw.state == outsideCsiCode {
|
||||||
nw, err = cw.w.Write(p[first:len(p)])
|
nw, err = cw.w.Write(p[first:])
|
||||||
}
|
}
|
||||||
|
|
||||||
return r + nw + nc, err
|
return r + nw + nc, err
|
||||||
|
|||||||
@@ -19,8 +19,9 @@ package main
|
|||||||
import "errors"
|
import "errors"
|
||||||
|
|
||||||
var (
|
var (
|
||||||
|
// TODO remove, unused
|
||||||
// fs
|
// fs
|
||||||
errFskey = errors.New("Key is needed to get the file")
|
// errFskey = errors.New("Key is needed to get the file")
|
||||||
|
|
||||||
// url
|
// url
|
||||||
errEmptyURL = errors.New("URL is empty")
|
errEmptyURL = errors.New("URL is empty")
|
||||||
@@ -31,8 +32,9 @@ var (
|
|||||||
// url
|
// url
|
||||||
errInvalidURL = errors.New("Invalid URL")
|
errInvalidURL = errors.New("Invalid URL")
|
||||||
|
|
||||||
|
// TODO remove, unused
|
||||||
// host
|
// host
|
||||||
errHostname = errors.New("No hostname specified")
|
// errHostname = errors.New("No hostname specified")
|
||||||
|
|
||||||
// common
|
// common
|
||||||
errInvalidbucket = errors.New("Invalid bucket name")
|
errInvalidbucket = errors.New("Invalid bucket name")
|
||||||
|
|||||||
@@ -105,25 +105,6 @@ func fixFileURL(urlStr string) (fixedURL string, err error) {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// url2Host extracts hostname from the URL.
|
|
||||||
func url2Host(urlStr string) (host string, err error) {
|
|
||||||
if urlStr == "" {
|
|
||||||
return "", iodine.New(errEmptyURL, nil)
|
|
||||||
}
|
|
||||||
|
|
||||||
utype, e := getURLType(urlStr)
|
|
||||||
if e != nil || utype != urlFile {
|
|
||||||
return "", iodine.New(e, nil)
|
|
||||||
}
|
|
||||||
|
|
||||||
u, e := url.Parse(urlStr)
|
|
||||||
if e != nil {
|
|
||||||
return "", iodine.New(e, nil)
|
|
||||||
}
|
|
||||||
|
|
||||||
return u.Host, nil
|
|
||||||
}
|
|
||||||
|
|
||||||
// url2Object converts URL to bucket and objectname
|
// url2Object converts URL to bucket and objectname
|
||||||
func url2Object(urlStr string) (bucketName, objectName string, err error) {
|
func url2Object(urlStr string) (bucketName, objectName string, err error) {
|
||||||
u, err := url.Parse(urlStr)
|
u, err := url.Parse(urlStr)
|
||||||
|
|||||||
Reference in New Issue
Block a user