Skip to content

Commit

Permalink
fix: In addition to ErrWorktreeNotClean the ErrUnstagedChanges handle…
Browse files Browse the repository at this point in the history
…d as well.
  • Loading branch information
szkiba committed Sep 10, 2024
1 parent 55f8de1 commit d851d0e
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
2 changes: 1 addition & 1 deletion cmd/lint.go
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ func updateWorkdir(ctx context.Context, dir string, cloneURL string) error {

err = wtree.Pull(&git.PullOptions{Force: true})
if err != nil && !errors.Is(err, git.NoErrAlreadyUpToDate) {
if !errors.Is(err, git.ErrWorktreeNotClean) {
if !errors.Is(err, git.ErrWorktreeNotClean) && !errors.Is(err, git.ErrUnstagedChanges) {
return err
}

Expand Down
9 changes: 9 additions & 0 deletions releases/v0.1.22.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
k6registry `v0.1.22` is here 🎉!

This is an internal maintenance release.

**Retry git pull on error**

In the git working directory, the file permissions are changed to make the cache persistent in GitHub action mode. As a consequence, the git pull operation will fail (if permissions have actually been changed).

To fix this, if the pull operation fails, the pull operation is repeated after a forced checkout operation.

0 comments on commit d851d0e

Please sign in to comment.