#!/bin/bash # Lint fix script for VibeTunnel Tauri project # This script automatically fixes formatting and some linting issues set -e echo "๐Ÿ”ง Auto-fixing Rust code issues for Tauri..." cd "$(dirname "$0")/src-tauri" # Format code echo "๐Ÿ“‹ Formatting code with rustfmt..." cargo fmt echo "โœ… Code formatted!" # Fix clippy warnings that can be auto-fixed echo "๐Ÿ”ง Attempting to fix clippy warnings..." cargo clippy --fix --allow-dirty --allow-staged -- -D warnings echo "โœ… Applied clippy fixes!" # Run tests to ensure nothing broke echo "๐Ÿงช Running tests to verify fixes..." cargo test echo "โœ… All tests passed!" echo "๐ŸŽ‰ All auto-fixes completed successfully!" echo "" echo "Note: Some issues may require manual fixes. Run ./lint.sh to check for remaining issues."