Skip to content

Commit

Permalink
Merge pull request #41 from geoadmin/feature_shellcheck
Browse files Browse the repository at this point in the history
v0.25.0 - add shellcheck and bash script linting - #minor
  • Loading branch information
ltclm authored Dec 7, 2021
2 parents 0d53d49 + f0b042f commit 6ddeceb
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
10 changes: 10 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,9 @@ AWS_DEFAULT_REGION = eu-central-1
# Find all python files that are not inside a hidden directory (directory starting with .)
PYTHON_FILES := $(shell find ./* -type f -name "*.py" -print)

# Find all bash files that are not inside a hidden directory (directory starting with .)
BASH_FILES := $(shell find ./* -type f -name "*.sh" -print)

# PIPENV files
PIP_FILE = Pipfile
PIP_FILE_LOCK = Pipfile.lock
Expand All @@ -48,6 +51,7 @@ YAPF := $(PIPENV_RUN) yapf
ISORT := $(PIPENV_RUN) isort
NOSE := $(PIPENV_RUN) nose2
PYLINT := $(PIPENV_RUN) pylint
SHELLCHECK := $(PIPENV_RUN) shellcheck



Expand All @@ -68,6 +72,7 @@ help:
@echo "- ci-check-format Format the python source code and check if any files has changed. This is meant to be used by the CI."
@echo "- lint Lint the python source code"
@echo "- format-lint Format and lint the python source code"
@echo "- shellcheck shellcheck all the bash scripts"
@echo "- test Run the tests"
@echo -e " \033[1mLOCAL SERVER TARGETS\033[0m "
@echo "- serve Run the project using the flask debug server. Port can be set by Env variable HTTP_PORT (default: 5000)"
Expand Down Expand Up @@ -130,6 +135,11 @@ lint:
format-lint: format lint


.PHONY: shellcheck
shellcheck:
$(SHELLCHECK) $(BASH_FILES)


# Test target

.PHONY: test
Expand Down
1 change: 1 addition & 0 deletions Pipfile
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ yapf = "*"
nose2 = "*"
pylint = "*"
pylint-flask = "*"
shellcheck-py = "*"

[requires]
python_version = "3.7"

0 comments on commit 6ddeceb

Please sign in to comment.