add a lookup by path function
This commit is contained in:
parent
3d6002b055
commit
e6eb92845a
11
new.go
11
new.go
|
@ -17,6 +17,15 @@ func ListAll() {
|
|||
}
|
||||
}
|
||||
|
||||
// returns the object for the path
|
||||
func FindPath(path string) *RepoStatus {
|
||||
if windowMap[path] == nil {
|
||||
log.Log(INFO, "FindPath() not initialized yet", path)
|
||||
return nil
|
||||
}
|
||||
return windowMap[path]
|
||||
}
|
||||
|
||||
func NewRepoStatusWindow(path string) *RepoStatus {
|
||||
if windowMap[path] == nil {
|
||||
log.Log(INFO, "NewRepoStatusWindow() adding new", path)
|
||||
|
@ -45,7 +54,7 @@ func NewRepoStatusWindow(path string) *RepoStatus {
|
|||
}
|
||||
|
||||
rs := &RepoStatus{
|
||||
ready: false,
|
||||
ready: false,
|
||||
}
|
||||
rs.tags = make(map[string]string)
|
||||
rs.window = gadgets.RawBasicWindow("GO Repo Details " + path)
|
||||
|
|
Loading…
Reference in New Issue