mirror of
https://github.com/mitb-archive/filebot
synced 2024-12-23 00:08:51 -05:00
Experiment with PGP signed messages
This commit is contained in:
parent
f0a59d51f0
commit
f468be3a62
@ -113,22 +113,19 @@ public class Main {
|
||||
|
||||
// CLI mode => run command-line interface and then exit
|
||||
if (args.runCLI()) {
|
||||
int status = new ArgumentProcessor().run(args);
|
||||
System.exit(status);
|
||||
}
|
||||
|
||||
// CLI behaviour for console interactive usage
|
||||
if (isHeadless() || System.console() != null) {
|
||||
// print license to console if we have an interactive console
|
||||
// just import and print license when running with --license option
|
||||
if (configureLicense(args)) {
|
||||
System.exit(0);
|
||||
}
|
||||
|
||||
// exit with man page if we can't launch the GUI
|
||||
if (isHeadless()) {
|
||||
log.info(String.format("%s / %s (headless)%n%n%s", getApplicationIdentifier(), getJavaRuntimeIdentifier(), args.usage()));
|
||||
System.exit(1);
|
||||
}
|
||||
int status = new ArgumentProcessor().run(args);
|
||||
System.exit(status);
|
||||
}
|
||||
|
||||
// just print help page if we can't run any command and also can't start the GUI
|
||||
if (isHeadless()) {
|
||||
log.info(String.format("%s / %s (headless)%n%n%s", getApplicationIdentifier(), getJavaRuntimeIdentifier(), args.usage()));
|
||||
System.exit(1);
|
||||
}
|
||||
|
||||
// GUI mode => start user interface
|
||||
|
@ -1,5 +1,6 @@
|
||||
package net.filebot.cli;
|
||||
|
||||
import static java.awt.GraphicsEnvironment.*;
|
||||
import static java.util.Arrays.*;
|
||||
import static java.util.Collections.*;
|
||||
import static net.filebot.Logging.*;
|
||||
@ -155,7 +156,7 @@ public class ArgumentBean {
|
||||
public List<String> arguments = new ArrayList<String>();
|
||||
|
||||
public boolean runCLI() {
|
||||
return rename || getSubtitles || check || list || mediaInfo || revert || extract || script != null;
|
||||
return rename || getSubtitles || check || list || mediaInfo || revert || extract || script != null || (license != null && isHeadless());
|
||||
}
|
||||
|
||||
public boolean isInteractive() {
|
||||
|
Loading…
Reference in New Issue
Block a user