Browse Source

fix(cli): CLI can't run in CI envs

For now just downgrade desktop check to warning. Decided
against CI flag since that requires more setup for all
Gabriel Horner 6 days ago
parent
commit
a4d3bd4d93
1 changed files with 3 additions and 4 deletions
  1. 3 4
      deps/cli/src/logseq/cli.cljs

+ 3 - 4
deps/cli/src/logseq/cli.cljs

@@ -116,15 +116,14 @@
     :spec default-spec
     :fn default-command}])
 
-(defn- error-if-db-version-not-installed
+(defn- warn-if-db-version-not-installed
   []
   (when-not (fs/existsSync (cli-common-graph/get-db-graphs-dir))
-    (println "Error: The database version's desktop app is not installed. Please install per https://github.com/logseq/logseq/#-database-version.")
-    (js/process.exit 1)))
+    (println "[WARN] The database version's desktop app is not installed. Please install per https://github.com/logseq/logseq/#-database-version.")))
 
 (defn ^:api -main [& args]
   (when-not (contains? #{nil "-h" "--help"} (first args))
-    (error-if-db-version-not-installed))
+    (warn-if-db-version-not-installed))
   (try
     (cli/dispatch table
                   args