Documentation
¶
Overview ¶
Package config implements interface for app-level configs for cr-rev.
Index ¶
- Variables
- func Override(ctx context.Context, cfg *Config) error
- func Set(ctx context.Context) error
- type Config
- type Host
- func (*Host) Descriptor() ([]byte, []int)deprecated
- func (x *Host) GetName() string
- func (x *Host) GetPubsubSubscription() string
- func (x *Host) GetRepos() []*Repository
- func (*Host) ProtoMessage()
- func (x *Host) ProtoReflect() protoreflect.Message
- func (x *Host) Reset()
- func (x *Host) String() string
- type Repository
- func (*Repository) Descriptor() ([]byte, []int)deprecated
- func (x *Repository) GetDoNotIndex() bool
- func (x *Repository) GetExcludeRefs() []string
- func (m *Repository) GetIndexing() isRepository_Indexing
- func (x *Repository) GetName() string
- func (x *Repository) GetPriority() bool
- func (x *Repository) GetRefs() []string
- func (*Repository) ProtoMessage()
- func (x *Repository) ProtoReflect() protoreflect.Message
- func (x *Repository) Reset()
- func (x *Repository) String() string
- type Repository_DoNotIndex
- type Repository_Priority
Constants ¶
This section is empty.
Variables ¶
View Source
var File_infra_appengine_cr_rev_config_config_proto protoreflect.FileDescriptor
Functions ¶
Types ¶
type Config ¶
type Config struct {
// A list of hosts to index.
Hosts []*Host `protobuf:"bytes,1,rep,name=hosts,proto3" json:"hosts,omitempty"`
// contains filtered or unexported fields
}
func (*Config) Descriptor
deprecated
func (*Config) ProtoMessage ¶
func (*Config) ProtoMessage()
func (*Config) ProtoReflect ¶
func (x *Config) ProtoReflect() protoreflect.Message
type Host ¶
type Host struct {
// The name of the host, for example "chromium" or "chrome-internal".
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
// Should be specified only for repositories that need to override default
// attributes.
Repos []*Repository `protobuf:"bytes,2,rep,name=repos,proto3" json:"repos,omitempty"`
// Name of pubsub topic for the host which is used to update individual
// repositories. If not present, new commits won't be indexed.
PubsubSubscription string `protobuf:"bytes,3,opt,name=pubsub_subscription,json=pubsubSubscription,proto3" json:"pubsub_subscription,omitempty"`
// contains filtered or unexported fields
}
func (*Host) Descriptor
deprecated
func (*Host) GetPubsubSubscription ¶
func (*Host) GetRepos ¶
func (x *Host) GetRepos() []*Repository
func (*Host) ProtoMessage ¶
func (*Host) ProtoMessage()
func (*Host) ProtoReflect ¶
func (x *Host) ProtoReflect() protoreflect.Message
type Repository ¶
type Repository struct {
// The name of the repository, for example "chromium/src" or "v8/v8".
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
// Indexing configuration for this repository.
//
// Types that are assignable to Indexing:
// *Repository_DoNotIndex
// *Repository_Priority
Indexing isRepository_Indexing `protobuf_oneof:"indexing"`
// A list of refs to be indexed, specified as a list of ref paths. If provided
// path is not a leaf, it will include all its children.
//
// Examples:
// # All heads
// "refs/heads"
// # All branch-heads
// "refs/branch-heads"
// # main only
// "refs/heads/main"
//
// Defaults to ["refs/heads"]
Refs []string `protobuf:"bytes,6,rep,name=refs,proto3" json:"refs,omitempty"`
// A list of git refs to ignore even when they match a ref included above.
// It is also specified as a list of regular expressions automatically wrapped
// in ^ and $.
ExcludeRefs []string `protobuf:"bytes,7,rep,name=exclude_refs,json=excludeRefs,proto3" json:"exclude_refs,omitempty"`
// contains filtered or unexported fields
}
func (*Repository) Descriptor
deprecated
func (*Repository) Descriptor() ([]byte, []int)
Deprecated: Use Repository.ProtoReflect.Descriptor instead.
func (*Repository) GetDoNotIndex ¶
func (x *Repository) GetDoNotIndex() bool
func (*Repository) GetExcludeRefs ¶
func (x *Repository) GetExcludeRefs() []string
func (*Repository) GetIndexing ¶
func (m *Repository) GetIndexing() isRepository_Indexing
func (*Repository) GetName ¶
func (x *Repository) GetName() string
func (*Repository) GetPriority ¶
func (x *Repository) GetPriority() bool
func (*Repository) GetRefs ¶
func (x *Repository) GetRefs() []string
func (*Repository) ProtoMessage ¶
func (*Repository) ProtoMessage()
func (*Repository) ProtoReflect ¶
func (x *Repository) ProtoReflect() protoreflect.Message
func (*Repository) Reset ¶
func (x *Repository) Reset()
func (*Repository) String ¶
func (x *Repository) String() string
type Repository_DoNotIndex ¶
type Repository_DoNotIndex struct {
// Ignore commits for this repository.
DoNotIndex bool `protobuf:"varint,2,opt,name=do_not_index,json=doNotIndex,proto3,oneof"`
}
type Repository_Priority ¶
type Repository_Priority struct {
// Whether git hashes that are also part of other repositories should refer
// to this repository.
//
// For example, we set `priority = true` for "chromium/src", since all git
// commit hashes in "chromium/src" will also exist in
// "chromium/src/codesearch", but we want crrev to redirect to
// "chromium/src" instead of "chromium/src/codesearch".
Priority bool `protobuf:"varint,3,opt,name=priority,proto3,oneof"`
}
Click to show internal directories.
Click to hide internal directories.