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
Is it possible to preserve all the comments and new lines generated by buf?
For example, this part:
# -*- coding: utf-8 -*-
# Generated by the protocol buffer compiler. DO NOT EDIT!
# NO CHECKED-IN PROTOBUF GENCODE
# source: project/protos/abc.proto
# Protobuf Python Version: 5.28.2
"""Generated protocol buffer code."""
from google.protobuf import descriptor as _descriptor
from google.protobuf import descriptor_pool as _descriptor_pool
from google.protobuf import runtime_version as _runtime_version
from google.protobuf import symbol_database as _symbol_database
from google.protobuf.internal import builder as _builder
_runtime_version.ValidateProtobufRuntimeVersion(
_runtime_version.Domain.PUBLIC,
5,
28,
2,
'',
'project/protos/abc.proto'
)
# @@protoc_insertion_point(imports)
_sym_db = _symbol_database.Default()
from validate import validate_pb2 as validate_dot_validate__pb2
from google.protobuf import struct_pb2 as google_dot_protobuf_dot_struct__pb2
is rewritten as
"""Generated protocol buffer code."""
from google.protobuf import descriptor as _descriptor
from google.protobuf import descriptor_pool as _descriptor_pool
from google.protobuf import runtime_version as _runtime_version
from google.protobuf import symbol_database as _symbol_database
from google.protobuf.internal import builder as _builder
_runtime_version.ValidateProtobufRuntimeVersion(_runtime_version.Domain.PUBLIC, 5, 28, 2, '', 'project/protos/abc.proto')
_sym_db = _symbol_database.Default()
from ...validate import validate_pb2 as validate_dot_validate__pb2
from google.protobuf import struct_pb2 as google_dot_protobuf_dot_struct__pb2
It removed all the # comments and removed the new lines.
The text was updated successfully, but these errors were encountered:
Hello and thanks for creating this, very helpful!
Is it possible to preserve all the comments and new lines generated by
buf
?For example, this part:
is rewritten as
It removed all the
#
comments and removed the new lines.The text was updated successfully, but these errors were encountered: