Files
Northern-Thailand-Ping-Rive…/scripts/init_git.sh
grabowski 19e182c53b
Some checks failed
Release - Northern Thailand Ping River Monitor / Create Release (push) Successful in 6s
Security & Dependency Updates / Dependency Security Scan (push) Successful in 19s
Security & Dependency Updates / Docker Security Scan (push) Successful in 1m12s
Security & Dependency Updates / License Compliance (push) Successful in 11s
Security & Dependency Updates / Check for Dependency Updates (push) Successful in 14s
Security & Dependency Updates / Code Quality Metrics (push) Successful in 9s
Release - Northern Thailand Ping River Monitor / Test Release Build (3.10) (push) Failing after 1m17s
Release - Northern Thailand Ping River Monitor / Test Release Build (3.11) (push) Failing after 23s
Release - Northern Thailand Ping River Monitor / Test Release Build (3.9) (push) Has been cancelled
Release - Northern Thailand Ping River Monitor / Build Release Images (push) Has been cancelled
Release - Northern Thailand Ping River Monitor / Security Scan (push) Has been cancelled
Release - Northern Thailand Ping River Monitor / Deploy Release (push) Has been cancelled
Release - Northern Thailand Ping River Monitor / Validate Release (push) Has been cancelled
Release - Northern Thailand Ping River Monitor / Notify Release (push) Has been cancelled
Release - Northern Thailand Ping River Monitor / Test Release Build (3.12) (push) Has been cancelled
Security & Dependency Updates / Security Summary (push) Has been cancelled
Version bump: 3.1.0 3.1.1
Version Updates:
- Core application version (src/__init__.py)
- Web API version (src/web_api.py)
- Main application logging (src/main.py)
- Package setup version (setup.py)
- Documentation generation (docs workflow)
- Release workflow example version
- Badge generation script
- Integration test version display
- README.md badge version
- Setup and deployment documentation
- Git initialization scripts

 Patch Release (3.1.1):
- Workflow token migration fixes (GITHUB_TOKEN  GH_TOKEN)
- Pip installation warning elimination
- Improved workflow reliability and logging
- Better Gitea compatibility
- Enhanced error handling and validation

 Files Updated:
- 13 files with version references updated
- Consistent versioning across all components
- Ready for release tagging and deployment
2025-08-12 16:52:39 +07:00

89 lines
1.6 KiB
Bash

#!/bin/bash
# Git initialization script for Northern Thailand Ping River Monitor
echo "🏔️ Initializing Git repository for Northern Thailand Ping River Monitor"
# Initialize git repository
git init
# Add remote origin
git remote add origin https://git.b4l.co.th/B4L/Northern-Thailand-Ping-River-Monitor.git
# Create .gitignore if it doesn't exist
if [ ! -f .gitignore ]; then
echo "Creating .gitignore file..."
cat > .gitignore << 'EOF'
# Python
__pycache__/
*.py[cod]
*.so
.Python
build/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
var/
wheels/
*.egg-info/
.installed.cfg
*.egg
# Virtual environments
.env
.venv
env/
venv/
ENV/
# IDE
.vscode/
.idea/
*.swp
*.swo
# Logs
*.log
logs/
# Database files
*.db
*.sqlite
*.sqlite3
# OS
.DS_Store
Thumbs.db
EOF
fi
# Add all files
git add .
# Initial commit
git commit -m "Initial commit: Northern Thailand Ping River Monitor v3.1.1
Features:
- Real-time water level monitoring for Ping River Basin
- 16 monitoring stations from Chiang Dao to Nakhon Sawan
- FastAPI web interface with station management
- Multi-database support (SQLite, MySQL, PostgreSQL, InfluxDB, VictoriaMetrics)
- Comprehensive monitoring and health checks
- Docker deployment with Grafana integration
- Production-ready architecture with CI/CD pipeline"
echo "✅ Git repository initialized successfully!"
echo ""
echo "Next steps:"
echo "1. Review and edit .env file with your configuration"
echo "2. Push to remote repository:"
echo " git push -u origin main"
echo ""
echo "3. Start the application:"
echo " make run-api"
echo " # or: python run.py --web-api"