<commit_before>GEM_VERSION = $(shell cat ../RES_VERSION)
GEM_NAME    = rails_event_store-browser
REQUIRE     = rails_event_store/browser ./spec/dummy_5_1_4/config/environment
IGNORE      =
SUBJECT     ?= RailsEventStore::Browser*
JS_BUNDLE   = public/rails_event_store_browser.js

install: ## Install gem dependencies
	@echo "Installing gem dependencies"
	@bundle install
	@echo "Installing npm dependencies"
	@cd elm; yarn install

test: $(JS_BUNDLE) ## Run unit tests
	@echo "Running unit and integration tests"
	@cd elm; yarn test; cd -
	@bundle exec rspec

mutate: ## Run mutation tests
	@echo "Running mutation tests"
	@bundle exec mutant --include lib \
		$(addprefix --require ,$(REQUIRE)) \
		$(addprefix --ignore-subject ,$(IGNORE))
		--use rspec "$(SUBJECT)"

$(JS_BUNDLE):
	@echo "Building browser frontend"
	@cd elm; yarn build

build: $(JS_BUNDLE)
	@echo "Building gem package"
	@gem build -V $(GEM_NAME).gemspec
	@mkdir -p pkg/
	@mv $(GEM_NAME)-$(GEM_VERSION).gem pkg/<commit_msg>Silly error unnoticed on CI.<commit_after>GEM_VERSION = $(shell cat ../RES_VERSION)
GEM_NAME    = rails_event_store-browser
REQUIRE     = rails_event_store/browser ./spec/dummy_5_1_4/config/environment
IGNORE      =
SUBJECT     ?= RailsEventStore::Browser*
JS_BUNDLE   = public/rails_event_store_browser.js

install: ## Install gem dependencies
	@echo "Installing gem dependencies"
	@bundle install
	@echo "Installing npm dependencies"
	@cd elm; yarn install

test: $(JS_BUNDLE) ## Run unit tests
	@echo "Running unit and integration tests"
	@cd elm; yarn test; cd -
	@bundle exec rspec

mutate: ## Run mutation tests
	@echo "Running mutation tests"
	@bundle exec mutant --include lib \
		$(addprefix --require ,$(REQUIRE)) \
		$(addprefix --ignore-subject ,$(IGNORE)) \
		--use rspec "$(SUBJECT)"

$(JS_BUNDLE):
	@echo "Building browser frontend"
	@cd elm; yarn build

build: $(JS_BUNDLE)
	@echo "Building gem package"
	@gem build -V $(GEM_NAME).gemspec
	@mkdir -p pkg/
	@mv $(GEM_NAME)-$(GEM_VERSION).gem pkg/
{'fraction_non_alphanumeric': 0.12668329177057355, 'fraction_numerical': 0.0029925187032418953, 'mean_word_length': 4.335106382978723, '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': '3727164', 'n_tokens_mistral': 734, 'n_tokens_neox': 697, 'n_words': 199}