mirror of
https://github.com/go-gitea/gitea.git
synced 2025-09-02 22:07:05 +09:00
committed by
Lunny Xiao
parent
b209531959
commit
33ad554800
4
vendor/gopkg.in/src-d/go-git.v4/worktree.go
generated
vendored
4
vendor/gopkg.in/src-d/go-git.v4/worktree.go
generated
vendored
@ -160,6 +160,8 @@ func (w *Worktree) Checkout(opts *CheckoutOptions) error {
|
||||
ro := &ResetOptions{Commit: c, Mode: MergeReset}
|
||||
if opts.Force {
|
||||
ro.Mode = HardReset
|
||||
} else if opts.Keep {
|
||||
ro.Mode = SoftReset
|
||||
}
|
||||
|
||||
if !opts.Hash.IsZero() && !opts.Create {
|
||||
@ -720,7 +722,7 @@ func (w *Worktree) Clean(opts *CleanOptions) error {
|
||||
|
||||
func (w *Worktree) doClean(status Status, opts *CleanOptions, dir string, files []os.FileInfo) error {
|
||||
for _, fi := range files {
|
||||
if fi.Name() == ".git" {
|
||||
if fi.Name() == GitDirName {
|
||||
continue
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user