MCPcopy
hub / github.com/cortesi/modd / trigger

Method trigger

modd.go:148–164  ·  view source on GitHub ↗
(root string, mod *moddwatch.Mod, dworld *DaemonWorld)

Source from the content-addressed store, hash-verified

146}
147
148func (mr *ModRunner) trigger(root string, mod *moddwatch.Mod, dworld *DaemonWorld) {
149 for i, b := range mr.Config.Blocks {
150 lmod := mod
151 if lmod != nil {
152 var err error
153 lmod, err = mod.Filter(root, b.Include, b.Exclude)
154 if err != nil {
155 mr.Log.Shout("Error filtering events: %s", err)
156 continue
157 }
158 if lmod.Empty() {
159 continue
160 }
161 }
162 mr.runBlock(b, lmod, dworld.DaemonPens[i])
163 }
164}
165
166// Gives control of chan to caller
167func (mr *ModRunner) runOnChan(modchan chan *moddwatch.Mod, readyCallback func()) error {

Callers 1

runOnChanMethod · 0.95

Calls 1

runBlockMethod · 0.95

Tested by

no test coverage detected