Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Windows Go Shortcuts
@echo off
setlocal EnableDelayedExpansion
for /f %%A in ('forfiles /s /m *.go /c "cmd /c echo @relpath"') do SET "files=!files! %%~A"
go build %files%
ENDLOCAL
@echo off
setlocal EnableDelayedExpansion
for /f %%A in ('forfiles /s /m *.go /c "cmd /c echo @relpath"') do SET "files=!files! %%~A"
go run %files%
ENDLOCAL
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment