Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
新注册的用户请输入邮箱并保存,随后登录邮箱激活账号。后续可直接使用邮箱登录!
Open sidebar
白 鹿
contract-sdk-go
Commits
90b3f8d5
Commit
90b3f8d5
authored
Feb 16, 2023
by
天乐 韩
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: Modify build.sh
--story=0
parent
5a3b0357
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
9 deletions
+7
-9
build.sh
build.sh
+7
-9
No files found.
build.sh
View file @
90b3f8d5
#!/bin/bash
#!/bin/bash
DIR
=
"/home/contract_docker_go/target/release/"
contractName
=
$1
if
[[
!
-n
$contractName
]]
;
then
if
[
!
-d
$DIR
]
;
then
echo
"contractName is empty. use as: ./build.sh contractName"
mkdir
-p
$DIR
exit
1
fi
fi
echo
"please input zip file name (no suffix): "
go build
-ldflags
=
"-s -w"
-o
$contractName
read
zip_file
go build
-ldflags
=
"-s -w"
-o
$zip_file
7z a
$zip_file
$zip_file
7z a
$contractName
$contractName
mv
$zip_file
.7z
$DIR
rm
-f
$contractName
\ No newline at end of file
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment