22PROJECT := GitMan
33PACKAGE := gitman
44REPOSITORY := jacebrowning/gitman
5+
6+ # Project paths
57PACKAGES := $(PACKAGE ) tests
6- CONFIG := $(shell ls * .py)
7- MODULES := $(shell find $( PACKAGES ) -name ' * .py') $( CONFIG )
8+ CONFIG := $(wildcard * .py)
9+ MODULES := $(wildcard $( PACKAGE ) / * .py)
810
911# Python settings
1012ifndef TRAVIS
@@ -62,7 +64,7 @@ HONCHO := $(ACTIVATE) && $(BIN)/honcho
6264# MAIN TASKS ###################################################################
6365
6466.PHONY : all
65- all : doc
67+ all : install
6668
6769.PHONY : ci
6870ci : check test demo # # Run all tasks that determine CI status
@@ -78,8 +80,6 @@ demo: install
7880 $(BIN ) /gitman list
7981 $(BIN ) /gitman lock
8082 $(BIN ) /gitman uninstall
81- $(BIN ) /gitman show
82- - $(BIN ) /gitman edit
8383
8484# SYSTEM DEPENDENCIES ##########################################################
8585
@@ -124,29 +124,24 @@ $(PYTHON):
124124
125125# CHECKS #######################################################################
126126
127- PEP8 := $(BIN ) /pep8
128- PEP8RADIUS := $(BIN ) /pep8radius
129- PEP257 := $(BIN ) /pep257
130127PYLINT := $(BIN ) /pylint
128+ PYCODESTYLE := $(BIN ) /pycodestyle
129+ PYDOCSTYLE := $(BIN ) /pydocstyle
131130
132131.PHONY : check
133- check : pep8 pep257 pylint # # Run linters and static analysis
134-
135- .PHONY : pep8
136- pep8 : install # # Check for convention issues
137- $(PEP8 ) $(PACKAGES ) $(CONFIG ) --config=.pep8rc
138-
139- .PHONY : pep257
140- pep257 : install # # Check for docstring issues
141- $(PEP257 ) $(PACKAGES ) $(CONFIG )
132+ check : pylint pycodestyle pydocstyle # # Run linters and static analysis
142133
143134.PHONY : pylint
144135pylint : install # # Check for code issues
145- $(PYLINT ) $(PACKAGES ) $(CONFIG ) --rcfile=.pylintrc
136+ $(PYLINT ) $(PACKAGES ) $(CONFIG ) --rcfile=.pylint.ini
137+
138+ .PHONY : pycodestyle
139+ pycodestyle : install # # Check for code conventions
140+ $(PYCODESTYLE ) $(PACKAGES ) $(CONFIG ) --config=.pycodestyle.ini
146141
147- .PHONY : fix
148- fix : install
149- $(PEP8RADIUS ) --docformatter --in-place
142+ .PHONY : pydocstyle
143+ pydocstyle : install # # Check for docstring conventions
144+ $(PYDOCSTYLE ) $( PACKAGES ) $( CONFIG )
150145
151146# TESTS ########################################################################
152147
@@ -179,12 +174,14 @@ test-unit: install ## Run the unit tests
179174.PHONY : test-int
180175test-int : install # # Run the integration tests
181176 @ if test -e $( FAILURES) ; then TEST_INTEGRATION=true $( PYTEST) $( PYTEST_OPTS_FAILFAST) tests; fi
182- $(PYTEST ) $(PYTEST_OPTS ) tests --junitxml=$(REPORTS ) /integration.xml
177+ @ rm -rf $(FAILURES )
178+ TEST_INTEGRATION=true $(PYTEST ) $(PYTEST_OPTS ) tests --junitxml=$(REPORTS ) /integration.xml
183179 $(COVERAGE_SPACE ) $(REPOSITORY ) integration
184180
185181.PHONY : test-all
186182test-all : install # # Run all the tests
187183 @ if test -e $( FAILURES) ; then TEST_INTEGRATION=true $( PYTEST) $( PYTEST_OPTS_FAILFAST) $( PACKAGES) ; fi
184+ @ rm -rf $(FAILURES )
188185 TEST_INTEGRATION=true $(PYTEST ) $(PYTEST_OPTS ) $(PACKAGES ) --junitxml=$(REPORTS ) /overall.xml
189186 $(COVERAGE_SPACE ) $(REPOSITORY ) overall
190187
0 commit comments