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
edit function doesn't work inside VSCode's Julia REPL #2057
Comments
Can you check what |
julia> ENV["EDITOR"]
ERROR: KeyError: key "EDITOR" not found
Stacktrace:
[1] access_env at ./env.jl:43 [inlined]
[2] getindex(::Base.EnvDict, ::String) at ./env.jl:79
[3] top-level scope at REPL[3]:1
julia> ENV["JULIA_EDITOR"]
"\"/usr/lib/electron/electron\"" |
How did you install VSCode? |
|
I set ENV["JULIA_EDITOR"] to "code" and have run a few experiments:
If I sent ENV["JULIA_EDITOR"] = "vim" then steps 1 and 2 above work. As far as I can tell there are two problems b) even when initalized correctly (to "code") Julia silently refuses to open the file with VSCode from a terminal or REPL that is launched from VSCode. |
Well, we don't find the right path for the official distribution. Everything works fine if you build the AUR package yourself, for example. I'll play around with finding the correct path... |
Sorry, I forgot to mention that all experiments 1-4 above I ran with So switching to AUR at least informs @edit about the correct Julia Library source location (because @edit opens the source code when I sent JULIA_EDITOR to "nano" or "vim") but @edit still doesn't work when JULIA_EDITOR is set to "code" for some other reason... |
I have the same problem it seems. I am using Ubuntu: Julia
Ubuntu
VSCode
I can install whatever you want to test. |
@pfitzseb Does it take long until the fix is rolled out to VSCode? I have no idea about the process. |
The fix should appear on the insiders channel within in the next day or so, I think. |
@pfitzseb The fix doesn't solve the problem for me, when I call I'm using the latest 1.1.38 |
What is |
You can now also set the |
Let me repeat myself, this is from the post above:
Thus, the problem is now not related to "JULIA_EDITOR" variable not being initialized correctly, it is related to the fact that even if it is initialized correctly |
Must be a weird interaction with how Arch packages VSCode or something. The re-packaged code-bin versions work fine for me. The PR above fixed auto-setting of |
When I try to call
edit
forjl
file I get the following errorIf I try to call
edit
for an emptytest.txt
file I getEnvironemnt
The text was updated successfully, but these errors were encountered: