Merge pull request #1134 from urbit/philip/boot-args

Provide default for -e for galaxies
This commit is contained in:
Philip Monk 2019-01-11 17:32:31 -08:00 committed by GitHub
commit d10812b2cb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 6 additions and 14 deletions

View File

@ -606,7 +606,7 @@
c3_c* raf_c; // -r, raft flotilla
c3_o has; // -S, Skip battery hashes
c3_o git; // -s, pill url from arvo git hash
c3_o etn; // -t, use snapshot exclusively to boot
c3_o etn; // -t, trust snapshot for pre-boot
c3_c* url_c; // -u, pill url
c3_o vno; // -V, replay without reboots
c3_o veb; // -v, verbose (inverse of -q)

View File

@ -328,7 +328,7 @@ u3_dawn_vent(u3_noun seed)
//
c3_c* url_c = ( 0 != u3_Host.ops_u.eth_c ) ?
u3_Host.ops_u.eth_c :
"https://ropsten.infura.io/v3/196a7f37c7d54211b4a07904ec73ad87";
"https://mainnet.infura.io/v3/196a7f37c7d54211b4a07904ec73ad87";
// pin block number
//

View File

@ -218,18 +218,6 @@ _main_getopt(c3_i argc, c3_c** argv)
c3_t imp_t = ( (0 != u3_Host.ops_u.who_c) && (4 == strlen(u3_Host.ops_u.who_c)) );
if ( u3_Host.ops_u.ets_c == 0 && c3y == u3_Host.ops_u.etn ) {
fprintf(stderr, "can't trust Ethereum snapshot without specifying "
"snapshot with -E\n");
return c3n;
}
if ( (0 == u3_Host.ops_u.fak_c) && (0 == u3_Host.ops_u.eth_c) && imp_t ) {
fprintf(stderr, "can't create a new galaxy without specifying "
"the Ethereum gateway with -e\n");
return c3n;
}
if ( u3_Host.ops_u.gen_c != 0 && u3_Host.ops_u.nuu == c3n ) {
fprintf(stderr, "-G only makes sense when bootstrapping a new instance\n");
return c3n;
@ -283,6 +271,10 @@ _main_getopt(c3_i argc, c3_c** argv)
return c3n;
}
if ( u3_Host.ops_u.eth_c == 0 && imp_t ) {
u3_Host.ops_u.eth_c = "http://eth-mainnet.urbit.org:8545";
}
if ( u3_Host.ops_u.sap_c == 0 && u3_Host.ops_u.can == c3n ) {
u3_Host.ops_u.sap_c =