Julia startup options for VSCode

Hi all,

I was wondering if there is a way to include julia startup options in VSCode. Specifically, I would like to enable deprecation warnings by default.

Thanks!

In settings.json, I see a line "julia.additionalArgs":[]. I added depwarn=true inside the brackets. Is that correct?

Edit

Evidently not:

 f() = "f()"

g() = "g()"

@deprecate f() g()

julia> f()
"g()"

It should have printed the following:

julia> f()
┌ Warning: `f()` is deprecated, use `g()` instead.
│   caller = top-level scope at REPL[4]:1
└ @ Core REPL[4]:1
"g()"

I don’t know the answer, but maybe try --depwarn=true with hyphens inside the brackets?
https://docs.julialang.org/en/v1/manual/command-line-interface/#command-line-interface

2 Likes

Yes, when you navigate (through the menus) to the extension settings of the Julia extension, “additional args” is actually the first option that is offered (at least for me?).

Here’s mine:

    "julia.additionalArgs": [
        "--warn-overwrite=yes",
    ],
5 Likes

Thank you everyone for your replies. It turns out that “–warn-overwrite=yes” is the correct input.