This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#how to use .\Export-Codebase.ps1 "C:\Path\To\Your\Codebase" "allcodebase.txt" | |
param ( | |
[string]$RootPath, # Parameter 1: Root directory of the codebase | |
[string]$OutputFile # Parameter 2: Output filename | |
) | |
# Check if the root directory exists | |
if (-Not (Test-Path -Path $RootPath)) { | |
Write-Host "Error: The specified root directory does not exist." | |
exit |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
MAX_RETRIES=5 | |
COUNT=0 | |
PACKAGE_NAME=$1 | |
while [ $COUNT -lt $MAX_RETRIES ]; do | |
brew install $PACKAGE_NAME && break | |
COUNT=$((COUNT+1)) |