Skip to content

Commit 51938df

Browse files
committed
Minor fixes for CLI Tinfoil/Awoo Net-install mode.
1 parent 3690c63 commit 51938df

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/main/java/nsusbloader/cli/TinfoilNet.java

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
// TODO: Add 'don't serve requests' option
2828
public class TinfoilNet {
2929

30-
private String[] arguments;
30+
private final String[] arguments;
3131

3232
private String nsIp;
3333

@@ -43,7 +43,7 @@ public class TinfoilNet {
4343
this.arguments = arguments;
4444
checkArguments();
4545
parseNsIP();
46-
parseHostIPAndExtras();
46+
parseHostSettings();
4747
parseFilesArguments();
4848
runTinfoilNetBackend();
4949
}
@@ -73,8 +73,8 @@ private void checkArguments() throws IncorrectSetupException{
7373
private boolean isHelpDirective(String argument){
7474
return argument.equals("help");
7575
}
76-
private void showHelp(){
77-
System.out.println("Usage:\n"
76+
private void showHelp() throws IncorrectSetupException{
77+
throw new IncorrectSetupException("Usage:\n"
7878
+ "\tns-usbloader -n nsip=<arg1> [hostip=<arg2>] FILE1 ...\n"
7979
+ "\tns-usbloader --tfn nsip=<arg1> [hostip=<arg2>] FILE1 ..."
8080
+ "\n\nOptions:"
@@ -96,7 +96,7 @@ private void parseNsIP() throws IncorrectSetupException{
9696
"Try 'ns-usbloader -n help' for more information.");
9797
}
9898

99-
private void parseHostIPAndExtras(){
99+
private void parseHostSettings(){
100100
String argument2 = arguments[1];
101101

102102
if (! argument2.startsWith("hostip="))

0 commit comments

Comments
 (0)