mirror of
https://github.com/ipfs/kubo.git
synced 2025-07-01 02:30:39 +08:00
fix(unixfs/pb) rename proto package -> unixfs_pb
This commit is contained in:
@ -1,5 +1,10 @@
|
||||
all: data.pb.go
|
||||
PB = $(wildcard *.proto)
|
||||
GO = $(PB:.proto=.pb.go)
|
||||
|
||||
data.pb.go: data.proto
|
||||
protoc --go_out=. data.proto
|
||||
all: $(GO)
|
||||
|
||||
%.pb.go: %.proto
|
||||
protoc --gogo_out=. --proto_path=../../../../../../:/usr/local/opt/protobuf/include:. $<
|
||||
|
||||
clean:
|
||||
rm *.pb.go
|
||||
|
@ -1,19 +1,19 @@
|
||||
// Code generated by protoc-gen-go.
|
||||
// source: data.proto
|
||||
// Code generated by protoc-gen-gogo.
|
||||
// source: unixfs.proto
|
||||
// DO NOT EDIT!
|
||||
|
||||
/*
|
||||
Package unixfs is a generated protocol buffer package.
|
||||
Package unixfs_pb is a generated protocol buffer package.
|
||||
|
||||
It is generated from these files:
|
||||
data.proto
|
||||
unixfs.proto
|
||||
|
||||
It has these top-level messages:
|
||||
PBData
|
||||
*/
|
||||
package unixfs
|
||||
package unixfs_pb
|
||||
|
||||
import proto "github.com/jbenet/go-ipfs/Godeps/_workspace/src/code.google.com/p/goprotobuf/proto"
|
||||
import proto "github.com/jbenet/go-ipfs/Godeps/_workspace/src/code.google.com/p/gogoprotobuf/proto"
|
||||
import math "math"
|
||||
|
||||
// Reference imports to suppress errors if they are not otherwise used.
|
||||
@ -57,7 +57,7 @@ func (x *PBData_DataType) UnmarshalJSON(data []byte) error {
|
||||
}
|
||||
|
||||
type PBData struct {
|
||||
Type *PBData_DataType `protobuf:"varint,1,req,enum=unixfs.PBData_DataType" json:"Type,omitempty"`
|
||||
Type *PBData_DataType `protobuf:"varint,1,req,enum=unixfs.pb.PBData_DataType" json:"Type,omitempty"`
|
||||
Data []byte `protobuf:"bytes,2,opt" json:"Data,omitempty"`
|
||||
Filesize *uint64 `protobuf:"varint,3,opt,name=filesize" json:"filesize,omitempty"`
|
||||
Blocksizes []uint64 `protobuf:"varint,4,rep,name=blocksizes" json:"blocksizes,omitempty"`
|
||||
@ -97,5 +97,5 @@ func (m *PBData) GetBlocksizes() []uint64 {
|
||||
}
|
||||
|
||||
func init() {
|
||||
proto.RegisterEnum("unixfs.PBData_DataType", PBData_DataType_name, PBData_DataType_value)
|
||||
proto.RegisterEnum("unixfs.pb.PBData_DataType", PBData_DataType_name, PBData_DataType_value)
|
||||
}
|
@ -1,4 +1,4 @@
|
||||
package unixfs;
|
||||
package unixfs.pb;
|
||||
|
||||
message PBData {
|
||||
enum DataType {
|
Reference in New Issue
Block a user