Why is my clojure shell result not like what works in python?
clojure, python
Solution
`future` is a convenient way to leave work running in the background, and it is easy to check up on the process later.
user> (def notepad-process (future (sh "emacs" "jpad.clj")))
#'user/notepad-process
Edit the file for a while, then check on the process later if you want its exit code:
user> @notepad-process
{:exit 0, :out "", :err ""}
Problem
When working in the python `repl` I often need to edit multiline code. So I use `import os` then `os.system("notepad npad.py")` In clojure I first run `(use '[clojure.java.shell :only [sh]])` Then I run `(sh "notepad" "jpad.clj")` This starts notepad but not in a useful way because the clojure `repl` now hangs. In other words, until I close notepad I cannot enter code in the `repl` and I want to keep both open. I know I can easily open notepad without clojure so it is no big deal. However, is there a way for clojure to start an external process without hanging?