Albirew/nyaa-pantsu
Archivé
1
0
Bifurcation 0

Merge branch 'master' into travis-auto-deps

Cette révision appartient à :
Eliot Whalan 2017-05-07 20:17:28 +10:00 révisé par GitHub
révision 4cf64f259e
2 fichiers modifiés avec 5 ajouts et 6 suppressions

Voir le fichier

@ -1,16 +1,14 @@
language: go
go:
- 1.x
before_install:
- sudo apt-get install gcc-mingw-w64 gcc-mingw-w64-i686 gcc-mingw-w64-x86-64 binutils-mingw-w64-i686 binutils-mingw-w64-x86-64
install:
- go get github.com/tcnksm/ghr
- go get github.com/axw/gocov/gocov
- go get github.com/karalabe/xgo
- mkdir dist
script:
# Downloads deps automatically. No need to add manually.
- go list -f '{{.Deps}}' | tr "[" " " | tr "]" " " | xargs go list -e -f '{{if not .Standard}}{{.ImportPath}}{{end}}' | grep -v 'github.com/ewhal/nyaa' | xargs go get -v
- go build
- cd dist
- xgo github.com/ewhal/nyaa
- ./package.sh
- ghr --username ewhal --token $GITHUB_TOKEN --replace --prerelease --debug pre-release dist/

Voir le fichier

@ -7,6 +7,7 @@ version=$(git describe --tags)
declare -a OSes
OSes[0]='linux;x86_64-linux-gnu-gcc'
OSes[1]='windows;x86_64-w64-mingw32-gcc'
mkdir dist
for i in "${OSes[@]}"; do
arr=(${i//;/ })
@ -16,5 +17,5 @@ for i in "${OSes[@]}"; do
echo -e "\nBuilding $os..."
echo GOOS=$os GOARCH=amd64 CC=$cc CGO_ENABLED=1 go build -v
GOOS=$os GOARCH=amd64 CC=$cc CGO_ENABLED=1 go build -v
zip -9 -q nyaa-${version}_${os}_amd64.zip os css js *.md *.html nyaa nyaa.exe
zip -9 -q dist/nyaa-${version}_${os}_amd64.zip os css js *.md *.html nyaa nyaa.exe
done