Skip to content

Commit 72f747b

Browse files
committed
Add build script
1 parent 68e3f69 commit 72f747b

File tree

2 files changed

+19
-1
lines changed

2 files changed

+19
-1
lines changed

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
1-
consul-fs
1+
consul-fs
2+
dist

build.sh

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
#!/usr/bin/env bash
2+
3+
RELEASE=0.1
4+
dist=dist
5+
bin=consul-fs
6+
7+
function build {
8+
GOOS=$1 GOARCH=$2 go build -o $bin
9+
package=$bin-$RELEASE-$1-$2.tar.gz
10+
tar cvzf $package $bin
11+
mv $package $dist
12+
rm $bin
13+
}
14+
15+
mkdir -p $dist
16+
build darwin amd64
17+
build linux amd64

0 commit comments

Comments
 (0)