diff options
| author | Jeff Carr <[email protected]> | 2025-10-20 13:21:03 -0500 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2025-10-20 13:21:03 -0500 |
| commit | 69b5038c58e6a8487f22aeaf28eddec5c785c283 (patch) | |
| tree | 72b9910c32a803d8c7f3bffc0f5d7175516d39b0 /repoNew.go | |
| parent | 2ecc340541f88d4c1cbe437efe79a6fcfdbf5499 (diff) | |
probably better. notsure
Diffstat (limited to 'repoNew.go')
| -rw-r--r-- | repoNew.go | 10 |
1 files changed, 5 insertions, 5 deletions
@@ -15,7 +15,7 @@ import ( ) func (f *Forge) NewGoRepo(gopath string, url string) (*gitpb.Repo, error) { - fullpath := filepath.Join(f.Config.ReposDir, gopath) + fullpath := filepath.Join(config.Get("ReposDir"), gopath) test := f.Repos.FindByFullPath(fullpath) if test != nil { return test, nil @@ -192,12 +192,12 @@ func (f *Forge) configUserBranchName(repo *gitpb.Repo) string { if uname != "" { return uname } - if f.Config.Username == "" { + if config.Get("username") == "" { // something is wrong! } // use the os.Username - uname = f.Config.Username + uname = config.Get("username") return uname } @@ -230,7 +230,7 @@ func (f *Forge) AddFullPath(fulldir string) *gitpb.Repo { // } func (f *Forge) FindByNamespace(gopath string) *gitpb.Repo { - fullpath := filepath.Join(f.Config.ReposDir, gopath) + fullpath := filepath.Join(config.Get("ReposDir"), gopath) return f.Repos.FindByFullPath(fullpath) } @@ -257,6 +257,6 @@ func (f *Forge) FindAnyPath(dir string) *gitpb.Repo { } func (f *Forge) DeleteByGoPath(gopath string) bool { - fullpath := filepath.Join(f.Config.ReposDir, gopath) + fullpath := filepath.Join(config.Get("ReposDir"), gopath) return f.Repos.DeleteByFullPath(fullpath) } |
