# How to launch Julia from a customized script in Vscode

**URL:** <https://discourse.julialang.org/t/how-to-launch-julia-from-a-customized-script-in-vscode/84742>\
**Category:** New to Julia\
**Tags:** question\
**Created:** [July 25, 2022, 9:12am UTC](https://discourse.julialang.org/t/how-to-launch-julia-from-a-customized-script-in-vscode/84742 "2022-07-25T09:12:37Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Weijie](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/weijie/32/37758_2.png) [@Weijie](https://discourse.julialang.org/u/Weijie)\
**Post date:** [July 25, 2022, 9:12am UTC](https://discourse.julialang.org/t/how-to-launch-julia-from-a-customized-script-in-vscode/84742/1 "2022-07-25T09:12:37Z")

</div>

Dear there,  
These days I was trying to launch Julia from a script (in my customized path) that defines the JULIA\_DEPOT\_PATH and Executable\_Path in Vscode. However, it seems that the julia\_extension is not able to find the settings in the script after click (ctrl+shift+P) to run “Julia: Start REPL”.  
Nothing happens after this action:

 ![image](https://global.discourse-cdn.com/julialang/original/3X/6/8/689a10f3900f1ef2e9194cae073456e4a8ff4c9a.png)  
Would be very grateful if there is any clue to address my confusion…

-Weijie

---

<div class="post-metadata">

**Author:** ![fredrikekre](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/fredrikekre/32/1688_2.png) [@fredrikekre](https://discourse.julialang.org/u/fredrikekre)\
**Post date:** [July 25, 2022, 9:52am UTC](https://discourse.julialang.org/t/how-to-launch-julia-from-a-customized-script-in-vscode/84742/2 "2022-07-25T09:52:07Z")

</div>

It would be helpful if you could provide more information. What does your script look like? How are you telling VSCode to use that script?

---

<div class="post-metadata">

**Author:** ![Weijie](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/weijie/32/37758_2.png) [@Weijie](https://discourse.julialang.org/u/Weijie)\
**Post date:** [July 25, 2022, 1:17pm UTC](https://discourse.julialang.org/t/how-to-launch-julia-from-a-customized-script-in-vscode/84742/3 "2022-07-25T13:17:44Z")

</div>

Thanks for the response! 🍻

So the script is called **launch\_julia\_v171** in Path /home/wj/julia/, with contents:

```julia
export JULIA_DEPOT_PATH=/home/wj/julia/julia_depots
/home/wj/juliahome/julia-1.7.1/bin/julia

```

Then in VScode Julia extensions, the setting is:

```julia
{
    "julia.environmentPath": "/home/wj/julia/julia_depots/environments/",
    "julia.persistentSession.enabled": true,
    "julia.executablePath": "/home/wj/julia/launch_julia_v171"
}

```

The executablePath works on the terminal, but unfortunately it does not work in VScode.

Thanks,  
Weijie

---

<div class="post-metadata">

**Author:** ![pfitzseb](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/pfitzseb/32/45566_2.png) [@pfitzseb](https://discourse.julialang.org/u/pfitzseb)\
**Post date:** [July 25, 2022, 1:22pm UTC](https://discourse.julialang.org/t/how-to-launch-julia-from-a-customized-script-in-vscode/84742/4 "2022-07-25T13:22:05Z")

</div>

Try

```julia
export JULIA_DEPOT_PATH=/home/wj/julia/julia_depots
/home/wj/juliahome/julia-1.7.1/bin/julia "$@"

```

instead. It’s important you pipe all arguments through to Julia (check that `./launch_julia_v171 -v` works, for example).

---

<div class="post-metadata">

**Author:** ![Weijie](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/weijie/32/37758_2.png) [@Weijie](https://discourse.julialang.org/u/Weijie)\
**Post date:** [July 25, 2022, 1:51pm UTC](https://discourse.julialang.org/t/how-to-launch-julia-from-a-customized-script-in-vscode/84742/5 "2022-07-25T13:51:54Z")

</div>

Hi there,

Super cool it works after adding “$@”, although I do not get the underlying logic…  
Thanks a million! 🍻 🍻

-Weijie

---

<div class="post-metadata">

**Author:** ![fredrikekre](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/fredrikekre/32/1688_2.png) [@fredrikekre](https://discourse.julialang.org/u/fredrikekre)\
**Post date:** [July 25, 2022, 2:57pm UTC](https://discourse.julialang.org/t/how-to-launch-julia-from-a-customized-script-in-vscode/84742/6 "2022-07-25T14:57:51Z")

</div>

> [@Weijie](#):
>
> Super cool it works after adding “$@”, although I do not get the underlying logic…

`"$@"` expands to the parameters that your script is called with. These needs to be passed on to the actual/real Julia executable.
