22 lines
442 B
PowerShell
22 lines
442 B
PowerShell
# Check if .venv exists
|
|
if (Test-Path .venv) {
|
|
# Activate the virtual environment
|
|
.\.venv\Scripts\Activate.ps1
|
|
} else {
|
|
# Run uv sync if .venv does not exist
|
|
uv sync
|
|
.\.venv\Scripts\Activate.ps1
|
|
}
|
|
|
|
# Perform a git pull
|
|
git pull
|
|
|
|
# Run uv sync if .venv exists (already activated)
|
|
uv sync
|
|
# Start main.py
|
|
uv run python main.py
|
|
|
|
# Deactivate the virtual environment if it was activated
|
|
if (Test-Path .venv) {
|
|
deactivate
|
|
} |