Merge pull request #2126 from webkonstantin/fix-read-only-from-working-dir

fix: Impossible to /read-only from another working directory
This commit is contained in:
paul-gauthier 2024-10-25 07:40:57 -07:00 committed by GitHub
commit b911ceaa61
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 38 additions and 1 deletions

View file

@ -1170,7 +1170,7 @@ class Commands:
# First collect all expanded paths
for pattern in filenames:
expanded_pattern = expanduser(pattern)
expanded_paths = glob.glob(expanded_pattern, recursive=True)
expanded_paths = glob.glob(expanded_pattern, recursive=True, root_dir=self.coder.root)
if not expanded_paths:
self.io.tool_error(f"No matches found for: {pattern}")
else: