You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Prepare for a 1.31.0 release and update docs (#1843)
# Motivations
In the previous PRs, I landed support for distributing `protoc` via this
repo which finally allows us to broadly recommend the SPM plugin.
# Modifications
This PR bumps the versions and updates the docs for the SPM plugin and a
tiny addition to the RELEASING doc to ensure the latest check is set.
# Result
Unblocking the ecosystem in broadly adopting the SPM plugin.
Copy file name to clipboardExpand all lines: Sources/protoc-gen-swift/Docs.docc/spm-plugin.md
+10-17Lines changed: 10 additions & 17 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -105,20 +105,16 @@ is generating Swift types for the `Bar.proto` file with the `public` visibility.
105
105
invocation is using the `pathToUnderscores` file naming option. This option can be used to solve
106
106
problems where a single target contains two or more proto files with the same name.
107
107
108
-
### Defining the path to the protoc binary
108
+
### Overriding the path to the protoc binary
109
109
110
-
The plugin needs to be able to invoke the `protoc` binary to generate the Swift types. There are several ways to achieve this.
110
+
The plugin needs to be able to invoke the `protoc` binary to generate the Swift types.
111
+
By default the plugin will use the latest `protoc` binary distributed as an
112
+
artifact bundle from the [swift-protobuf releases](https://github.com/apple/swift-protobuf/releases).
111
113
112
-
First, by default, the package manager looks into the `$PATH` to find binaries named `protoc`.
113
-
This works immediately if you use `swift build` to build your package and `protoc` is installed
114
-
in the `$PATH` (`brew` is adding it to your `$PATH` automatically).
115
-
However, this doesn't work if you want to compile from Xcode since Xcode is not passed the `$PATH`.
114
+
There are several ways for you to override the path to the `protoc` binary.
116
115
117
-
If compiling from Xcode, you have **three options** to set the path of `protoc` that the plugin is going to use:
118
-
119
-
* You can start Xcode by running `$ xed .` from the command line from the directory your project is located - this should make `$PATH` visible to Xcode.
120
-
121
-
* Set an environment variable `PROTOC_PATH` that gets picked up by the plugin. Here are two examples of how you can achieve this:
116
+
* Set an environment variable `PROTOC_PATH` that gets picked up by the plugin.
117
+
Here are two examples of how you can achieve this:
0 commit comments