Spaces:
No application file
No application file
File size: 951 Bytes
9529bc2 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 |
"""
Development setup script.
"""
import os
import subprocess
import sys
def run_command(command):
"""Run a shell command and print its output."""
print(f"Running: {command}")
process = subprocess.run(command, shell=True, check=True)
return process.returncode
def setup_development():
"""Set up development environment."""
# Create conda environment
run_command("conda env create -f environment.yml")
# Install pre-commit hooks
run_command("pre-commit install")
# Create necessary directories
os.makedirs("logs", exist_ok=True)
os.makedirs("data", exist_ok=True)
print("\nDevelopment environment setup complete!")
print("\nTo activate the environment, run:")
print("conda activate agent2robot")
print("\nTo run tests:")
print("pytest tests/")
print("\nTo run the application:")
print("python src/main.py")
if __name__ == "__main__":
setup_development() |