File tree Expand file tree Collapse file tree 2 files changed +24
-2
lines changed Expand file tree Collapse file tree 2 files changed +24
-2
lines changed Original file line number Diff line number Diff line change 1+ ---
2+ " claude-dev " : minor
3+ ---
4+
5+ Update protoc script version check to check for versions LOWER than that specified
Original file line number Diff line number Diff line change @@ -22,8 +22,25 @@ async function main() {
2222 console . warn ( chalk . yellow ( "Warning: Could not determine protoc version. Continuing anyway..." ) )
2323 } else {
2424 const version = versionMatch [ 1 ]
25- const requiredVersion = "30.1"
26- if ( version !== requiredVersion ) {
25+ const requiredVersion = "30.1.0" // Update to include patch version
26+
27+ // Split versions and convert to numbers, default patch to 0 if not present
28+ const vParts = version . split ( "." ) . map ( Number )
29+ const rParts = requiredVersion . split ( "." ) . map ( Number )
30+
31+ const vMajor = vParts [ 0 ]
32+ const vMinor = vParts [ 1 ]
33+ const vPatch = vParts [ 2 ] || 0 // Default to 0 if patch is missing
34+
35+ const rMajor = rParts [ 0 ]
36+ const rMinor = rParts [ 1 ]
37+ const rPatch = rParts [ 2 ] || 0
38+
39+ if (
40+ vMajor < rMajor ||
41+ ( vMajor === rMajor && vMinor < rMinor ) ||
42+ ( vMajor === rMajor && vMinor === rMinor && vPatch < rPatch )
43+ ) {
2744 console . warn (
2845 chalk . yellow ( `Warning: protoc version ${ version } found, but version ${ requiredVersion } is required.` ) ,
2946 )
You can’t perform that action at this time.
0 commit comments