mirror of
https://github.com/ilyakooo0/urbit.git
synced 2024-12-02 15:13:25 +03:00
Allow optional pier directory argument with -w -t
This commit is contained in:
parent
38456edc4e
commit
2830d2cddb
@ -95,7 +95,6 @@ _main_getopt(c3_i argc, c3_c** argv)
|
||||
case 'w': {
|
||||
u3_Host.ops_u.who_c = _main_presig(optarg);
|
||||
u3_Host.ops_u.nuu = c3y;
|
||||
u3_Host.dir_c = strdup(1 + u3_Host.ops_u.who_c);
|
||||
break;
|
||||
}
|
||||
case 't': {
|
||||
@ -198,6 +197,10 @@ _main_getopt(c3_i argc, c3_c** argv)
|
||||
}
|
||||
}
|
||||
|
||||
if ( argc != (optind + 1) && u3_Host.ops_u.who_c != 0 ) {
|
||||
u3_Host.dir_c = strdup(1 + u3_Host.ops_u.who_c);
|
||||
}
|
||||
|
||||
if ( argc != (optind + 1) ) {
|
||||
return u3_Host.dir_c ? c3y : c3n;
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user