Open cgrindel opened 2 years ago
Having thought about it a bit more, I tend to think that option 2 or 4 might be the best path forward. It reduces the complexity, but allows the entire operation to be handled by a single Bazel run command.
To support multiple Xcode configurations (i.e. Release and Profile in addition to Debug) we will probably need a wrapper script around the bazel run
invocation, to be able to capture some arbitrary bazel flags (though this isn't guaranteed yet).
To properly support Focused Projects we will also recommend a wrapper script around the bazel run
invocation, as one will need to do some level of meta programming to generate changes to one or more .bzl
files.
Since code snippets don't exist in the .xcodeproj
bundle, I feel this ties into that wrapper script. I recommend creating a simple wrapper, per option 1, for now. We will need to get further along in the implementation of the previously mentioned features before we will know what our example wrapper script will look like (or if we will have a wrapper script creator, or a canonical one, or ...).
We now have a wrapper script in the form of the "runner". It's not too customizable right now, but we now also support pretty arbitrary config via configs in .bazelrc
or .xcodeproj.bazelrc
or even command-line arguments.
I think it would be fine to add more customization into what happens in the runner. A design document would be nice, but a well fleshed out PR works as well.
Some companies/projects provide shared code snippets checked in to source control. Right now, we perform a separate step to copy the code snippets to the appropriate location.
Granted this request is slightly orthogonal to the generation of the project. However, the generation of the project does provide a nice signal to copy the shared code snippets.
Options
rules_xcodeproj
.)