|
| 1 | +# πͺ Windows Installation Guide for fazrepo |
| 2 | + |
| 3 | +This guide covers all the ways to install and use fazrepo on Windows. |
| 4 | + |
| 5 | +## π Installation Methods |
| 6 | + |
| 7 | +### Method 1: PowerShell (Recommended) |
| 8 | + |
| 9 | +Open PowerShell and run: |
| 10 | + |
| 11 | +```powershell |
| 12 | +irm https://raw.githubusercontent.com/avadakedavra-wp/fazrepo/main/install.ps1 | iex |
| 13 | +``` |
| 14 | + |
| 15 | +This will: |
| 16 | +- β
Download the latest Windows binary |
| 17 | +- β
Install to `%USERPROFILE%\bin` |
| 18 | +- β
Add to your PATH automatically |
| 19 | +- β
Verify the installation |
| 20 | + |
| 21 | +### Method 2: Git Bash / WSL |
| 22 | + |
| 23 | +If you're using Git Bash or Windows Subsystem for Linux: |
| 24 | + |
| 25 | +```bash |
| 26 | +curl -fsSL https://raw.githubusercontent.com/avadakedavra-wp/fazrepo/main/install.sh | bash |
| 27 | +``` |
| 28 | + |
| 29 | +### Method 3: Manual Download |
| 30 | + |
| 31 | +1. Go to [Releases](https://github.com/avadakedavra-wp/fazrepo/releases) |
| 32 | +2. Download `fazrepo-x86_64-pc-windows-msvc.exe` |
| 33 | +3. Rename to `fazrepo.exe` |
| 34 | +4. Place in a directory in your PATH |
| 35 | + |
| 36 | +### Method 4: From Source |
| 37 | + |
| 38 | +```bash |
| 39 | +# Install Rust first: https://rustup.rs/ |
| 40 | +git clone https://github.com/avadakedavra-wp/fazrepo.git |
| 41 | +cd fazrepo |
| 42 | +cargo build --release |
| 43 | +copy target\release\fazrepo.exe C:\Users\%USERNAME%\bin\ |
| 44 | +``` |
| 45 | + |
| 46 | +## π§ Package Manager Support on Windows |
| 47 | + |
| 48 | +fazrepo automatically detects Windows-specific command variations: |
| 49 | + |
| 50 | +### Supported Package Managers |
| 51 | + |
| 52 | +| Package Manager | Windows Command | Detection | |
| 53 | +|----------------|----------------|-----------| |
| 54 | +| **npm** | `npm.cmd` | β
Automatic | |
| 55 | +| **yarn** | `yarn.cmd` | β
Automatic | |
| 56 | +| **pnpm** | `pnpm.cmd` | β
Automatic | |
| 57 | +| **bun** | `bun.exe` | β
Automatic | |
| 58 | + |
| 59 | +### Command Examples |
| 60 | + |
| 61 | +```powershell |
| 62 | +# Check all package managers |
| 63 | +fazrepo |
| 64 | +
|
| 65 | +# Check specific managers |
| 66 | +fazrepo check --only npm,bun |
| 67 | +
|
| 68 | +# Detailed output with paths |
| 69 | +fazrepo check --detailed |
| 70 | +
|
| 71 | +# List supported managers |
| 72 | +fazrepo list |
| 73 | +``` |
| 74 | + |
| 75 | +## π οΈ Troubleshooting |
| 76 | + |
| 77 | +### "fazrepo is not recognized as an internal or external command" |
| 78 | + |
| 79 | +**Solution 1: Restart your terminal** |
| 80 | +After installation, restart PowerShell/CMD to refresh the PATH. |
| 81 | + |
| 82 | +**Solution 2: Add to PATH manually** |
| 83 | +```powershell |
| 84 | +$env:PATH += ";$env:USERPROFILE\bin" |
| 85 | +``` |
| 86 | + |
| 87 | +**Solution 3: Use full path** |
| 88 | +```powershell |
| 89 | +& "$env:USERPROFILE\bin\fazrepo.exe" check |
| 90 | +``` |
| 91 | + |
| 92 | +### Permission Issues |
| 93 | + |
| 94 | +If you get permission errors: |
| 95 | + |
| 96 | +```powershell |
| 97 | +# Run PowerShell as Administrator, then: |
| 98 | +Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser |
| 99 | +``` |
| 100 | + |
| 101 | +### Antivirus False Positives |
| 102 | + |
| 103 | +Some antivirus software may flag the binary. This is common with new executables. You can: |
| 104 | +1. Add an exception for fazrepo.exe |
| 105 | +2. Install from source instead |
| 106 | +3. Check the file hash against releases |
| 107 | + |
| 108 | +### Package Managers Not Detected |
| 109 | + |
| 110 | +**Common causes:** |
| 111 | +- Package manager not in PATH |
| 112 | +- Using PowerShell ISE (use regular PowerShell) |
| 113 | +- Package manager installed via installer that doesn't add to PATH |
| 114 | + |
| 115 | +**Solutions:** |
| 116 | +```powershell |
| 117 | +# Check your PATH |
| 118 | +$env:PATH -split ';' |
| 119 | +
|
| 120 | +# Find npm location |
| 121 | +where.exe npm |
| 122 | +
|
| 123 | +# Add Node.js to PATH if needed |
| 124 | +$env:PATH += ";C:\Program Files\nodejs" |
| 125 | +``` |
| 126 | + |
| 127 | +## π― Windows-Specific Features |
| 128 | + |
| 129 | +### Command Extensions |
| 130 | + |
| 131 | +fazrepo automatically tries multiple command variants: |
| 132 | +- `npm.cmd` (primary) |
| 133 | +- `npm.exe` (fallback) |
| 134 | +- `npm` (final fallback) |
| 135 | + |
| 136 | +### Path Handling |
| 137 | + |
| 138 | +- Uses Windows path separators automatically |
| 139 | +- Supports both forward and backward slashes |
| 140 | +- Handles spaces in paths correctly |
| 141 | + |
| 142 | +### Environment Variables |
| 143 | + |
| 144 | +Works with Windows environment variables: |
| 145 | +- `%USERPROFILE%` for user directory |
| 146 | +- `%PATH%` for executable search |
| 147 | +- `%TEMP%` for temporary files |
| 148 | + |
| 149 | +## π¦ Development on Windows |
| 150 | + |
| 151 | +### Building from Source |
| 152 | + |
| 153 | +```powershell |
| 154 | +# Install Rust |
| 155 | +winget install --id Rust.Rustup |
| 156 | +
|
| 157 | +# Clone and build |
| 158 | +git clone https://github.com/avadakedavra-wp/fazrepo.git |
| 159 | +cd fazrepo |
| 160 | +cargo build --release |
| 161 | +``` |
| 162 | + |
| 163 | +### Cross-compilation |
| 164 | + |
| 165 | +```powershell |
| 166 | +# Add Windows targets |
| 167 | +rustup target add x86_64-pc-windows-msvc |
| 168 | +rustup target add aarch64-pc-windows-msvc |
| 169 | +
|
| 170 | +# Build for Windows |
| 171 | +cargo build --release --target x86_64-pc-windows-msvc |
| 172 | +``` |
| 173 | + |
| 174 | +### Testing |
| 175 | + |
| 176 | +```powershell |
| 177 | +# Run tests |
| 178 | +cargo test |
| 179 | +
|
| 180 | +# Test Windows-specific functionality |
| 181 | +.\scripts\test-release.sh # In Git Bash |
| 182 | +``` |
| 183 | + |
| 184 | +## π Integration |
| 185 | + |
| 186 | +### PowerShell Profile |
| 187 | + |
| 188 | +Add fazrepo to your PowerShell profile: |
| 189 | + |
| 190 | +```powershell |
| 191 | +# Edit profile |
| 192 | +notepad $PROFILE |
| 193 | +
|
| 194 | +# Add these lines: |
| 195 | +function Check-PackageManagers { fazrepo check } |
| 196 | +Set-Alias -Name pm -Value Check-PackageManagers |
| 197 | +``` |
| 198 | + |
| 199 | +### Batch Scripts |
| 200 | + |
| 201 | +Create a batch file for convenience: |
| 202 | + |
| 203 | +```batch |
| 204 | +@echo off |
| 205 | +fazrepo %* |
| 206 | +``` |
| 207 | + |
| 208 | +### Chocolatey (Future) |
| 209 | + |
| 210 | +We're working on Chocolatey package support: |
| 211 | + |
| 212 | +```powershell |
| 213 | +# Coming soon: |
| 214 | +choco install fazrepo |
| 215 | +``` |
| 216 | + |
| 217 | +## π Windows Requirements |
| 218 | + |
| 219 | +- **OS**: Windows 10 or later |
| 220 | +- **Architecture**: x64 (ARM64 support available) |
| 221 | +- **Dependencies**: None (statically linked) |
| 222 | +- **Permissions**: User-level (no admin required) |
| 223 | + |
| 224 | +## π Success Verification |
| 225 | + |
| 226 | +After installation, verify everything works: |
| 227 | + |
| 228 | +```powershell |
| 229 | +# Check version |
| 230 | +fazrepo --version |
| 231 | +
|
| 232 | +# Test functionality |
| 233 | +fazrepo check |
| 234 | +
|
| 235 | +# Expected output: |
| 236 | +# π Checking package manager versions... |
| 237 | +# |
| 238 | +# β
npm 10.9.0 (C:\Program Files\nodejs\npm.cmd) |
| 239 | +# β yarn not installed |
| 240 | +# β
pnpm 9.13.2 (C:\Users\...\AppData\Roaming\npm\pnpm.cmd) |
| 241 | +# β
bun 1.1.38 (C:\Users\...\.bun\bin\bun.exe) |
| 242 | +``` |
| 243 | + |
| 244 | +## π‘ Tips for Windows Users |
| 245 | + |
| 246 | +1. **Use PowerShell** instead of Command Prompt for better experience |
| 247 | +2. **Install Windows Terminal** for better console experience |
| 248 | +3. **Enable Developer Mode** for symlink support |
| 249 | +4. **Use winget** for installing development tools |
| 250 | +5. **Consider WSL2** for Linux-like development experience |
| 251 | + |
| 252 | +Your fazrepo CLI is now ready for Windows! π― |
0 commit comments