9a5720e8ad
Branch Policy Check / Verify merge target (pull_request) Has been cancelled
Universal: PR Check / Branch Policy (pull_request) Has been cancelled
PR RC Release / Build RC Release (pull_request) Has been cancelled
Universal: PR Check / Validate PR (pull_request) Has been cancelled
Branch Cleanup / Delete merged branch (pull_request) Has been cancelled
Universal: PR Check / Build RC Package (pull_request) Has been cancelled
Full namespace migration: update the Go module path and all import statements from git.mokoconsulting.tech to code.mokoconsulting.tech. Also updates all URL references in templates, workflows, configs, tests, and documentation. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
31 lines
804 B
Go
31 lines
804 B
Go
// Copyright 2015 The Gogs Authors. All rights reserved.
|
|
// Copyright 2019 The Gitea Authors. All rights reserved.
|
|
// SPDX-License-Identifier: MIT
|
|
|
|
//go:build !gogit
|
|
|
|
package git
|
|
|
|
import (
|
|
"fmt"
|
|
"time"
|
|
|
|
"code.mokoconsulting.tech/MokoConsulting/MokoGitea/modules/util"
|
|
)
|
|
|
|
// Signature represents the Author, Committer or Tagger information.
|
|
type Signature struct {
|
|
Name string // the committer name, it can be anything
|
|
Email string // the committer email, it can be anything
|
|
When time.Time // the timestamp of the signature
|
|
}
|
|
|
|
func (s *Signature) String() string {
|
|
return fmt.Sprintf("%s <%s>", s.Name, s.Email)
|
|
}
|
|
|
|
// Decode decodes a byte array representing a signature to signature
|
|
func (s *Signature) Decode(b []byte) {
|
|
*s = *parseSignatureFromCommitLine(util.UnsafeBytesToString(b))
|
|
}
|