Skip to content

Commit

Permalink
Add comment to reference the official docs
Browse files Browse the repository at this point in the history
  • Loading branch information
gesellix committed Nov 11, 2018
1 parent 80fea51 commit 388f9a7
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,9 @@ class GlobsMatcher {
static String separator = File.separatorChar

Matcher(FileSystem fileSystem, String pattern) {
// According to https://docs.docker.com/engine/reference/builder/#dockerignore-file
// and https://golang.org/pkg/path/filepath/#Clean we clean paths
// by removing trailing slashes and also by replacing slashes with the path separator.
this.pattern = pattern.replaceAll("/", "\\${separator}")
.split("\\${separator}")
.join("\\${separator}")
Expand Down

0 comments on commit 388f9a7

Please sign in to comment.