Stream: ideas

Topic: --output flag


view this post on Zulip Richard Feldman (Oct 19 2023 at 18:35):

I'm thinking of adding an --output CLI flag with these characteristics:

view this post on Zulip Richard Feldman (Oct 19 2023 at 18:40):

(this would also make it so that the "whatever" in app "whatever" gets ignored in favor of your .roc filename being the source of truth for the output filename, which we've talked about wanting to do anyway

view this post on Zulip Richard Feldman (Oct 19 2023 at 18:40):

I was also thinking that if you pass a directory to --output then it uses that normal file naming scheme

view this post on Zulip Richard Feldman (Oct 19 2023 at 18:41):

in case you want the filename to be auto-generated based on the target OS (e.g. .exe for executables on Windows but not the others)

view this post on Zulip Luke Boswell (Oct 19 2023 at 18:49):

I like it, will make it easier to drive roc cli from scripts.

view this post on Zulip Richard Feldman (Oct 19 2023 at 19:00):

yeah I want it at work for basically that reason :big_smile:

view this post on Zulip Richard Feldman (Oct 19 2023 at 21:28):

hm, a problem with the "accept a directory" - if the directory doesn't exist yet, then there's no way to tell a directory was desired :thinking:

view this post on Zulip Richard Feldman (Oct 19 2023 at 21:28):

I guess if the path ends in /

view this post on Zulip Kevin Gillette (Oct 19 2023 at 23:32):

If the "whatever" is to be ignored, what's the benefit in still making app authors specify it?

view this post on Zulip Richard Feldman (Oct 19 2023 at 23:40):

the plan is already to get rid of it; this is just implementing the replacement we already settled on (and then later can make parser changes to take it out)


Last updated: Jun 16 2026 at 16:19 UTC