mirror of
https://codeberg.org/qwjyh/dotfiles.git
synced 2025-06-26 19:29:20 +09:00
fix(julials): remove sysimage to fix too old LanguageServer.jl version being resolved
This commit is contained in:
parent
b40e8ad329
commit
ddb9a620c9
3 changed files with 18 additions and 17 deletions
|
@ -3,14 +3,14 @@ project_path = joinpath(homedir(), ".julia", "environments", "nvim-lspconfig")
|
|||
cd(project_path) do
|
||||
@info "now at " pwd()
|
||||
run(`julia --project=. -e 'using Pkg; Pkg.update()'`)
|
||||
compile_traces = Iterators.filter(eachline("tracecompile.jl")) do line
|
||||
# Remove anonymous functions from compile trace
|
||||
!startswith(line, '#') && !occursin(r"\#\d+\#\d+", line) && !occursin(r"\#\#printstyled\#", line)
|
||||
end |> join
|
||||
read("precompile_exec_head.jl", String) * compile_traces |> (b -> write("precompile_exec.jl", b))
|
||||
@info "compiling sysimage..."
|
||||
run(`julia --project=. -e 'using PackageCompiler; create_sysimage(["LanguageServer"], sysimage_path = "sys-ls.so", precompile_execution_file = ["precompile_exec.jl"])'`)
|
||||
@info "post precompile"
|
||||
run(`julia --project=. -J sys-ls.so -e 'using Pkg; Pkg.precompile()'`)
|
||||
# compile_traces = Iterators.filter(eachline("tracecompile.jl")) do line
|
||||
# # Remove anonymous functions from compile trace
|
||||
# !startswith(line, '#') && !occursin(r"\#\d+\#\d+", line) && !occursin(r"\#\#printstyled\#", line)
|
||||
# end |> join
|
||||
# read("precompile_exec_head.jl", String) * compile_traces |> (b -> write("precompile_exec.jl", b))
|
||||
# @info "compiling sysimage..."
|
||||
# run(`julia --project=. -e 'using PackageCompiler; create_sysimage(["LanguageServer"], sysimage_path = "sys-ls.so", precompile_execution_file = ["precompile_exec.jl"])'`)
|
||||
# @info "post precompile"
|
||||
# run(`julia --project=. -J sys-ls.so -e 'using Pkg; Pkg.precompile()'`)
|
||||
end
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue