From 9b35c74f0e7626e360dfa2f00202d23b8d08b7a5 Mon Sep 17 00:00:00 2001 From: Joffrey F Date: Thu, 13 Oct 2016 16:45:01 -0700 Subject: Fix dockerignore exclusion logic on Windows Signed-off-by: Joffrey F --- docker/utils/utils.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'docker') diff --git a/docker/utils/utils.py b/docker/utils/utils.py index f2f7c26..d89aecf 100644 --- a/docker/utils/utils.py +++ b/docker/utils/utils.py @@ -209,8 +209,8 @@ def match_path(path, pattern): if pattern: pattern = os.path.relpath(pattern) - pattern_components = pattern.split('/') - path_components = path.split('/')[:len(pattern_components)] + pattern_components = pattern.split(os.path.sep) + path_components = path.split(os.path.sep)[:len(pattern_components)] return fnmatch('/'.join(path_components), pattern) -- cgit v1.2.1