1
0
mirror of https://github.com/jhillyerd/inbucket.git synced 2026-01-25 20:45:59 +00:00
Files
go-inbucket/bin/dist-win.ps1
James Hillyerd 5214f30f87 Add Windows config
- Dist building powershell script
- Sample config
- Simple .bat launcher
2012-11-12 20:36:27 -08:00

26 lines
1.6 KiB
PowerShell
Raw Blame History

This file contains invisible Unicode characters
This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# Compile and package inbucket dist for windows
param([Parameter(Mandatory=$true)]$versionLabel)
set DESKTOP ([Environment]::GetFolderPath("Desktop"))
set GOOS $(go env GOOS)
set GOARCH $(go env GOARCH)
set distname "inbucket-${versionLabel}-${GOOS}_${GOARCH}"
set distdir "$DESKTOP\$distname"
if (Test-Path $distdir) {
Remove-Item -Force -Recurse $distdir
}
echo "Building $distname..."
md $distdir | Out-Null
go build -o "$distdir/inbucket.exe" -a -v "github.com/jhillyerd/inbucket"
echo "Copying resources..."
Copy-Item LICENSE -Destination "$distdir\LICENSE.txt"
Copy-Item README.md -Destination "$distdir\README.txt"
Copy-Item bin\inbucket.bat -Destination $distdir
Copy-Item etc -Destination $distdir -Recurse
Copy-Item themes -Destination $distdir -Recurse