Skip to content

Commit cbbdaf6

Browse files
committed
Emit 'swift-format-ignore-file' in generated files to avoid having them reformatted by swift-format
1 parent 6b55ce0 commit cbbdaf6

File tree

7 files changed

+7
-1
lines changed

7 files changed

+7
-1
lines changed

Diff for: Sources/Examples/Echo/Model/echo.grpc.swift

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
//
22
// DO NOT EDIT.
3+
// swift-format-ignore-file
34
//
45
// Generated by the protocol buffer compiler.
56
// Source: echo.proto

Diff for: Sources/Examples/HelloWorld/Model/helloworld.grpc.swift

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
//
22
// DO NOT EDIT.
3+
// swift-format-ignore-file
34
//
45
// Generated by the protocol buffer compiler.
56
// Source: helloworld.proto

Diff for: Sources/Examples/RouteGuide/Model/route_guide.grpc.swift

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
//
22
// DO NOT EDIT.
3+
// swift-format-ignore-file
34
//
45
// Generated by the protocol buffer compiler.
56
// Source: route_guide.proto

Diff for: Sources/GRPCInteroperabilityTestModels/Generated/test.grpc.swift

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
//
22
// DO NOT EDIT.
3+
// swift-format-ignore-file
34
//
45
// Generated by the protocol buffer compiler.
56
// Source: src/proto/grpc/testing/test.proto

Diff for: Sources/protoc-gen-grpc-swift/Generator.swift

+1
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,7 @@ class Generator {
111111
self.printer.print("""
112112
//
113113
// DO NOT EDIT.
114+
// swift-format-ignore-file
114115
//
115116
// Generated by the protocol buffer compiler.
116117
// Source: \(self.file.name)

Diff for: Tests/GRPCTests/Codegen/Normalization/normalization.grpc.swift

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
//
22
// DO NOT EDIT.
3+
// swift-format-ignore-file
34
//
45
// Generated by the protocol buffer compiler.
56
// Source: normalization.proto

Diff for: scripts/license-check.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ check_copyright_headers() {
9797
# Package.swift is preceeded by a "swift-tools-version" line.
9898
*.grpc.swift)
9999
expected_sha="$SWIFT_GRPC_SHA"
100-
drop_first=8
100+
drop_first=9
101101
expected_lines=13
102102
;;
103103
*.pb.swift)

0 commit comments

Comments
 (0)