-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
Docs: julia_cmd
: Document use of julia_cmd()[1]
#48425
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.
Looks good to me, but I'd like someone else to confirm it's ok to set this in stone.
Seems a shame to do all the work to construct the args then throw them away. |
Or just """
Base.julia_exepath()
Returns the path to the julia executable of the running process.
"""
julia_exepath() = joinpath(Sys.BINDIR, julia_exename())
...
function julia_cmd(julia=julia_exepath(); cpu_target::Union{Nothing,String} = nothing) Happy to PR it if people approve |
@IanButterworth I don't think this will be used in performance-critical code, right? The advantage of documenting |
That could be in the compat note """
Base.julia_exepath()
Returns the path to the julia executable of the running process.
!!! compat julia 1.10
This was added in Julia 1.10. In prior versions use `julia_cmd()[1]`
"""
julia_exepath() = joinpath(Sys.BINDIR, julia_exename())
...
function julia_cmd(julia=julia_exepath(); cpu_target::Union{Nothing,String} = nothing) |
We can also just merge this as is and that can be a follow-on |
All sounds good to me! :) |
Resolve #48393
I don't want to take up too much time for this issue, so feel free to close/edit without comment. I'm already happy to have found the solution☺️