Documentation ¶
Index ¶
- type ByRevision
- type Entry
- func (e *Entry) Delete(msg string) bool
- func (e *Entry) Equals(other *Entry) bool
- func (e *Entry) GetName() string
- func (e *Entry) GetRevisions() []*Revision
- func (e *Entry) IsDeleted() bool
- func (e *Entry) Latest() *Revision
- func (e *Entry) Merge(other *Entry) *Entry
- func (e *Entry) SortedRevisions() []*Revision
- type Revision
- type Store
- type Timestamp
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ByRevision ¶
type ByRevision []*Revision
ByRevision sorts to latest revision to the top, i.e. [0]
func (ByRevision) Len ¶
func (r ByRevision) Len() int
func (ByRevision) Less ¶
func (r ByRevision) Less(i, j int) bool
func (ByRevision) Swap ¶
func (r ByRevision) Swap(i, j int)
type Entry ¶
Entry is a key-value entry with a number of revisions
func (*Entry) GetRevisions ¶
GetRevisions returns the slice of revisions
func (*Entry) SortedRevisions ¶
SortedRevisions returns a list of sorted revisions
type Revision ¶
type Revision struct { Created *Timestamp `json:"created"` Message string `json:"message"` Filename string `json:"filename"` Tombstone bool `json:"tombstone"` }
Revision is a single revision of a secret
func (*Revision) GetCreated ¶
GetCreated returns the creation timestampo
func (*Revision) GetFilename ¶
GetFilename returns the blob filename
func (*Revision) GetMessage ¶
GetMessage returns the commit message
func (*Revision) GetTombstone ¶
GetTombstone returns true if this entry was deleted. Important for merging.
type Store ¶
Store is secrets store
func (*Store) GetEntries ¶
GetEntries returns the map of entries
type Timestamp ¶
Timestamp is time.Time with JSON encoding
func (*Timestamp) MarshalJSON ¶
MarshalJSON implements the json marshaler
func (*Timestamp) UnmarshalJSON ¶
UnmarshalJSON implements the json unmarshaler