New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[wip] Fix config install not working when .git* folder is in the path #8605
Conversation
@@ -130,7 +130,7 @@ def _process_folder(config, folder, cache, output): | |||
folder = os.path.join(folder, config.source_folder) | |||
for root, dirs, files in walk(folder): | |||
dirs[:] = [d for d in dirs if d != ".git"] | |||
if ".git" in root: | |||
if os.path.join(".git", "") in root: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure if this will make a difference in the end, the line above: dirs[:] = [d for d in dirs if d != ".git"]
Is already filtering the .git folder.
Also, the new comparison will compare if .git/
is in root that will have the value my/root/path/git
so it will always be false because of the forward slash join is going to add in the end.
I don't know if I'm missing something, but is this comparison needed in the end?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you are right, I have removed that line as it looks useless and added a check in the test
Changelog: Bugfix: Fix config install not working when .git* folder is in the path.
Docs: omit
closes #8594