Created
December 27, 2014 09:09
-
-
Save mscharley/32c387264b5ae24a4522 to your computer and use it in GitHub Desktop.
Open multiple Skype instances (Windows/Powershell)
This file contains 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
$skypePath = (Get-ItemProperty -Path hkcu:\SOFTWARE\Skype\Phone).SkypePath | |
if (!(Test-Path $skypePath -pathType leaf)) { | |
Write-Host "Unable to find Skype for Desktop. Is it installed correctly?" | |
pause | |
exit 1 | |
} | |
$dataPath = "$($env:localappdata)\SkypePortable" | |
$instanceCount = 2 | |
for ($i = 1; $i -le $instanceCount; $i++) { | |
$instanceData = "$($dataPath)\Skype.$($i)" | |
if (!(Test-Path $instanceData -pathType container)) { | |
Write-Host "Creating: $instanceData" | |
New-Item $instanceData -force -itemtype directory | |
} | |
Write-Host "Running Skype instance $i. Data directory: $instanceData" | |
& $skypePath /datapath:"$($instanceData)" /removable /secondary | |
sleep 5 | |
} | |
$null |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment