This commit is contained in:
evilsocket 2018-01-14 00:33:24 +01:00
parent 4631a25c4b
commit 42da5c6489
4 changed files with 3 additions and 15 deletions

1
.gitignore vendored
View file

@ -1,4 +1,3 @@
*.sw*
core/build.go
bettercap
bettercap.history

View file

@ -1,6 +1,4 @@
TARGET=bettercap
BUILD_DATE=`date +%Y-%m-%d\ %H:%M`
BUILD_FILE=core/build.go
all: fmt vet build
@echo "@ Done"
@ -8,17 +6,10 @@ all: fmt vet build
test: build
@go test ./...
build: build_file
build: resources
@echo "@ Building ..."
@go build $(FLAGS) -o $(TARGET) .
build_file: resources
@rm -f $(BUILD_FILE)
@echo "package core" > $(BUILD_FILE)
@echo "const (" >> $(BUILD_FILE)
@echo " BuildDate = \"$(BUILD_DATE)\"" >> $(BUILD_FILE)
@echo ")" >> $(BUILD_FILE)
resources:
@echo "@ Compiling resources into go files ..."
@$(GOPATH)/bin/go-bindata -o net/oui_compiled.go -pkg net net/oui.dat

View file

@ -3,7 +3,6 @@ package main
import (
"fmt"
"os"
"runtime"
"strings"
"github.com/evilsocket/bettercap-ng/core"
@ -21,8 +20,7 @@ func main() {
os.Exit(1)
}
fmt.Printf("%s v%s\n", core.Name, core.Version)
fmt.Printf("Build: date=%s os=%s arch=%s\n\n", core.BuildDate, runtime.GOOS, runtime.GOARCH)
fmt.Printf(core.Bold("%s v%s\n\n"), core.Name, core.Version)
sess.Register(modules.NewEventsStream(sess))
sess.Register(modules.NewProber(sess))

View file

@ -83,7 +83,7 @@ func netOuiDat() (*asset, error) {
return nil, err
}
info := bindataFileInfo{name: "net/oui.dat", size: 585353, mode: os.FileMode(420), modTime: time.Unix(1510072358, 0)}
info := bindataFileInfo{name: "net/oui.dat", size: 585353, mode: os.FileMode(420), modTime: time.Unix(1515886330, 0)}
a := &asset{bytes: bytes, info: info}
return a, nil
}