<commit_before># only random once obviously ;)
python=venv/bin/python
pip=venv/bin/pip
pycodestyle=venv/bin/pycodestyle
pyresttest=venv/bin/pyresttest
manage=$(python) $(CURDIR)/manage.py

lint:
	$(pycodestyle) $(CURDIR)/nextcloudappstore --exclude=migrations

test: lint
	$(manage) test
	# assume that the testserver is running on port 8001


# Only for local setup, do not use in production
dev-setup:
	pyvenv venv
	@echo "DEBUG = True" > $(CURDIR)/nextcloudappstore/local_settings.py
	@echo "SECRET_KEY = 'secret'" >> $(CURDIR)/nextcloudappstore/local_settings.py
	$(pip) install -r $(CURDIR)/requirements/development.txt
	$(pip) install -r $(CURDIR)/requirements/production.txt
	$(manage) migrate
	$(manage) loaddata $(CURDIR)/nextcloudappstore/**/fixtures/*.yaml
	@echo "from django.contrib.auth.models import User; User.objects.create_superuser('admin', '<EMAIL>', 'admin')" | $(manage) shell<commit_msg>add owners and collaborators to model<commit_after># only random once obviously ;)
python=venv/bin/python
pip=venv/bin/pip
pycodestyle=venv/bin/pycodestyle
pyresttest=venv/bin/pyresttest
manage=$(python) $(CURDIR)/manage.py

lint:
	$(pycodestyle) $(CURDIR)/nextcloudappstore --exclude=migrations

test: lint
	$(manage) test
	# assume that the testserver is running on port 8001


# Only for local setup, do not use in production
dev-setup:
	pyvenv venv
	@echo "DEBUG = True" > $(CURDIR)/nextcloudappstore/local_settings.py
	@echo "SECRET_KEY = 'secret'" >> $(CURDIR)/nextcloudappstore/local_settings.py
	$(pip) install -r $(CURDIR)/requirements/development.txt
	$(pip) install -r $(CURDIR)/requirements/production.txt
	$(manage) migrate
	$(manage) loaddata $(CURDIR)/nextcloudappstore/**/fixtures/*.yaml
	@echo "from django.contrib.auth.models import User; User.objects.create_superuser('admin', '<EMAIL>', 'admin')" | $(manage) shell

{'fraction_non_alphanumeric': 0.14525745257452574, 'fraction_numerical': 0.004336043360433604, 'mean_word_length': 5.862453531598513, 'pattern_counts': {'":': 0, '<': 5, '<?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': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4677336', 'n_tokens_mistral': 650, 'n_tokens_neox': 614, 'n_words': 146}