<commit_before>SHELL := /bin/bash
COFFEE     = node_modules/.bin/coffee
COFFEELINT = node_modules/.bin/coffeelint
MOCHA      = node_modules/.bin/mocha --compilers coffee:coffee-script --require "coffee-script/register"
REPORTER   = spec

lint:
	@[ ! -f coffeelint.json ] && $(COFFEELINT) --makeconfig > coffeelint.json || true
	$(COFFEELINT) --file ./coffeelint.json src

build:
	make lint || true
	$(COFFEE) $(CSOPTS) --map --compile --output lib src

test: build
	DEBUG=Ratestate:* $(MOCHA) --reporter $(REPORTER) test/ --grep "$(GREP)"

compile:
	@echo "Compiling files"
	time make build

run-upload:
	source env.sh && make build && DEBUG=Ratestate:* ./bin/ratestate.js upload ./test/fixtures/test.md

run-download:
	source env.sh && make build && DEBUG=Ratestate:* ./bin/ratestate.js download -

watch:
	watch -n 2 make -s compile

release-major: build test
	npm version major -m "Release %s"
	git push
	npm publish

release-minor: build test
	npm version minor -m "Release %s"
	git push
	npm publish

release-patch: build test
	npm version patch -m "Release %s"
	git push
	npm publish

.PHONY: \
	test \
	lint \
	build \
	download-real \
	upload-real \
	sync-real \
	run-download \
	run-upload \
	release-major \
	release-minor \
	release-patch \
	compile \
	watch
<commit_msg>Local phonies<commit_after>SHELL     := /bin/bash
COFFEE     = node_modules/.bin/coffee
COFFEELINT = node_modules/.bin/coffeelint
MOCHA      = node_modules/.bin/mocha --compilers coffee:coffee-script --require "coffee-script/register"
REPORTER   = spec

.PHONY: lint
lint:
	@[ ! -f coffeelint.json ] && $(COFFEELINT) --makeconfig > coffeelint.json || true
	$(COFFEELINT) --file ./coffeelint.json src

.PHONY: build
build:
	make lint || true
	$(COFFEE) $(CSOPTS) --map --compile --output lib src

.PHONY: test
test: build
	DEBUG=Ratestate:* $(MOCHA) --reporter $(REPORTER) test/ --grep "$(GREP)"

.PHONY: compile
compile:
	@echo "Compiling files"
	time make build

.PHONY: run-upload
run-upload:
	source env.sh && make build && DEBUG=Ratestate:* ./bin/ratestate.js upload ./test/fixtures/test.md

.PHONY: run-download
run-download:
	source env.sh && make build && DEBUG=Ratestate:* ./bin/ratestate.js download -

.PHONY: watch
watch:
	watch -n 2 make -s compile

.PHONY: release-major
release-major: build test
	npm version major -m "Release %s"
	git push
	npm publish

.PHONY: release-minor
release-minor: build test
	npm version minor -m "Release %s"
	git push
	npm publish

.PHONY: release-patch
release-patch: build test
	npm version patch -m "Release %s"
	git push
	npm publish

{'fraction_non_alphanumeric': 0.1357254290171607, 'fraction_numerical': 0.00078003120124805, 'mean_word_length': 3.4377162629757785, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 7, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6994878', 'n_tokens_mistral': 1001, 'n_tokens_neox': 949, 'n_words': 265}