Skip to content

Commit

Permalink
Make run_in_venv POSIX compliant (not just Bash)
Browse files Browse the repository at this point in the history
  • Loading branch information
AndrewFerr committed Feb 7, 2025
1 parent 90a61c5 commit b135eb1
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions modules/restricted-guests/synapse/scripts/run_in_venv.sh
Original file line number Diff line number Diff line change
Expand Up @@ -23,14 +23,14 @@

set -e

cd -- "$(dirname -- "${BASH_SOURCE[0]}")/.."
cd -- "$(dirname -- "$0")/.."

repo_root=$(git rev-parse --show-cdup)
venv_path=${repo_root:-./}.venv

[ -d "$venv_path" ] || python3.11 -m venv "$venv_path"
source "$venv_path/bin/activate"
. "$venv_path/bin/activate"

pip install -e ."[dev]"

[ $# -gt 1 ] && $*
[ $# -gt 1 ] && "$@"

0 comments on commit b135eb1

Please sign in to comment.