Skip to content

Commit

Permalink
add make file
Browse files Browse the repository at this point in the history
  • Loading branch information
liweiyi88 committed Jan 14, 2022
1 parent 5a006a4 commit ac957fb
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 0 deletions.
13 changes: 13 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
.PHONY: prepare install release

ARTIFACTS_DIR=artifacts/${VERSION}
GITHUB_USERNAME=liweiyi88

install:
go install

release:
GOOS=windows GOARCH=amd64 go build -o $(ARTIFACTS_DIR)/gosnakego_windows_amd64
GOOS=darwin GOARCH=amd64 go build -o $(ARTIFACTS_DIR)/gosnakego_darwin_amd64
GOOS=linux GOARCH=amd64 go build -o $(ARTIFACTS_DIR)/gosnakego_linux_amd64
ghr -u $(GITHUB_USERNAME) --replace ${VERSION} $(ARTIFACTS_DIR)
11 changes: 11 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,16 @@ A snake game written in Go

![snake](https://user-images.githubusercontent.com/7248260/149492282-6588ead3-954d-42a4-9871-dc08cf833920.gif)

## Installation
### Build yourself
```
$ git clone https://github.com/liweiyi88/gosnakego.git
$ make install
```

## How to play
### Start
```
$ gosnakego
```
Use arrow keys to control the snake, and eat the apple!
File renamed without changes.

0 comments on commit ac957fb

Please sign in to comment.