Last active
July 29, 2016 10:37
-
-
Save karaaie/b0065963bfbae07dfe7e to your computer and use it in GitHub Desktop.
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
try { | |
#Get current dir | |
$tools = split-path $MyInvocation.MyCommand.Path (1) | |
#Get parent dir | |
$parentDir = split-path -parent $tools (2) | |
#get HelloWorldSite source dir $source = join-path $parentDir "source/*" (3) | |
#get location of the installtion file | |
$installFile = join-path $parentDir "installSite.ps1" (4) | |
Invoke-Expression "$installFile -Sourcefiles $source" (5) | |
Write-ChocolateySuccess 'HelloWorldSite' (6) | |
} catch { | |
Write-Host $_.Exception.Message (7) | |
Write-Host $_.Exception (8) | |
Write-ChocolateyFailure 'HelloWorldSite' (9) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment