github.com/TrueBlocks/trueblocks-core/src/apps/chifra@v0.0.0-20241022031540-b362680128f7/internal/daemon/handle_scraper.go (about) 1 package daemonPkg 2 3 import ( 4 scrapePkg "github.com/TrueBlocks/trueblocks-core/src/apps/chifra/internal/scrape" 5 "github.com/TrueBlocks/trueblocks-core/src/apps/chifra/pkg/output" 6 ) 7 8 // HandleScraper starts and manages the scraper process 9 func (opts *DaemonOptions) HandleScraper(rCtx *output.RenderCtx) error { 10 if len(opts.Scrape) == 0 { 11 return nil 12 } 13 14 scrapeOpts := scrapePkg.GetScrapeOptions([]string{}, &opts.Globals) 15 err := scrapeOpts.ScrapeInternal(rCtx) 16 return err 17 }