<commit_before>#
# Makefile for juju-core.
#

PROJECT := launchpad.net/juju-core
PROJECT_DIR := $(shell go list -e -f '{{.Dir}}' $(PACKAGE))

ifndef GOPATH
$(warning You need to set up a GOPATH.  See the README file.)
endif

define DEPENDENCIES
  build-essential
  bzr
  distro-info-data
  git-core
  golang-go
  mercurial
  zip
endef

default: build

# Start of GOPATH-dependent targets. Some targets only make sense -
# and will only work - when this tree is found on the GOPATH.
ifeq ($(CURDIR),$(PROJECT_DIR))

build:
	go build $(PROJECT)/...

check:
	go test $(PROJECT)/...

else # --------------------------------

build:
	$(error Cannot build package outside of GOPATH)

check:
	$(error Cannot check package outside of GOPATH)

endif
# End of GOPATH-dependent targets.

# Reformat the source files.
format:
	go fmt ./...

# Remove test executables.
clean:
	find . -name '*.test' -print0 | xargs -r0 $(RM) -v

# Install packages required to develop Juju and run tests.
install-dependencies:
	sudo apt-get install $(strip $(DEPENDENCIES))
	@echo
	@echo "Make sure you have MongoDB installed.  See the README file."

# Invoke gofmt's "simplify" option to streamline the source code.
simplify:
	gofmt -w -s .


.PHONY: build check format clean install-dependencies simplify<commit_msg>Use gofmt for consistency, and move simplify next to format.<commit_after>#
# Makefile for juju-core.
#

PROJECT := launchpad.net/juju-core
PROJECT_DIR := $(shell go list -e -f '{{.Dir}}' $(PACKAGE))

ifndef GOPATH
$(warning You need to set up a GOPATH.  See the README file.)
endif

define DEPENDENCIES
  build-essential
  bzr
  distro-info-data
  git-core
  golang-go
  mercurial
  zip
endef

default: build

# Start of GOPATH-dependent targets. Some targets only make sense -
# and will only work - when this tree is found on the GOPATH.
ifeq ($(CURDIR),$(PROJECT_DIR))

build:
	go build $(PROJECT)/...

check:
	go test $(PROJECT)/...

else # --------------------------------

build:
	$(error Cannot build package outside of GOPATH)

check:
	$(error Cannot check package outside of GOPATH)

endif
# End of GOPATH-dependent targets.

# Reformat the source files.
format:
	gofmt -w -l .

# Invoke gofmt's "simplify" option to streamline the source code.
simplify:
	gofmt -w -l -s .

# Clean the tree, including removing test executables.
clean:
	find . -name '*.test' -print0 | xargs -r0 $(RM) -v

# Install packages required to develop Juju and run tests.
install-dependencies:
	sudo apt-get install $(strip $(DEPENDENCIES))
	@echo
	@echo "Make sure you have MongoDB installed.  See the README file."


.PHONY: build check format simplify clean install-dependencies
{'fraction_non_alphanumeric': 0.1288135593220339, 'fraction_numerical': 0.0015065913370998117, 'mean_word_length': 3.215873015873016, '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': '688719', 'n_tokens_mistral': 912, 'n_tokens_neox': 862, 'n_words': 338}