<commit_before>.PHONY: check-env prepare

SOURCES=$(wilcard  *.go **/*.go **/**/*.go)
GODEP := $(GOPATH)/bin/godep

all: srasearch

dev: export PATH := $(GOPATH)/bin/:$(PATH) 
dev: check-env $(SOURCES)
	go-bindata -debug -o assets/assets.go \
		-pkg="assets" \
		-ignore=web/static/js/bootstrap.js \
		-ignore=web/static/js/jquery.js \
		web/static/... web/views/...
	go build -o srasearch-dev main.go

srasearch: export PATH := $(GOPATH)/bin/:$(PATH) 
srasearch: check-env $(SOURCES)
	go-bindata -o assets/assets.go \
		-pkg="assets" \
		-ignore=web/static/js/bootstrap.js \
		-ignore=web/static/js/jquery.js \
		web/static/... web/views/...
	go build -o srasearch main.go

prepare: check-env
	@echo "GOPATH is: ${GOPATH}"
	@echo "GOROOT is: ${GOROOT}"
	go get github.com/jteeuwen/go-bindata/go-bindata
	go get github.com/tools/godep
	$(GODEP) restore

check-env:
ifndef GOROOT
	$(error environment variable GOROOT is undefined)
endif

ifndef GOPATH
	$(error environment variable GOPATH is undefined)
endif
<commit_msg>+ introduce a 'clean' target to the Makefile<commit_after>.PHONY: check-env prepare clean

SOURCES=$(wilcard  *.go **/*.go **/**/*.go)
GODEP := $(GOPATH)/bin/godep

all: srasearch

dev: export PATH := $(GOPATH)/bin/:$(PATH) 
dev: check-env $(SOURCES)
	go-bindata -debug -o assets/assets.go \
		-pkg="assets" \
		-ignore=web/static/js/bootstrap.js \
		-ignore=web/static/js/jquery.js \
		web/static/... web/views/...
	go build -o srasearch-dev main.go

srasearch: export PATH := $(GOPATH)/bin/:$(PATH) 
srasearch: check-env $(SOURCES)
	go-bindata -o assets/assets.go \
		-pkg="assets" \
		-ignore=web/static/js/bootstrap.js \
		-ignore=web/static/js/jquery.js \
		web/static/... web/views/...
	go build -o srasearch main.go

prepare: check-env
	@echo "GOPATH is: ${GOPATH}"
	@echo "GOROOT is: ${GOROOT}"
	go get github.com/jteeuwen/go-bindata/go-bindata
	go get github.com/tools/godep
	$(GODEP) restore

check-env:
ifndef GOROOT
	$(error environment variable GOROOT is undefined)
endif

ifndef GOPATH
	$(error environment variable GOPATH is undefined)
endif

clean:
	if [ -e srasearch-dev ]; then rm srasearch-dev; fi;
	if [ -e srasearch ]; then rm srasearch; fi;
	if [ -e assets/assets.go ]; then rm -rf assets; fi;
	if [ -d build ]; then rm -rf build; fi;

{'fraction_non_alphanumeric': 0.17039964866051824, 'fraction_numerical': 0.0, 'mean_word_length': 3.3892100192678227, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3964620', 'n_tokens_mistral': 940, 'n_tokens_neox': 891, 'n_words': 217}