Stream: beginners

Topic: can you make `roc run` use /tmp for storing binaries?


view this post on Zulip Daniele Parisi (Jul 15 2024 at 06:30):

I'm not a fan of using the disk in a case like this

view this post on Zulip Brendan Hansknecht (Jul 15 2024 at 06:51):

I think we have a few options:

  1. .roc_cache (either global or local)
  2. Somewhere in /tmp
  3. Keep it totally in memory and never write to disk.

But yeah, run probably shouldn't make a visible artifact if it still does.

view this post on Zulip Anton (Jul 15 2024 at 11:02):

Yeah, Richard just proposed to change this to "This builds the foo.roc application into a binary in a tempdir (or in memory on Linux) and runs it."

view this post on Zulip Richard Feldman (Jul 15 2024 at 11:19):

yeah I think we should:

view this post on Zulip Richard Feldman (Jul 15 2024 at 11:21):

on macOS we probably have to keep the file descriptor to the executable open and then unlink it before running it, because if we're doing execvp to have the running program take over the roc process, then we won't have a chance to clean it up afterwards ourselves


Last updated: Jul 06 2025 at 12:14 UTC