<commit_before>all: ci goterp test


goterp: src/generated/reflections.go FORCE
	GOPATH=$$(pwd) go build -x goterp 
test: FORCE
	GOPATH=$$(pwd) go test -i src/terp/*.go
	GOPATH=$$(pwd) go test src/terp/*.go

_externs.txt: src/externs/externs.go
	go run src/externs/externs.go $$( eval $$(go env) ; find $$GOROOT/src/pkg/* -type d ) > _externs.txt

src/generated/reflections.go : src/externs/generate.tcl _externs.txt
	tclsh src/externs/generate1.tcl < _externs.txt  | grep -v // | grep -v _test | grep -v Test > src/generated/reflections.go
	tclsh src/externs/generate2.tcl < _externs.txt  | grep -v // | grep -v _test | grep -v Test >> src/generated/reflections.go
ci:
	ci -l -q -m/dev/null -t/dev/null src/*/*.go 
fmt:
	gofmt -w src/*/*.go 

demo1:
	./goterp 'must 3 [+ 1 2]; must 1015 [+ 0 1 2 3 [ + 2 2 ] [ - 8 3 ] [+ 100 900]]'

clean:
	rm -rf ./goterp _externs.txt src/generated/reflections.go pkg/*

FORCE:<commit_msg>generate1.tcl, generate2.tcl<commit_after>all: ci goterp test


goterp: src/generated/reflections.go FORCE
	GOPATH=$$(pwd) go build -x goterp 
test: FORCE
	GOPATH=$$(pwd) go test -i src/terp/*.go
	GOPATH=$$(pwd) go test src/terp/*.go

_externs.txt: src/externs/externs.go
	go run src/externs/externs.go $$( eval $$(go env) ; find $$GOROOT/src/pkg/* -type d ) > _externs.txt

src/generated/reflections.go : src/externs/generate1.tcl src/externs/generate2.tcl _externs.txt
	tclsh src/externs/generate1.tcl < _externs.txt  | grep -v // | grep -v _test | grep -v Test > src/generated/reflections.go
	tclsh src/externs/generate2.tcl < _externs.txt  | grep -v // | grep -v _test | grep -v Test >> src/generated/reflections.go
ci:
	ci -l -q -m/dev/null -t/dev/null src/*/*.go 
fmt:
	gofmt -w src/*/*.go 

demo1:
	./goterp 'must 3 [+ 1 2]; must 1015 [+ 0 1 2 3 [ + 2 2 ] [ - 8 3 ] [+ 100 900]]'

clean:
	rm -rf ./goterp _externs.txt src/generated/reflections.go pkg/*

FORCE:
{'fraction_non_alphanumeric': 0.16807610993657504, 'fraction_numerical': 0.02748414376321353, 'mean_word_length': 3.0974025974025974, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 11, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1574398', 'n_tokens_mistral': 893, 'n_tokens_neox': 799, 'n_words': 201}