Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 5 additions & 6 deletions plugins/tutor-contrib-ltistore/Makefile
Original file line number Diff line number Diff line change
@@ -1,25 +1,24 @@
.DEFAULT_GOAL := help
.PHONY: docs
SRC_DIRS = ./tutor_ltistore
BLACK_OPTS = --exclude templates ${SRC_DIRS}

# Warning: These checks are not necessarily run on every PR.
test: test-lint test-types test-format # Run some static checks.

test-format: ## Run code formatting tests
black --check --diff $(BLACK_OPTS)
ruff format --check --diff $(SRC_DIRS)

test-lint: ## Run code linting tests
pylint --errors-only --enable=unused-import,unused-argument --ignore=templates --ignore=docs/_ext ${SRC_DIRS}
ruff check ${SRC_DIRS}

test-types: ## Run type checks.
mypy --exclude=templates --ignore-missing-imports --implicit-reexport --strict ${SRC_DIRS}

format: ## Format code automatically
black $(BLACK_OPTS)
ruff format ${SRC_DIRS}

isort: ## Sort imports. This target is not mandatory because the output may be incompatible with black formatting. Provided for convenience purposes.
isort --skip=templates ${SRC_DIRS}
fix-lint: ## Fix lint errors automatically
ruff check --fix ${SRC_DIRS}

ESCAPE = 
help: ## Print this help
Expand Down
1 change: 0 additions & 1 deletion plugins/tutor-contrib-ltistore/tutor_ltistore/plugin.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import os
from glob import glob

import click
import importlib_resources
from tutor import hooks

Expand Down
11 changes: 5 additions & 6 deletions plugins/tutor-contrib-paragon/Makefile
Original file line number Diff line number Diff line change
@@ -1,25 +1,24 @@
.DEFAULT_GOAL := help
.PHONY: docs
SRC_DIRS = ./tutorparagon
BLACK_OPTS = --exclude templates ${SRC_DIRS}

# Warning: These checks are not necessarily run on every PR.
test: test-lint test-types test-format # Run some static checks.

test-format: ## Run code formatting tests
black --check --diff $(BLACK_OPTS)
ruff format --check --diff $(SRC_DIRS)

test-lint: ## Run code linting tests
pylint --errors-only --enable=unused-import,unused-argument --ignore=templates --ignore=docs/_ext ${SRC_DIRS}
ruff check ${SRC_DIRS}

test-types: ## Run type checks.
mypy --exclude=templates --ignore-missing-imports --implicit-reexport --strict ${SRC_DIRS}

format: ## Format code automatically
black $(BLACK_OPTS)
ruff format ${SRC_DIRS}

isort: ## Sort imports. This target is not mandatory because the output may be incompatible with black formatting. Provided for convenience purposes.
isort --skip=templates ${SRC_DIRS}
fix-lint: ## Fix lint errors automatically
ruff check --fix ${SRC_DIRS}

unittest: ## Run code tests cases
pytest tests --ignore=tests/integration
Expand Down
1 change: 0 additions & 1 deletion plugins/tutor-contrib-paragon/tutorparagon/plugin.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import os
from glob import glob

import click
import importlib_resources
from tutor import hooks
from tutor import config as tutor_config
Expand Down