Skip to content

Commit

Permalink
fix(website): help page and ffcli arg/flags ordering (#622)
Browse files Browse the repository at this point in the history
  • Loading branch information
tbruyelle authored and moul committed Mar 28, 2023
1 parent ec3f170 commit 57e9c33
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions gnoland/website/static/js/realm_help.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,32 +55,34 @@ function updateCommand(x) {
"-pkgpath", shq(realmPath), "-func", shq(funcName),
"-gas-fee", "1000000ugnot", "-gas-wanted", "2000000",
"-send", shq(""),
"-broadcast", "-chainid", shq(chainid), myAddr];
"-broadcast", "-chainid", shq(chainid)];
vals.forEach(function(arg) {
args.push("-args");
args.push(shq(arg));
});
args.push("-remote", shq(remote));
args.push(myAddr);
var command = args.join(" ");
shell.append(u("<span>").text(command)).append(u("<br>")).append(u("<br>"));

// or...
shell.append(u("<span>").text("### FULL SECURITY WITH AIRGAP ###")).append(u("<br>"));

// command 0: query account info.
var args = ["gnokey", "query", "auth/accounts/" + myAddr, "-remote", shq(remote)];
var args = ["gnokey", "query", "-remote", shq(remote), "auth/accounts/" + myAddr];
var command = args.join(" ");
shell.append(u("<span>").text(command)).append(u("<br>"));

// command 1: construct tx.
var args = ["gnokey", "maketx", "call",
"-pkgpath", shq(realmPath), "-func", shq(funcName),
"-gas-fee", "1000000ugnot", "-gas-wanted", "2000000",
"-send", shq(""), myAddr];
"-send", shq("")];
vals.forEach(function(arg) {
args.push("-args");
args.push(shq(arg));
});
args.push(myAddr)
var command = args.join(" ");
command = command + " > unsigned.tx";
shell.append(u("<span>").text(command)).append(u("<br>"));
Expand All @@ -95,7 +97,7 @@ function updateCommand(x) {
shell.append(u("<span>").text(command)).append(u("<br>"));

// command 3: broadcast tx.
var args = ["gnokey", "broadcast", "signed.tx", "-remote", shq(remote)];
var args = ["gnokey", "broadcast", "-remote", shq(remote), "signed.tx"];
var command = args.join(" ");
command = command;
shell.append(u("<span>").text(command)).append(u("<br>"));
Expand Down

0 comments on commit 57e9c33

Please sign in to comment.