refactoring

This commit is contained in:
Prashant Gupta 2019-03-27 16:09:54 -07:00
parent 6f98c66210
commit 5a1d59fcad
3 changed files with 42 additions and 2 deletions

3
.gitignore vendored
View File

@ -1 +1,2 @@
vendor/
vendor/
bin/

View File

@ -1,5 +1,28 @@
all: open
build: clean
mkdir -p -v ./bin/amm.app/Contents/Resources
mkdir -p -v ./bin/amm.app/Contents/MacOS
cp ./appInfo/*.plist ./bin/amm.app/Contents/Info.plist
go build -o ./bin/amm.app/Contents/MacOS/amm cmd/main.go
open: build
open ./bin
clean:
rm -rf ./bin
start:
go run cmd/main.go
test:
go test -v -race -failfast ./...
go test -v -race -failfast ./...
vet:
go vet $(shell glide nv)
lint:
go list ./... | grep -v vendor | xargs -L1 golint -set_exit_status
.PHONY: build
.PHONY: clean

16
appInfo/Info.plist Normal file
View File

@ -0,0 +1,16 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleExecutable</key>
<string>amm</string>
<key>CFBundleIconFile</key>
<string>icon.icns</string>
<key>CFBundleIdentifier</key>
<string>com.pg.amm</string>
<key>NSHighResolutionCapable</key>
<true/>
<key>LSUIElement</key>
<true/>
</dict>
</plist>