diff options
Diffstat (limited to 'app/src/main/java/org/pacien/tincapp/commands/Tinc.kt')
-rw-r--r-- | app/src/main/java/org/pacien/tincapp/commands/Tinc.kt | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/app/src/main/java/org/pacien/tincapp/commands/Tinc.kt b/app/src/main/java/org/pacien/tincapp/commands/Tinc.kt index 883430c..b9860fb 100644 --- a/app/src/main/java/org/pacien/tincapp/commands/Tinc.kt +++ b/app/src/main/java/org/pacien/tincapp/commands/Tinc.kt | |||
@@ -53,7 +53,7 @@ object Tinc { | |||
53 | 53 | ||
54 | fun info(netName: String, node: String): CompletableFuture<String> = | 54 | fun info(netName: String, node: String): CompletableFuture<String> = |
55 | Executor.call(newCommand(netName).withArguments("info", node)) | 55 | Executor.call(newCommand(netName).withArguments("info", node)) |
56 | .thenApply<String> { it.joinToString("\n") } | 56 | .thenApply { it.joinToString("\n") } |
57 | 57 | ||
58 | fun init(netName: String, nodeName: String): CompletableFuture<String> = | 58 | fun init(netName: String, nodeName: String): CompletableFuture<String> = |
59 | if (netName.isBlank()) | 59 | if (netName.isBlank()) |
@@ -62,7 +62,7 @@ object Tinc { | |||
62 | Executor.call(Command(AppPaths.tinc().absolutePath) | 62 | Executor.call(Command(AppPaths.tinc().absolutePath) |
63 | .withOption("config", AppPaths.confDir(netName).absolutePath) | 63 | .withOption("config", AppPaths.confDir(netName).absolutePath) |
64 | .withArguments("init", nodeName)) | 64 | .withArguments("init", nodeName)) |
65 | .thenApply<String> { it.joinToString("\n") } | 65 | .thenApply { it.joinToString("\n") } |
66 | 66 | ||
67 | fun join(netName: String, invitationUrl: String): CompletableFuture<String> = | 67 | fun join(netName: String, invitationUrl: String): CompletableFuture<String> = |
68 | if (netName.isBlank()) | 68 | if (netName.isBlank()) |
@@ -71,7 +71,7 @@ object Tinc { | |||
71 | Executor.call(Command(AppPaths.tinc().absolutePath) | 71 | Executor.call(Command(AppPaths.tinc().absolutePath) |
72 | .withOption("config", AppPaths.confDir(netName).absolutePath) | 72 | .withOption("config", AppPaths.confDir(netName).absolutePath) |
73 | .withArguments("join", invitationUrl)) | 73 | .withArguments("join", invitationUrl)) |
74 | .thenApply<String> { it.joinToString("\n") } | 74 | .thenApply { it.joinToString("\n") } |
75 | 75 | ||
76 | fun log(netName: String, level: Int? = null): Process = | 76 | fun log(netName: String, level: Int? = null): Process = |
77 | Executor.run(newCommand(netName) | 77 | Executor.run(newCommand(netName) |