Arm64 build (#449)

* Build for arm64

* Build CLI for arm64

* Fix test
This commit is contained in:
Sung Won Cho 2020-04-24 18:44:43 +10:00 committed by GitHub
commit cabe02aa71
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 7 additions and 3 deletions

View file

@ -70,6 +70,7 @@ uname_arch() {
arch=$(uname -m)
case $arch in
x86_64) arch="amd64" ;;
aarch64) arch="arm64" ;;
x86) arch="386" ;;
i686) arch="386" ;;
i386) arch="386" ;;

View file

@ -112,6 +112,7 @@ if [ -z "$GOOS" ] && [ -z "$GOARCH" ]; then
cp -R "$projectDir" "$goPathBasedir"
build linux amd64
build linux arm64
build darwin amd64
build windows amd64
else

View file

@ -64,3 +64,4 @@ build() {
}
build linux amd64
build linux arm64

View file

@ -3,13 +3,14 @@
# appropriate env vars.
set -eux
dir=$(dirname "${BASH_SOURCE[0]}")
dir=$(realpath "$(dirname "${BASH_SOURCE[0]}")")
pushd "$dir/../../pkg/server"
export DNOTE_TEST_EMAIL_TEMPLATE_DIR="$dir/../../pkg/server/mailer/templates/src"
emailTemplateDir=$(realpath "$dir/../../pkg/server/mailer/templates/src")
export DNOTE_TEST_EMAIL_TEMPLATE_DIR="$emailTemplateDir"
function run_test {
go test ./... -cover -p 1
go test ./... -cover -p 1
}
if [ "${WATCH-false}" == true ]; then