boot-clj / boot-clj/boot

Supplying CLI args "as is"

Open
#542 6 comments 0 reactions 0 assignees View on GitHub
Enhancement
Dominant language
Clojure
Stars
1.7k
Forks
178
PR merge metrics
No merged PRs in 30d

Description

This is the followup on #374. Unfortunately, the issue I had is not resolved, because the new functionality seems to break when I provide arguments like `--foo`.

```clojure
(deftask run []
(println "Args passed:" *args*))
```

```sh
$ boot [ run --port 8080 ]
java.lang.Thread.run Thread.java: 745
java.util.concurrent.ThreadPoolExecutor$Worker.run ThreadPoolExecutor.java: 617
java.util.concurrent.ThreadPoolExecutor.runWorker ThreadPoolExecutor.java: 1142
java.util.concurrent.FutureTask.run FutureTask.java: 266
...
clojure.core/binding-conveyor-fn/fn core.clj: 2020
boot.core/boot/fn core.clj: 1030
...
boot.core/construct-tasks core.clj: 981
...
boot.core/construct-tasks core.clj: 988
java.lang.IllegalArgumentException: Unknown option: "--port"
clojure.lang.ExceptionInfo: Unknown option: "--port"
file: "/tmp/boot.user3615370981886979666.clj"
line: 25
```

Is this the final behavior? It seems like I would have to continue using hacks just to have this very basic feature.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.