Start refactor of code into what I think is a more modular way of working
This commit is contained in:
@@ -1,41 +1,12 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"github.com/starkers/safer-eve/pkg/eve"
|
||||
"time"
|
||||
)
|
||||
|
||||
func main() {
|
||||
fmt.Println("searching")
|
||||
|
||||
//logDirs := eve.PathSearch()
|
||||
//fmt.Println(a)
|
||||
fileList := eve.FileSearchUnix()
|
||||
|
||||
//List := eve.GetActiveChannels(fileList)
|
||||
//for _, name := range List{
|
||||
// fmt.Println(name)
|
||||
//}
|
||||
|
||||
//for _, d := range logDirs {
|
||||
// fmt.Println(d)
|
||||
// go eve.WatchPath(d)
|
||||
//}
|
||||
|
||||
|
||||
for _, f := range fileList{
|
||||
if eve.IsCurrentLog(f) {
|
||||
//if strings.Contains(f, "delve.imperium") {
|
||||
// fmt.Printf("tailing file: %v\n", f)
|
||||
go eve.Tail(f)
|
||||
//}
|
||||
}
|
||||
//else {
|
||||
// fmt.Println(f)
|
||||
//}
|
||||
}
|
||||
time.Sleep(9999 * time.Hour)
|
||||
//Think about some cli params that might be useful later.
|
||||
eve.Init()
|
||||
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user