From 92d811804631bd616e40e7b5220450057eac5719 Mon Sep 17 00:00:00 2001 From: seanbreckenridge Date: Wed, 6 Sep 2023 17:11:32 -0700 Subject: [PATCH] ci: use python3 -m in CI --- install | 4 ++-- scripts/lint | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/install b/install index 37406659..a608fd49 100755 --- a/install +++ b/install @@ -179,7 +179,7 @@ ci_config() { ci_tests() { echo 'Running tests' | maybe_boxes ci && unset HPI_TESTS_SEANB - pytest ./tests || return $? + python3 -m pytest ./tests || return $? } ci_mypy() { @@ -239,7 +239,7 @@ ci_mypy() { ci_lint() { pip_install flake8 || return $? echo 'Linting...' | maybe_boxes - flake8 ./my || return $? + python3 -m flake8 ./my || return $? } ci_run() { diff --git a/scripts/lint b/scripts/lint index d5cef542..5afef1d1 100755 --- a/scripts/lint +++ b/scripts/lint @@ -70,11 +70,11 @@ update_fork() { main() { (update_fork) # cd in subshell - pytest "$@" || prompt '' + python3 -m pytest "$@" || prompt '' echo "Running mypy..." MY_CONFIG="${BASE_DIR}/tests/my" mypy --install-types --non-interactive --color-output -p my || prompt '' - mypy ~/.config/my/my/config/ || prompt '' - flake8 ./my || prompt '' + python3 -m mypy ~/.config/my/my/config/ || prompt '' + python3 -m flake8 ./my || prompt '' echo "Running shellcheck..." shellcheck_scripts # format everything in the repo