diff options
| author | Jeff Carr <[email protected]> | 2025-10-24 18:31:45 -0500 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2025-10-24 18:31:45 -0500 |
| commit | e3f7c41f1082f132182c84961ab9fdf9666c8d79 (patch) | |
| tree | 31d9761f8d7162d4b2918fd36fc1f973304b1519 /rill.go | |
| parent | a2d6aac9f22bfe1060930e756a7dff86b3918f7e (diff) | |
s/ENV/env/ but ENV really is better herev0.0.189
Diffstat (limited to 'rill.go')
| -rw-r--r-- | rill.go | 18 |
1 files changed, 9 insertions, 9 deletions
@@ -6,9 +6,9 @@ import ( "time" "github.com/destel/rill" - "go.wit.com/lib/ENV" "go.wit.com/lib/cobol" "go.wit.com/lib/config" + "go.wit.com/lib/env" "go.wit.com/lib/protobuf/gitpb" "go.wit.com/log" ) @@ -36,11 +36,11 @@ func (f *Forge) RillReload() int { var counter int // Read users from the API. // Concurrency = 20 - dirs := rill.Map(ids, cobol.Int(ENV.Get("RillX")), func(repo *gitpb.Repo) (*gitpb.Repo, error) { + dirs := rill.Map(ids, cobol.Int(env.Get("RillX")), func(repo *gitpb.Repo) (*gitpb.Repo, error) { return repo, nil }) - rill.ForEach(dirs, cobol.Int(ENV.Get("RillY")), func(repo *gitpb.Repo) error { + rill.ForEach(dirs, cobol.Int(env.Get("RillY")), func(repo *gitpb.Repo) error { if err := repo.HasChanged(); err != nil { counter += 1 return err @@ -60,8 +60,8 @@ func (f *Forge) RillFuncError(rillf func(*gitpb.Repo) error) map[string]*RillSta } func (f *Forge) ConfigRill(rillX int, rillY int) { - ENV.Set("RillX", fmt.Sprintf("%d", rillX)) - ENV.Set("RillY", fmt.Sprintf("%d", rillY)) + env.Set("RillX", fmt.Sprintf("%d", rillX)) + env.Set("RillY", fmt.Sprintf("%d", rillY)) // log.Infof("Setting rill values to %d,%d\n", f.Config.RillX, f.Config.RillY) } @@ -135,11 +135,11 @@ func (f *Forge) RillRepos(rillf func(*gitpb.Repo) error) map[string]*RillStats { // Read users from the API. // Concurrency = 20 - dirs := rill.Map(ids, cobol.Int(ENV.Get("RillX")), func(id *gitpb.Repo) (*gitpb.Repo, error) { + dirs := rill.Map(ids, cobol.Int(env.Get("RillX")), func(id *gitpb.Repo) (*gitpb.Repo, error) { return id, nil }) - rill.ForEach(dirs, cobol.Int(ENV.Get("RillY")), func(repo *gitpb.Repo) error { + rill.ForEach(dirs, cobol.Int(env.Get("RillY")), func(repo *gitpb.Repo) error { // todo: make this a goroutine to show stats to the user rillMu.Lock() counter += 1 @@ -186,11 +186,11 @@ func (f *Forge) RunOnRepos(repos *gitpb.Repos, rillf func(*gitpb.Repo) error) ma // Read users from the API. // Concurrency = 20 - dirs := rill.Map(ids, cobol.Int(ENV.Get("RillX")), func(id *gitpb.Repo) (*gitpb.Repo, error) { + dirs := rill.Map(ids, cobol.Int(env.Get("RillX")), func(id *gitpb.Repo) (*gitpb.Repo, error) { return id, nil }) - rill.ForEach(dirs, cobol.Int(ENV.Get("RillY")), func(repo *gitpb.Repo) error { + rill.ForEach(dirs, cobol.Int(env.Get("RillY")), func(repo *gitpb.Repo) error { // todo: make this a goroutine to show stats to the user rillMu.Lock() counter += 1 |
