-
Notifications
You must be signed in to change notification settings - Fork 77
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add setup script for development and adjust readme (#818)
- Loading branch information
1 parent
e545921
commit 6bb04f9
Showing
2 changed files
with
57 additions
and
48 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
#!/usr/bin/env bash | ||
# Setups the development environment. | ||
|
||
# Stop on errors | ||
set -e | ||
|
||
cd "$(dirname "$0")/.." | ||
|
||
env_name=${1:-".venv"} | ||
|
||
if [ -d "$env_name" ]; then | ||
echo "Virtual environment '$env_name' already exists." | ||
else | ||
echo "Creating Virtual environment..." | ||
python -m venv .venv | ||
fi | ||
echo "Activating virtual environment..." | ||
source .venv/bin/activate | ||
|
||
echo "Installing development dependencies..." | ||
|
||
pip install -e ".[server]" | ||
pip install -e ".[test]" | ||
pre-commit install |