# Juliad and julias, wrappers to DaemonMode and -J sysimage for quicker Linux/Cygwin scripts

**URL:** <https://discourse.julialang.org/t/juliad-and-julias-wrappers-to-daemonmode-and-j-sysimage-for-quicker-linux-cygwin-scripts/76690>\
**Category:** General Usage\
**Tags:** question, linux, sysimage, ttfx\
**Created:** [February 18, 2022, 11:15am UTC](https://discourse.julialang.org/t/juliad-and-julias-wrappers-to-daemonmode-and-j-sysimage-for-quicker-linux-cygwin-scripts/76690 "2022-02-18T11:15:41Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![jdad](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/jdad/32/4739_2.png) [@jdad](https://discourse.julialang.org/u/jdad)\
**Post date:** [February 18, 2022, 11:15am UTC](https://discourse.julialang.org/t/juliad-and-julias-wrappers-to-daemonmode-and-j-sysimage-for-quicker-linux-cygwin-scripts/76690/1 "2022-02-18T11:15:42Z")

</div>

FWIW, as an old linuxer, I have created for my own usage two scripts to facilitate the use of either sysimage or DaermonMode.jl to get faster frequently used scripts (=faster TTFX, Time to First X). Sorry, I have done this in bash shell, as a first step/prototyping step before writing that in pure Julia.

So I would like to have advices / comments about those prototype implementations. Please take a look to **`juliad`** (for **`julia`** local **`d`** aemon) and **`julias`** (for **`julia`**  **`s`** ysimage) at [https://github.com/jdadavid/juliashellutils](https://github.com/jdadavid/juliashellutils) and comment and suggest! Many thanks in advance.

Excerpts from the Readme

```julia
julias : Julia launcher wrapper for using local JuliaSysimage.[dll|so] if its exists and is up to date
Usage : julias : [+h] [+v|+q] [+f] [+J juliax] [julia_options] file.jl [args]
launch Julia with sysimage "JuliaSysimage.[dll|so]" if found
   +h : this help
   +v : verbose
   +q : quiet (no warnings, e.g. about out of date or force)
   +f : force use of sysimage even if out of date
   +J juliax : use juliax executable for julia

```

```julia
juliad : launches Julia daemon server (if necessary), and client, to execute julia file with reduced TTFX
# wraps excellent DaemonMode by @dmolina (see https://github.com/dmolina/DaemonMode.jl)
# You must have added DaemonMode to the project that will be used (or the default v1.x env)
Usage : juliad [+h] [+v] [+l] [+k] [+s] [+J juliax] [julia_options] file.jl [args]
    +h : this help
    +v : verbose (vs launching steps)
    +l : list running server and exits
    +k : kill running server and exits
    +s : launch julia with startup file (default is without)
    +J juliax : use "juliax" as julia executable
Notes:
  - the principle is to lauch one daemon per directory (=project)
  - the script creates a local file '.juliad' which stores the status of a running daemon
  - as of current, status is (port used, julia_args(project, use_startup))

```

---

<div class="post-metadata">

**Author:** ![ufechner7](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ufechner7/32/51363_2.png) [@ufechner7](https://discourse.julialang.org/u/ufechner7)\
**Post date:** [August 8, 2022, 3:58am UTC](https://discourse.julialang.org/t/juliad-and-julias-wrappers-to-daemonmode-and-j-sysimage-for-quicker-linux-cygwin-scripts/76690/2 "2022-08-08T03:58:35Z")

</div>

Regarding `julias`:

I have a similar script [KiteSimulators.jl/run\_julia at main · aenarete/KiteSimulators.jl · GitHub](https://github.com/aenarete/KiteSimulators.jl/blob/main/bin/run_julia) with the following differences:

1. The script lives in the bin folder of a project
2. It uses one sysimage per major Julia version because I often switch versions
3. I have also a .bat version for Windows

---

<div class="post-metadata">

**Author:** ![jdad](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/jdad/32/4739_2.png) [@jdad](https://discourse.julialang.org/u/jdad)\
**Post date:** [August 8, 2022, 6:56am UTC](https://discourse.julialang.org/t/juliad-and-julias-wrappers-to-daemonmode-and-j-sysimage-for-quicker-linux-cygwin-scripts/76690/3 "2022-08-08T06:56:40Z")

</div>

Thanks for the comment, I will take a look to your scripts, including the “.bat” one - for myself I use Linux, or cygwin on Windows (or, more and more, WSL2), so no real need for .bat, but could be a nice addition.

NB. I just update my julias and juliad scripts, changing command switch “+” to “=” so they can coexist with Juliaup/julia(launcher), which already used “+” as switch.

---

<div class="post-metadata">

**Author:** ![jondea](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/jondea/32/39086_2.png) [@jondea](https://discourse.julialang.org/u/jondea)\
**Post date:** [August 8, 2022, 11:00am UTC](https://discourse.julialang.org/t/juliad-and-julias-wrappers-to-daemonmode-and-j-sysimage-for-quicker-linux-cygwin-scripts/76690/4 "2022-08-08T11:00:55Z")

</div>

This looks cool, and has some really nice ideas, thanks for sharing. I have my own hacky version of this called [juliab](https://github.com/jondea/juliab) (interesting that people seems to go for julia + 1 letter). I also recently saw this vaguely similar thing too [Tool: sysimage\_creator for IJulia users](https://discourse.julialang.org/t/tool-sysimage-creator-for-ijulia-users/61229)

It would be interesting to see if these projects/ideas could be combined somehow.
