diff --git a/Makefile b/Makefile index ccf615a..f413c93 100644 --- a/Makefile +++ b/Makefile @@ -4,21 +4,22 @@ GOCLEAN=$(GOCMD) clean GOTEST=$(GOCMD) test GOGET=$(GOCMD) get BINARY_NAME=drmdtool +SRC_DIR=src all: test build build: - $(GOBUILD) -o $(BINARY_NAME) -v + cd $(SRC_DIR) && $(GOBUILD) -o ../$(BINARY_NAME) -v test: - $(GOTEST) -v ./... + cd $(SRC_DIR) && $(GOTEST) -v ./... clean: $(GOCLEAN) rm -f $(BINARY_NAME) run: - $(GOBUILD) -o $(BINARY_NAME) -v + cd $(SRC_DIR) && $(GOBUILD) -o ../$(BINARY_NAME) -v ./$(BINARY_NAME) deps: @@ -28,12 +29,12 @@ deps: # Cross compilation build-linux: - CGO_ENABLED=0 GOOS=linux GOARCH=amd64 $(GOBUILD) -o $(BINARY_NAME)_linux -v + cd $(SRC_DIR) && CGO_ENABLED=0 GOOS=linux GOARCH=amd64 $(GOBUILD) -o ../$(BINARY_NAME)_linux -v build-windows: - CGO_ENABLED=0 GOOS=windows GOARCH=amd64 $(GOBUILD) -o $(BINARY_NAME).exe -v + cd $(SRC_DIR) && CGO_ENABLED=0 GOOS=windows GOARCH=amd64 $(GOBUILD) -o ../$(BINARY_NAME).exe -v build-mac: - CGO_ENABLED=0 GOOS=darwin GOARCH=amd64 $(GOBUILD) -o $(BINARY_NAME)_mac -v + cd $(SRC_DIR) && CGO_ENABLED=0 GOOS=darwin GOARCH=amd64 $(GOBUILD) -o ../$(BINARY_NAME)_mac -v .PHONY: all build test clean run deps build-linux build-windows build-mac diff --git a/config.go b/src/config.go similarity index 100% rename from config.go rename to src/config.go diff --git a/downloaders.go b/src/downloaders.go similarity index 100% rename from downloaders.go rename to src/downloaders.go diff --git a/go.mod b/src/go.mod similarity index 100% rename from go.mod rename to src/go.mod diff --git a/go.sum b/src/go.sum similarity index 100% rename from go.sum rename to src/go.sum diff --git a/handlers.go b/src/handlers.go similarity index 100% rename from handlers.go rename to src/handlers.go diff --git a/main.go b/src/main.go similarity index 100% rename from main.go rename to src/main.go diff --git a/subtitles.go b/src/subtitles.go similarity index 100% rename from subtitles.go rename to src/subtitles.go diff --git a/templates/index b/src/templates/index similarity index 100% rename from templates/index rename to src/templates/index diff --git a/templates/progress b/src/templates/progress similarity index 100% rename from templates/progress rename to src/templates/progress diff --git a/templates/select b/src/templates/select similarity index 100% rename from templates/select rename to src/templates/select diff --git a/src/templates/stats b/src/templates/stats new file mode 100644 index 0000000..2cbf1b9 --- /dev/null +++ b/src/templates/stats @@ -0,0 +1,114 @@ + + + + + + Network Stats + + + + +

Network Stats

+
+
+

Upload Speed

+

0 MB/s

+

Total Upload

+

0 MB

+
+
+

Download Speed

+

0 MB/s

+

Total Download

+

0 MB

+
+
+ + + + \ No newline at end of file diff --git a/utils.go b/src/utils.go similarity index 100% rename from utils.go rename to src/utils.go