mirror of
https://github.com/Chia-Network/chia-blockchain.git
synced 2025-01-06 04:07:16 +03:00
pre-commit: Fix a venv activation issue on linux (#12822)
* pre-commit: Fix a venv activation issue on linux I ended up with the same issue as in https://github.com/Chia-Network/chia-blockchain/pull/12235 and using `.` instead of `source` (Which is supposed to be the same?) fixed it. * Make it all `sh`
This commit is contained in:
parent
91bc4958d1
commit
43d679dba3
@ -18,7 +18,7 @@ def main(*args: str) -> int:
|
||||
command = ["powershell", os.fspath(here.joinpath(script)), *args]
|
||||
else:
|
||||
script = "activated.sh"
|
||||
command = [os.fspath(here.joinpath(script)), *args]
|
||||
command = ["sh", os.fspath(here.joinpath(script)), *args]
|
||||
|
||||
completed_process = subprocess.run(command)
|
||||
|
||||
|
@ -1,9 +1,9 @@
|
||||
#!/bin/bash
|
||||
#!/bin/sh
|
||||
|
||||
set -o errexit
|
||||
|
||||
SCRIPT_DIRECTORY=$(cd -- "$(dirname -- "$0")"; pwd)
|
||||
# shellcheck disable=SC1091
|
||||
source "${SCRIPT_DIRECTORY}/venv/bin/activate"
|
||||
. "${SCRIPT_DIRECTORY}/venv/bin/activate"
|
||||
|
||||
"$@"
|
||||
|
Loading…
Reference in New Issue
Block a user