Skip to content

Commit

Permalink
cmd/distpack: test for .DS_Store files in all directories
Browse files Browse the repository at this point in the history
macOS may write a .DS_Store file to any directory at any time in
the general case, unfortunately. Expand test rules to catch them
no matter where they may appear.

For #24904.

Change-Id: I98a2bb5d0ae2ab3a191ff87b33d6f8048ca39aa8
Reviewed-on: https://go-review.googlesource.com/c/go/+/514898
Reviewed-by: Russ Cox <rsc@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Gopher Robot <gobot@golang.org>
Auto-Submit: Dmitri Shuralyov <dmitshur@golang.org>
  • Loading branch information
dmitshur authored and gopherbot committed Aug 1, 2023
1 parent f719de0 commit fb6f38d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/cmd/distpack/test.go
Expand Up @@ -26,7 +26,7 @@ var srcRules = []testRule{
{name: "go/VERSION"},
{name: "go/src/cmd/go/main.go"},
{name: "go/src/bytes/bytes.go"},
{name: "go/.DS_Store", exclude: true},
{name: "**/.DS_Store", exclude: true},
{name: "go/.git", exclude: true},
{name: "go/.gitattributes", exclude: true},
{name: "go/.github", exclude: true},
Expand All @@ -44,7 +44,7 @@ var zipRules = []testRule{
{name: "go/src/cmd/go/main.go"},
{name: "go/src/bytes/bytes.go"},

{name: "go/.DS_Store", exclude: true},
{name: "**/.DS_Store", exclude: true},
{name: "go/.git", exclude: true},
{name: "go/.gitattributes", exclude: true},
{name: "go/.github", exclude: true},
Expand Down Expand Up @@ -73,7 +73,7 @@ var modRules = []testRule{
{name: "golang.org/toolchain@*/src/cmd/go/main.go"},
{name: "golang.org/toolchain@*/src/bytes/bytes.go"},

{name: "golang.org/toolchain@*/.DS_Store", exclude: true},
{name: "**/.DS_Store", exclude: true},
{name: "golang.org/toolchain@*/.git", exclude: true},
{name: "golang.org/toolchain@*/.gitattributes", exclude: true},
{name: "golang.org/toolchain@*/.github", exclude: true},
Expand Down

0 comments on commit fb6f38d

Please sign in to comment.