Skip to content

Commit

Permalink
chore: Bump github.com/twpayne/go-vfs to v5
Browse files Browse the repository at this point in the history
  • Loading branch information
twpayne committed Jan 22, 2024
1 parent ecf706d commit f0a7529
Show file tree
Hide file tree
Showing 50 changed files with 179 additions and 177 deletions.
2 changes: 1 addition & 1 deletion .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ linters-settings:
- github\.com/twpayne/chezmoi/v2/internal/chezmoi\.SourceStateEntry
- github\.com/twpayne/chezmoi/v2/internal/chezmoi\.System
- github\.com/twpayne/chezmoi/v2/internal/chezmoi\.TargetStateEntry
- github\.com/twpayne/go-vfs/v4\.FS
- github\.com/twpayne/go-vfs/v5\.FS
- stdlib
misspell:
locale: US
Expand Down
2 changes: 1 addition & 1 deletion assets/chezmoi.io/docs/developer/testing.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ chezmoi uses multiple levels of testing:
`internal/chezmoi/*_test.go`.

2. Filesystem integration tests, using `testing` and
[`github.com/twpayne/go-vfs/v4`](https://pkg.go.dev/github.com/twpayne/go-vfs/v4),
[`github.com/twpayne/go-vfs/v5`](https://pkg.go.dev/github.com/twpayne/go-vfs/v4),
test chezmoi's effects on the filesystem. This include some tests in
`internal/chezmoi/*_test.go`, and higher level command tests in
`internal/cmd/*cmd_test.go`.
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ require (
github.com/tailscale/hujson v0.0.0-20221223112325-20486734a56a
github.com/twpayne/go-pinentry v0.3.0
github.com/twpayne/go-shell v0.4.0
github.com/twpayne/go-vfs/v4 v4.3.0
github.com/twpayne/go-vfs/v5 v5.0.1
github.com/twpayne/go-xdg/v6 v6.1.2
github.com/ulikunitz/xz v0.5.11
github.com/withfig/autocomplete-tools/integrations/cobra v1.2.1
Expand Down
2 changes: 2 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -431,6 +431,8 @@ github.com/twpayne/go-shell v0.4.0 h1:RAAMbjEj7mcwDdwC7SiFHGUKR+WDAURU6mnyd3r2p2
github.com/twpayne/go-shell v0.4.0/go.mod h1:MP3aUA0TQ3IGoJc15ahjb+7A7wZH4NeGrvLZ/aFQsHc=
github.com/twpayne/go-vfs/v4 v4.3.0 h1:rTqFzzOQ/6ESKTSiwVubHlCBedJDOhQyVSnw8rQNZhU=
github.com/twpayne/go-vfs/v4 v4.3.0/go.mod h1:tq2UVhnUepesc0lSnPJH/jQ8HruGhzwZe2r5kDFpEIw=
github.com/twpayne/go-vfs/v5 v5.0.1 h1:5g2H6D/r4BlukZn21ysaPqracmsNb2lRCoiJt55tjqk=
github.com/twpayne/go-vfs/v5 v5.0.1/go.mod h1:x4tZII+nP25/KlZ2lTPXxnTiS1ZSE10yNJ/mGiBoR8s=
github.com/twpayne/go-xdg/v6 v6.1.2 h1:KbfCsAP4bBR5+dzfTIh/M9onOPCSqlYsIER79IKwt+s=
github.com/twpayne/go-xdg/v6 v6.1.2/go.mod h1:BFHclQaEPLq3jRRYjf1PdFzUEvAfPeLjNymIO/7/7o4=
github.com/ulikunitz/xz v0.5.11 h1:kpFauv27b6ynzBNT/Xy+1k+fK4WswhN/6PN5WhFAGw8=
Expand Down
10 changes: 5 additions & 5 deletions internal/chezmoi/boltpersistentstate_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import (
"testing"

"github.com/alecthomas/assert/v2"
"github.com/twpayne/go-vfs/v4"
"github.com/twpayne/go-vfs/v4/vfst"
"github.com/twpayne/go-vfs/v5"
"github.com/twpayne/go-vfs/v5/vfst"

"github.com/twpayne/chezmoi/v2/internal/chezmoitest"
)
Expand All @@ -32,7 +32,7 @@ func TestBoltPersistentState(t *testing.T) {
assert.NoError(t, err)
vfst.RunTests(t, fileSystem, "",
vfst.TestPath(path.String(),
vfst.TestDoesNotExist,
vfst.TestDoesNotExist(),
),
)
assert.Equal(t, []byte(nil), actualValue)
Expand All @@ -42,15 +42,15 @@ func TestBoltPersistentState(t *testing.T) {
assert.NoError(t, b1.Delete(bucket, key))
vfst.RunTests(t, fileSystem, "",
vfst.TestPath(path.String(),
vfst.TestDoesNotExist,
vfst.TestDoesNotExist(),
),
)

// Test that setting a key creates the state.
assert.NoError(t, b1.Set(bucket, key, value))
vfst.RunTests(t, fileSystem, "",
vfst.TestPath(path.String(),
vfst.TestModeIsRegular,
vfst.TestModeIsRegular(),
),
)
actualValue, err = b1.Get(bucket, key)
Expand Down
2 changes: 1 addition & 1 deletion internal/chezmoi/chezmoi.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import (
"strings"

"github.com/spf13/cobra"
vfs "github.com/twpayne/go-vfs/v4"
vfs "github.com/twpayne/go-vfs/v5"
"golang.org/x/crypto/ripemd160" //nolint:staticcheck
)

Expand Down
2 changes: 1 addition & 1 deletion internal/chezmoi/chezmoi_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (
"github.com/rs/zerolog"
"github.com/rs/zerolog/log"
"github.com/rs/zerolog/pkgerrors"
"github.com/twpayne/go-vfs/v4"
"github.com/twpayne/go-vfs/v5"

"github.com/twpayne/chezmoi/v2/internal/chezmoitest"
)
Expand Down
2 changes: 1 addition & 1 deletion internal/chezmoi/data.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import (
"strings"
"unicode"

"github.com/twpayne/go-vfs/v4"
"github.com/twpayne/go-vfs/v5"
)

// Kernel returns the kernel information parsed from /proc/sys/kernel.
Expand Down
4 changes: 2 additions & 2 deletions internal/chezmoi/data_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import (
"testing"

"github.com/alecthomas/assert/v2"
"github.com/twpayne/go-vfs/v4"
"github.com/twpayne/go-vfs/v4/vfst"
"github.com/twpayne/go-vfs/v5"
"github.com/twpayne/go-vfs/v5/vfst"

"github.com/twpayne/chezmoi/v2/internal/chezmoitest"
)
Expand Down
2 changes: 1 addition & 1 deletion internal/chezmoi/debugsystem.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"time"

"github.com/rs/zerolog"
vfs "github.com/twpayne/go-vfs/v4"
vfs "github.com/twpayne/go-vfs/v5"

"github.com/twpayne/chezmoi/v2/internal/chezmoilog"
)
Expand Down
2 changes: 1 addition & 1 deletion internal/chezmoi/dryrunsystem.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"os/exec"
"time"

vfs "github.com/twpayne/go-vfs/v4"
vfs "github.com/twpayne/go-vfs/v5"
)

// DryRunSystem is an System that reads from, but does not write to, to
Expand Down
2 changes: 1 addition & 1 deletion internal/chezmoi/dumpsystem.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
"io/fs"
"os/exec"

vfs "github.com/twpayne/go-vfs/v4"
vfs "github.com/twpayne/go-vfs/v5"
)

// A dataType is a data type.
Expand Down
2 changes: 1 addition & 1 deletion internal/chezmoi/dumpsystem_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (

"github.com/alecthomas/assert/v2"
"github.com/coreos/go-semver/semver"
vfs "github.com/twpayne/go-vfs/v4"
vfs "github.com/twpayne/go-vfs/v5"

"github.com/twpayne/chezmoi/v2/internal/chezmoitest"
)
Expand Down
2 changes: 1 addition & 1 deletion internal/chezmoi/erroronwritesystem.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"os/exec"
"time"

vfs "github.com/twpayne/go-vfs/v4"
vfs "github.com/twpayne/go-vfs/v5"
)

// An ErrorOnWriteSystem is an System that passes reads to the wrapped System
Expand Down
2 changes: 1 addition & 1 deletion internal/chezmoi/externaldiffsystem.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import (
"text/template"
"time"

vfs "github.com/twpayne/go-vfs/v4"
vfs "github.com/twpayne/go-vfs/v5"

"github.com/twpayne/chezmoi/v2/internal/chezmoilog"
)
Expand Down
2 changes: 1 addition & 1 deletion internal/chezmoi/gitdiffsystem.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import (
"github.com/go-git/go-git/v5/plumbing"
"github.com/go-git/go-git/v5/plumbing/filemode"
"github.com/go-git/go-git/v5/plumbing/format/diff"
vfs "github.com/twpayne/go-vfs/v4"
vfs "github.com/twpayne/go-vfs/v5"
)

// A TextConvFunc converts the contents of a file into a more human-readable form.
Expand Down
2 changes: 1 addition & 1 deletion internal/chezmoi/glob.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
"io/fs"

"github.com/bmatcuk/doublestar/v4"
vfs "github.com/twpayne/go-vfs/v4"
vfs "github.com/twpayne/go-vfs/v5"
)

// A lstatFS implements io/fs.StatFS but uses Lstat instead of Stat.
Expand Down
2 changes: 1 addition & 1 deletion internal/chezmoi/patternset.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (

"github.com/bmatcuk/doublestar/v4"
"github.com/rs/zerolog"
vfs "github.com/twpayne/go-vfs/v4"
vfs "github.com/twpayne/go-vfs/v5"
)

type patternSetIncludeType bool
Expand Down
2 changes: 1 addition & 1 deletion internal/chezmoi/patternset_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
"testing"

"github.com/alecthomas/assert/v2"
vfs "github.com/twpayne/go-vfs/v4"
vfs "github.com/twpayne/go-vfs/v5"

"github.com/twpayne/chezmoi/v2/internal/chezmoitest"
)
Expand Down
2 changes: 1 addition & 1 deletion internal/chezmoi/readonlysystem.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package chezmoi
import (
"io/fs"

vfs "github.com/twpayne/go-vfs/v4"
vfs "github.com/twpayne/go-vfs/v5"
)

// A ReadOnlySystem is a system that may only be read from.
Expand Down
2 changes: 1 addition & 1 deletion internal/chezmoi/realsystem.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (
"runtime"
"time"

vfs "github.com/twpayne/go-vfs/v4"
vfs "github.com/twpayne/go-vfs/v5"

"github.com/twpayne/chezmoi/v2/internal/chezmoierrors"
"github.com/twpayne/chezmoi/v2/internal/chezmoilog"
Expand Down
2 changes: 1 addition & 1 deletion internal/chezmoi/realsystem_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"testing"

"github.com/alecthomas/assert/v2"
vfs "github.com/twpayne/go-vfs/v4"
vfs "github.com/twpayne/go-vfs/v5"

"github.com/twpayne/chezmoi/v2/internal/chezmoitest"
)
Expand Down
2 changes: 1 addition & 1 deletion internal/chezmoi/realsystem_unix.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import (
"syscall"

"github.com/google/renameio/v2"
vfs "github.com/twpayne/go-vfs/v4"
vfs "github.com/twpayne/go-vfs/v5"

"github.com/twpayne/chezmoi/v2/internal/chezmoierrors"
)
Expand Down
2 changes: 1 addition & 1 deletion internal/chezmoi/realsystem_windows.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"path/filepath"
"sync"

vfs "github.com/twpayne/go-vfs/v4"
vfs "github.com/twpayne/go-vfs/v5"
)

// An RealSystem is a System that writes to a filesystem and executes scripts.
Expand Down
Loading

0 comments on commit f0a7529

Please sign in to comment.