- Implement argparse for CLI use - Setup SQLite DB with schema version checking
		
			
				
	
	
		
			21 lines
		
	
	
		
			418 B
		
	
	
	
		
			Bash
		
	
	
		
			Executable File
		
	
	
	
	
			
		
		
	
	
			21 lines
		
	
	
		
			418 B
		
	
	
	
		
			Bash
		
	
	
		
			Executable File
		
	
	
	
	
#!/bin/bash
 | 
						|
 | 
						|
# Create a virtual environment if it does not exist
 | 
						|
if [ ! -d "venv" ]; then
 | 
						|
  # shellcheck disable=SC1091
 | 
						|
  python3 -m venv venv && \
 | 
						|
  source venv/bin/activate && \
 | 
						|
  pip install -r requirements.txt && \
 | 
						|
  deactivate
 | 
						|
fi
 | 
						|
 | 
						|
# Activate the virtual environment
 | 
						|
# shellcheck disable=SC1091
 | 
						|
source venv/bin/activate
 | 
						|
 | 
						|
# Run the Python script
 | 
						|
python main.py "$@"
 | 
						|
 | 
						|
# Deactivate the virtual environment
 | 
						|
deactivate
 |