Skip to content
This repository has been archived by the owner on Jan 29, 2025. It is now read-only.

Commit

Permalink
Update enforcer version number
Browse files Browse the repository at this point in the history
  • Loading branch information
CryptAxe committed Jan 10, 2025
1 parent 9f4111d commit ab63526
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
6 changes: 3 additions & 3 deletions cusf_launcher/script/main_window.gd
Original file line number Diff line number Diff line change
Expand Up @@ -375,11 +375,11 @@ func start_l1() -> void:
var enforcer_bin_path : String = ""
match OS.get_name():
"Linux":
enforcer_bin_path = str(downloads_dir, "/bip300301-enforcer-latest-x86_64-unknown-linux-gnu/bip300301_enforcer-0.1.2-x86_64-unknown-linux-gnu")
enforcer_bin_path = str(downloads_dir, "/bip300301-enforcer-latest-x86_64-unknown-linux-gnu/bip300301_enforcer-0.1.4-x86_64-unknown-linux-gnu")
"Windows":
enforcer_bin_path = str(downloads_dir, "/bip300301-enforcer-latest-x86_64-pc-windows-gnu.exe/bip300301_enforcer-0.1.2-x86_64-pc-windows-gnu.exe")
enforcer_bin_path = str(downloads_dir, "/bip300301-enforcer-latest-x86_64-pc-windows-gnu.exe/bip300301_enforcer-0.1.4-x86_64-pc-windows-gnu.exe")
"macOS":
enforcer_bin_path = str(downloads_dir, "/bip300301-enforcer-latest-x86_64-apple-darwin/bip300301_enforcer-0.1.2-x86_64-apple-darwin")
enforcer_bin_path = str(downloads_dir, "/bip300301-enforcer-latest-x86_64-apple-darwin/bip300301_enforcer-0.1.4-x86_64-apple-darwin")

# Start bip300-301 enforcer
ret = OS.create_process(enforcer_bin_path, ["--node-rpc-addr=localhost:38332", "--node-rpc-user=user", "--node-rpc-pass=password", "--node-zmq-addr-sequence=tcp://localhost:29000", "--enable-wallet"])
Expand Down
10 changes: 5 additions & 5 deletions cusf_launcher/script/resource_downloader.gd
Original file line number Diff line number Diff line change
Expand Up @@ -189,15 +189,15 @@ func have_grpcurl() -> bool:
func have_enforcer() -> bool:
match OS.get_name():
"Linux":
if !FileAccess.file_exists("user://downloads/l1/bip300301-enforcer-latest-x86_64-unknown-linux-gnu/bip300301_enforcer-0.1.2-x86_64-unknown-linux-gnu"):
if !FileAccess.file_exists("user://downloads/l1/bip300301-enforcer-latest-x86_64-unknown-linux-gnu/bip300301_enforcer-0.1.4-x86_64-unknown-linux-gnu"):
return false
"Windows":
# TODO the folder name has .exe which is probably an accident.
# Maybe an issue with the github actions?
if !FileAccess.file_exists("user://downloads/l1/bip300301-enforcer-latest-x86_64-pc-windows-gnu.exe/bip300301_enforcer-0.1.2-x86_64-pc-windows-gnu.exe"):
if !FileAccess.file_exists("user://downloads/l1/bip300301-enforcer-latest-x86_64-pc-windows-gnu.exe/bip300301_enforcer-0.1.4-x86_64-pc-windows-gnu.exe"):
return false
"macOS":
if !FileAccess.file_exists("user://downloads/l1/bip300301-enforcer-latest-x86_64-apple-darwin/bip300301_enforcer-0.1.2-x86_64-apple-darwin"):
if !FileAccess.file_exists("user://downloads/l1/bip300301-enforcer-latest-x86_64-apple-darwin/bip300301_enforcer-0.1.4-x86_64-apple-darwin"):
return false

resource_enforcer_ready.emit()
Expand Down Expand Up @@ -383,15 +383,15 @@ func extract_enforcer() -> void:

# Make executable for linux
if OS.get_name() == "Linux":
ret = OS.execute("chmod", ["+x", str(downloads_dir, "/bip300301-enforcer-latest-x86_64-unknown-linux-gnu/bip300301_enforcer-0.1.2-x86_64-unknown-linux-gnu")])
ret = OS.execute("chmod", ["+x", str(downloads_dir, "/bip300301-enforcer-latest-x86_64-unknown-linux-gnu/bip300301_enforcer-0.1.4-x86_64-unknown-linux-gnu")])
if ret != OK:
printerr("Failed to mark enforcer executable")
return

resource_enforcer_ready.emit()

if OS.get_name() == "macOS":
ret = OS.execute("chmod", ["+x", str(downloads_dir, "/bip300301-enforcer-latest-x86_64-apple-darwin/bip300301_enforcer-0.1.2-x86_64-apple-darwin")])
ret = OS.execute("chmod", ["+x", str(downloads_dir, "/bip300301-enforcer-latest-x86_64-apple-darwin/bip300301_enforcer-0.1.4-x86_64-apple-darwin")])
if ret != OK:
printerr("Failed to mark enforcer executable")
return
Expand Down

0 comments on commit ab63526

Please sign in to comment.