[swift-build-dev] [swift-evolution] [Review] SE-0179: Swift `run` Command

Martin Angers martin.n.angers at gmail.com
Wed May 17 08:07:51 CDT 2017


Same comments as Tony and Richard, I'm definitely +1 on the proposal, but I
find the directory-related flags confusingly named.

I think Tony's suggestion is interesting, but `-working-directory` is still
confusing, it could fit both uses, so maybe instead something like:

-build-directory : change before any operation (assuming the only
operations besides running the executable is to build it?)

-run-directory : working directory to run the executable

However, I understand that -chdir is already supported by existing commands
to change the working directory before any other operation, so maybe just
rename -in-dir to -run-directory would make sense. Or use the directory
provided to -chdir as both the build and run directories and drop the
-in-dir flag (after all, this is a convenience operation that combines
build and run by default, you can always build separately, then run with
-skip-build).

Thinking out loud a bit, but the basic idea is that those 2 flags are
confusing, but the rest looks good to me.

Martin

On Wed, May 17, 2017 at 08:07 Tony Arnold via swift-evolution <
swift-evolution at swift.org> wrote:

>
> > On 17 May 2017, at 20:32, Richard Wei via swift-evolution <
> swift-evolution at swift.org> wrote:
> >
> > Excellent, except that `--chdir` and `--in-dir` are confusing. Why not
> use a long, clear name, just like `—enable-prefetching`? Consider
> `—working-dir` & `—preexec-working-dir`
>
> That would be my one bit of feedback as well. The names of these two
> parameters aren’t descriptive.
>
> My suggestions would be:
>
> --working-directory, -w         Change working directory before any other
> operation
> --run-directory, -r             Change working directory before running
> the executable
>
> I don’t believe there’s any reason to shorten or truncate the full
> parameters if you’re going to offer a single-character alias for them.
>
> Otherwise, top proposal! 5 stars, would review again ;)
>
> I’m +1 for SE-0179.
>
>
> -t
>
>
>
> ----------
> Tony Arnold
> +61 411 268 532
> http://thecocoabots.com/
>
> ABN: 14831833541
>
> _______________________________________________
> swift-evolution mailing list
> swift-evolution at swift.org
> https://lists.swift.org/mailman/listinfo/swift-evolution
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-build-dev/attachments/20170517/aa94eddc/attachment.html>


More information about the swift-build-dev mailing list