Browse Source

little fix

pull/103/head
Unknown 12 years ago
parent
commit
b31b0dfa69
  1. 8
      doc/github.go
  2. 4
      gpm.go

8
doc/github.go

@ -106,7 +106,10 @@ func GetGithubDoc(client *http.Client, match map[string]string, commit string, i
// Check if it is directory or not.
if strings.HasSuffix(absPath, "/") {
// Directory.
// Check if current directory is example.
if !(!isDownloadEx && strings.Contains(absPath, "example")) {
dirs = append(dirs, absPath)
}
continue
}
@ -143,11 +146,6 @@ func GetGithubDoc(client *http.Client, match map[string]string, commit string, i
// Check if need to check imports.
if isCheckImport {
for _, d := range dirs {
// Check if current directory is example.
if !isDownloadEx && strings.Contains(d, "example") {
continue
}
dir, err := os.Open(d)
if err != nil {
return nil, nil, err

4
gpm.go

@ -159,8 +159,8 @@ func initialize() bool {
}
// Create bundle and snapshot directories.
os.MkdirAll(appPath+"bundles", os.ModePerm)
os.MkdirAll(appPath+"snapshots", os.ModePerm)
os.MkdirAll(appPath+"repo/bundles/", os.ModePerm)
os.MkdirAll(appPath+"repo/snapshots/", os.ModePerm)
return true
}

Loading…
Cancel
Save