-
-
Notifications
You must be signed in to change notification settings - Fork 70
added load-file function #176
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perhaps an option to allow this to be used in a context where a user doesn't want to boot up/kill the existing vm?
I am not sure, about the use case of "not boot/up kill the vm". My use case is the equivalent of "clj hello.clj", in which hello.clj contains some libpython-clj code. Concretely I run it like thgis: docker run ..... ..... my-lib python3 -c "import sys;sys.path.append('/home/user');import cljbridge;cljbridge.load_clojure_file(clj_file='hello.clj)" |
But indeed, I can see the "need" to "load" several clojure files, one after the other. |
Maybe we should put this on hold.
I am not sure, if this belongs here, or should that be done in Clojure side ? My use case would be a Docker container, which start nrepl and notespace on startup |
I now went a bit more into a general "init_clojure" function, with 3 option flags, which controls:
The default could be current behaviour, so:
|
I think this looks good to me at this point. I think we should integrate this, let it be and see if people respond. |
I have not implemented any default . Is this needed ? |
I just came to an other use case, namely running of unit tests. |
maybe teh "real need" is a cli tool, so a replacement for the "clj" launcher, Is this even feasable ? |
I think it is feasible but this right now is a reasonable half step. |
I think "both functions" is best compromise.
|
Sounds good to me. Are you OK if I merge this? I need to release a version of libpython-clj that works on m-1 mac. |
yes, thanks |
as discussed here: https://clojurians.zulipchat.com/#narrow/stream/215609-libpython-clj-dev/topic/embeded.20cli.20apps