This is an automated email from the ASF dual-hosted git repository.

bchapuis pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-baremaps.git


The following commit(s) were added to refs/heads/main by this push:
     new 70f6d5f4 Handle no arguments in the init command (#804)
70f6d5f4 is described below

commit 70f6d5f44dfbd228b0bff811de68a4dd60a8b4eb
Author: Bertil Chapuis <[email protected]>
AuthorDate: Mon Nov 20 21:44:07 2023 +0100

    Handle no arguments in the init command (#804)
---
 baremaps-cli/src/main/java/org/apache/baremaps/cli/map/Init.java | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/baremaps-cli/src/main/java/org/apache/baremaps/cli/map/Init.java 
b/baremaps-cli/src/main/java/org/apache/baremaps/cli/map/Init.java
index f1a34284..3c9be06b 100644
--- a/baremaps-cli/src/main/java/org/apache/baremaps/cli/map/Init.java
+++ b/baremaps-cli/src/main/java/org/apache/baremaps/cli/map/Init.java
@@ -50,6 +50,10 @@ public class Init implements Callable<Integer> {
 
   @Override
   public Integer call() throws Exception {
+    if (style == null && tileset == null) {
+      logger.info("No configuration file specified.");
+      return 0;
+    }
     if (style != null) {
       Style styleObject = new Style();
       styleObject.setName("Baremaps");

Reply via email to