Skip to content

Commit

Permalink
build: update build configurations in Makefile
Browse files Browse the repository at this point in the history
  • Loading branch information
hiago-balbino committed Oct 4, 2023
1 parent db82749 commit b3a25c9
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.PHONY: all help setup fmt lint vulncheck tests cover sonarqube-up sonarqube-down sonarqube-analysis build-web run-web compose-ps compose-up compose-down doc clean
.PHONY: all help setup fmt lint vulncheck tests cover sonarqube-up sonarqube-down sonarqube-analysis build-ctl build-web run-ctl run-web compose-ps compose-up compose-down doc clean

APP_NAME=random_luck

Expand Down Expand Up @@ -47,10 +47,18 @@ sonarqube-down:
sonarqube-analysis: tests
${SONAR_BINARY} -Dsonar.host.url=${SONAR_HOST} -Dsonar.login=${SONAR_LOGIN} -Dsonar.password=${SONAR_PASSWORD}

## build-ctl: create an executable of the command tool
build-ctl:
go build -o ${APP_NAME} cmd/luckctl/main.go

## build-web: create an executable of the web application
build-web:
go build -o ${APP_NAME} cmd/luckweb/main.go

## run-ctl: build project and run the command tool using the built binary
run-ctl: build-ctl
./${APP_NAME} --games=${GAMES} --numbers=${NUMBERS}

## run-web: build project and run the Web using the built binary
run-web: build-web
./${APP_NAME}
Expand Down

0 comments on commit b3a25c9

Please sign in to comment.