# A neat Julia/SLURM trick

**URL:** https://discourse.julialang.org/t/a-neat-julia-slurm-trick/61123
**Category:** General Usage
**Created:** [May 14, 2021, 6:12am UTC](https://discourse.julialang.org/t/a-neat-julia-slurm-trick/61123 "2021-05-14T06:12:03Z")
**Posts on this page:** 1
**Showing post:** 2

<div class="post-metadata">

### Author: ![tbeason](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tbeason/32/15898_2.png) [@tbeason](https://discourse.julialang.org/u/tbeason)
#### Post date: [May 14, 2021, 6:27am UTC](https://discourse.julialang.org/t/a-neat-julia-slurm-trick/61123/2 "2021-05-14T06:27:20Z")

</div>

Thanks for sharing. What is the advantage of this over a “here document”?

```julia
#!/usr/bin/env sh
#SBATCH -N 10
#SBATCH -n 8
#SBATCH -o %x-%j.out

module load julia/1.6.1 ## I have to load julia before calling julia

julia << EOF

using SomePackage
do_julia_stuff

EOF
```

---

_[View the full topic](https://discourse.julialang.org/t/a-neat-julia-slurm-trick/61123)._
