Skip to content

Instantly share code, notes, and snippets.

@parzibyte
Last active December 26, 2021 22:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save parzibyte/030e525eba5c106697174e89a600e57c to your computer and use it in GitHub Desktop.
Save parzibyte/030e525eba5c106697174e89a600e57c to your computer and use it in GitHub Desktop.
GO=go
GOFMT=gofmt
OUTPUT_FILE=control_escuela
.DEFAULT_GOAL=run
run:
# Formateando
${GOFMT} -w .
# Compilando
${GO} build -o ${OUTPUT_FILE}.exe -tags desarrollo
# Ejecutando
./${OUTPUT_FILE}
prod:
# Si vas a compilar para 32 bits, probablemente quieras:
# SET PATH=C:\Go32\go\bin;%PATH% && SET GOROOT=C:\Go32\go\
# Formateando
${GOFMT} -w .
# Compilando
${GO} build -o ${OUTPUT_FILE}_prod_64.exe -tags produccion -ldflags "-H windowsgui"
prod_32:
# Si vas a compilar para 32 bits, probablemente quieras:
# SET PATH=C:\Go32\go\bin;%PATH% && SET GOROOT=C:\Go32\go\
# Formateando
${GOFMT} -w .
# Compilando
${GO} build -o ${OUTPUT_FILE}_prod_32.exe -tags produccion -ldflags "-H windowsgui"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment