Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Package (DEBUG)
- # C:\Windows\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe
- # /t:PACKAGE /p:Configuration=Debug /detailedsummary /nologo "$(ProjectFileName)"
- # $(ProjectDir)
- ############# Get Full Assembly Name ##################################
- # C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe
- # -NoLogo -NonInteractive -ExecutionPolicy Unrestricted -Command "& { GetFullAssemblyName '$(TargetPath)' }"
- # $(TargetDir)
- function GetFullAssemblyName([string]$dllPath){
- Write-Host "$([System.Reflection.AssemblyName]::GetAssemblyName($dllPath).FullName)"
- }
- ############# Copy to GAC ##################################
- # C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe
- # -NoLogo -NonInteractive -ExecutionPolicy Unrestricted -Command "& { CopyToGac '$(TargetPath)' } "
- # $(BinDir)
- function CopyToGac([string]$dllPath){
- $asName = [System.Reflection.AssemblyName]::GetAssemblyName($dllPath).FullName
- Write-Host "Removing $($asName) from GAC"
- GACUTIL /u $asName
- Write-Host "Adding $($dllPath) to GAC"
- GACUTIL /i $dllPath
- iisreset /noforce
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement