- Fix mole.cmd batch launcher to properly pass switch arguments
- Store %~dp0 before parse loop to avoid expansion issues
- Use PowerShell splatting in Invoke-MoleCommand for proper switch handling
- Rename $script:DryRun to $script:MoleDryRunMode in file_ops.ps1 to avoid
variable shadowing when dot-sourcing
- Handle switches passed as strings (e.g., '-ShowHelp') in mole.ps1 Main()
Fixes issue where 'mole clean -DryRun' would run cleanup instead of preview.
- Pester test suite for PowerShell scripts (Core, Clean, Commands)
- Go tests for TUI tools (analyze, status)
- GitHub Actions workflow for Windows CI
- Build and test automation scripts (test.ps1, build.ps1)
Add Go-based TUI tools for Windows:
- cmd/analyze: Interactive disk space analyzer with Bubble Tea
- cmd/status: Real-time system health monitor using gopsutil/WMI
- bin/analyze.ps1: Wrapper script for analyze tool
- bin/status.ps1: Wrapper script for status tool
- Makefile: Build automation for Go tools
- Updated README.md with Phase 3 documentation
Add cleanup modules and command scripts for Windows:
- lib/clean: user, caches, dev, apps, system cleanup modules
- bin/clean: deep cleanup orchestrator with dry-run and whitelist
- bin/uninstall: interactive app uninstaller
- bin/optimize: system optimization and health checks
- bin/purge: project artifact cleanup
All scripts support dry-run mode and follow safe deletion practices.
- Simplified banner in install.ps1 and ui.ps1 to avoid Unicode box-drawing
characters that caused parsing errors on some Windows systems
- Fixed PowerShell 5.1 compatibility for ANSI color codes using [char]27
- Renamed Show-Help to Show-InstallerHelp to avoid potential conflicts
- Changed -Help parameter to -ShowHelp for consistency with mole.ps1
Add isolated Windows support in windows/ directory with zero changes to existing macOS code.
Phase 1 includes:
- install.ps1: Windows installer with PATH and shortcut support
- mole.ps1: Main CLI entry point with menu system
- lib/core/base.ps1: Core definitions, colors, icons, constants
- lib/core/common.ps1: Common functions loader
- lib/core/file_ops.ps1: Safe file operations with protection checks
- lib/core/log.ps1: Logging functions with colors
- lib/core/ui.ps1: Interactive UI components (menus, confirmations)
- go.mod/go.sum: Go module for future TUI tools
- README.md: Windows-specific documentation
Closes#273
- Add '/Library/Input Methods' to application scan paths
- Unprotect Sogou, QQ, and Baidu input methods from system critical list
- Enhance file cleanup logic to detect input method plugins and caches
- Allow clean uninstallation and deep cleaning of WeType, Sogou, etc.
- Use temporary files (*.new) during installation process
- Perform atomic 'mv -f' operation to replace binaries
- Prevent partial updates if process is interrupted/fails
- Fixes critical issue where failed update deleted existing app
- Add classify_cleanup_risk() for risk level classification (LOW/MEDIUM/HIGH)
- Enhance safe_clean() with operation details and risk info
- Show item counts and file lists in debug mode
- Support for lib/clean/user.sh debug enhancements
- Part of GitHub issue #242 implementation
- Add file metadata logging in safe_remove() and safe_sudo_remove()
- Log file type, size, and age when in debug mode
- Support both dry-run and actual removal scenarios
- Part of GitHub issue #242 implementation
- Add debug_operation_start() for operation section headers
- Add debug_operation_detail() for detailed operation info
- Add debug_file_action() for file operations with metadata
- Add debug_risk_level() for risk classification with colors
- All functions output to both stderr and log file
- Addresses GitHub issue #242