Skip to content

Commit

Permalink
Merge pull request #4 from lidofinance/verification_script
Browse files Browse the repository at this point in the history
Added install-solido script
  • Loading branch information
Shi-eld authored Dec 5, 2022
2 parents 330293b + 6a9f037 commit 2e01763
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 8 deletions.
14 changes: 7 additions & 7 deletions scripts/install_solido.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,23 +34,23 @@ def install_solido():
# install solido v1
if not os.path.isdir(pathStr + "/solido_v1/"):
outout = os.system(
"git clone --recurse-submodules -b current https://github.com/lidofinance/solido solido_v1"
"git clone --recurse-submodules -b v1.3.6 https://github.com/lidofinance/solido solido_v1"
)
output = os.chdir(pathStr + "/solido_v1/")
outout = os.system("cargo build --release")
output = os.chdir(pathStr + "/solido_v1/")
outout = os.system("cargo build --release")
if os.path.isfile(pathStr + "/solido_v1/target/release/solido"):
os.environ["SOLIDO_V1"] = pathStr + "/solido_v1/target/release/solido"
else:
print("Program not exist: " + pathStr + "/solido_v1/target/release/solido")
output = os.chdir(pathStr)

# install solido v1
# install solido v2
if not os.path.isdir(pathStr + "/solido_v2/"):
outout = os.system(
"git clone --recurse-submodules -b main https://github.com/lidofinance/solido solido_v2"
"git clone --recurse-submodules -b v2.0.0 https://github.com/lidofinance/solido solido_v2"
)
output = os.chdir(pathStr + "/solido_v2/")
outout = os.system("cargo build --release")
output = os.chdir(pathStr + "/solido_v2/")
outout = os.system("cargo build --release")
if os.path.isfile(pathStr + "/solido_v2/target/release/solido"):
os.environ["SOLIDO_V2"] = pathStr + "/solido_v2/target/release/solido"
else:
Expand Down
8 changes: 7 additions & 1 deletion scripts/operation.py
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,11 @@ def get_signer() -> Any:
"--transactions-path", type=str, help='Path to transactions file', required=True
)

current_parser = subparsers.add_parser(
'install-solido',
help='Install solido_v1 and solido_v2 for deploy actions',
)

current_parser = subparsers.add_parser('test', help='`Command for tests`')

args = parser.parse_args()
Expand Down Expand Up @@ -254,6 +259,7 @@ def get_signer() -> Any:
verify_transaction.verify_transactions(ifile)
else:
print("Unknown phase")

elif args.command == "install-solido":
print("Install solido...")
else:
eprint("Unknown command %s" % args.command)

0 comments on commit 2e01763

Please sign in to comment.