Files
claudetools/clients/dataforth/scripts/check-junction.ps1
Mike Swanson 5cbd49ce24 Reorganize repo: compartmentalize scripts by client/project
Move 150+ scripts from root and scripts/ into client/project directories:
- clients/dataforth/scripts/ (110 files: AD2, sync, SSH, DB, DOS scripts)
- clients/bg-builders/scripts/ (14 files: Lesley mgmt, Exchange, termination)
- clients/internal-infrastructure/scripts/ (10 files: GDAP, Gitea, backups)
- projects/msp-tools/scripts/ (9 files: CIPP, MSP onboarding, Datto)
- projects/gururmm-agent/scripts/ (3 files: API test, JWT, record counts)
- clients/glaztech/scripts/ (1 file: CentraStage removal)

Also reorganized:
- VPN scripts → infrastructure/vpn-configs/
- Retrieved API/JS files → api/
- Forum posts → projects/community-forum/forum-posts/
- SSH docs → clients/internal-infrastructure/docs/
- NWTOC/CTONW docs → projects/wrightstown-smarthome/docs/
- ACG website files → projects/internal/acg-website-2025/
- Dataforth docs → clients/dataforth/docs/
- schema-retrieved.sql → docs/database/

Deleted 24 tmp_*.ps1 one-off debug scripts (preserved in git history).
Root reduced from 220+ files to 62 items (docs + directories only).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-20 17:15:07 -07:00

51 lines
2.2 KiB
PowerShell

$password = ConvertTo-SecureString 'Paper123!@#' -AsPlainText -Force
$cred = New-Object System.Management.Automation.PSCredential('INTRANET\sysadmin', $password)
Write-Host "================================================" -ForegroundColor Cyan
Write-Host "Checking COMMON vs _COMMON on AD2" -ForegroundColor Cyan
Write-Host "================================================" -ForegroundColor Cyan
Write-Host ""
Invoke-Command -ComputerName 192.168.0.6 -Credential $cred -ScriptBlock {
Write-Host "=== Checking if _COMMON and COMMON are junctioned ===" -ForegroundColor Yellow
Write-Host ""
# Check _COMMON
$underCommon = Get-Item "C:\Shares\test\_COMMON" -Force
Write-Host "_COMMON:" -ForegroundColor Cyan
Write-Host " Type: $($underCommon.Attributes)" -ForegroundColor White
if ($underCommon.LinkType) {
Write-Host " LinkType: $($underCommon.LinkType)" -ForegroundColor Green
Write-Host " Target: $($underCommon.Target)" -ForegroundColor Green
} else {
Write-Host " LinkType: Not a link/junction" -ForegroundColor Yellow
}
Write-Host ""
# Check COMMON
$common = Get-Item "C:\Shares\test\COMMON" -Force
Write-Host "COMMON:" -ForegroundColor Cyan
Write-Host " Type: $($common.Attributes)" -ForegroundColor White
if ($common.LinkType) {
Write-Host " LinkType: $($common.LinkType)" -ForegroundColor Green
Write-Host " Target: $($common.Target)" -ForegroundColor Green
} else {
Write-Host " LinkType: Not a link/junction" -ForegroundColor Yellow
}
Write-Host ""
# Compare file counts
Write-Host "=== File Counts ===" -ForegroundColor Yellow
$underCount = (Get-ChildItem "C:\Shares\test\_COMMON\ProdSW" -File -ErrorAction SilentlyContinue | Measure-Object).Count
$commonCount = (Get-ChildItem "C:\Shares\test\COMMON\ProdSW" -File -ErrorAction SilentlyContinue | Measure-Object).Count
Write-Host "_COMMON\ProdSW: $underCount files" -ForegroundColor White
Write-Host "COMMON\ProdSW: $commonCount files" -ForegroundColor White
if ($underCount -ne $commonCount) {
Write-Host "WARNING: File counts differ!" -ForegroundColor Red
} else {
Write-Host "File counts match" -ForegroundColor Green
}
}