go fmt code, first step finished
This commit is contained in:
parent
fa6a0a751b
commit
750b3623b9
|
@ -84,7 +84,7 @@ func printRepos(repos []string) {
|
||||||
|
|
||||||
func repoSize(path string) (float32, bool, error) {
|
func repoSize(path string) (float32, bool, error) {
|
||||||
var size int64
|
var size int64
|
||||||
err := filepath.Walk(path,func(_ string,info os.FileInfo,err error) error {
|
err := filepath.Walk(path, func(_ string, info os.FileInfo, err error) error {
|
||||||
if !info.IsDir() {
|
if !info.IsDir() {
|
||||||
size += info.Size()
|
size += info.Size()
|
||||||
}
|
}
|
||||||
|
@ -92,7 +92,7 @@ func repoSize(path string) (float32, bool, error) {
|
||||||
})
|
})
|
||||||
|
|
||||||
outOf1G := false
|
outOf1G := false
|
||||||
if size > 1024 * 1024 * 1024 {
|
if size > 1024*1024*1024 {
|
||||||
outOf1G = true
|
outOf1G = true
|
||||||
}
|
}
|
||||||
sizeMB := float32(size) / 1024.0 / 1024.0
|
sizeMB := float32(size) / 1024.0 / 1024.0
|
||||||
|
|
Loading…
Reference in New Issue