utils/getdeveloperlib.py: force foward-slash for pattern matching
A message that is not in the archive (sent off-list or not yet received): [email protected]
PATCH 1/1 utils/getdeveloperlib.py: force foward-slash for pattern matching
Force relative file path resolution of DEVELOPERS file entries to use forward-slash separators since pattern matching assumes forward slashes. This is to help permit uses invoking get-developers on Platforms where os.sep may not be a forward slash.
--- utils/getdeveloperlib.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
utils/getdeveloperlib.py +4 -1
@@ -249,7 +249,10 @@ def parse_developers(): if len(dev_files) == 0: print("WARNING: '%s' doesn't match any file" % fname, file=sys.stderr) - files += [os.path.relpath(f, brpath) for f in dev_files] + for f in dev_files: + dev_file = os.path.relpath(f, brpath) + dev_file = dev_file.replace(os.sep, '/') # force unix sep + files.append(dev_file) elif line == "": if not name: continue
Signature · 6 lines
2.28.0.windows.1 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
Arnout Vandecappelle
AppliedQuoted 6 lines · James Knight
Force relative file path resolution of DEVELOPERS file entries to use forward-slash separators since pattern matching assumes forward slashes. This is to help permit uses invoking
get-developerson Platforms whereos.sepmay not be a forward slash.Signed-off-by James Knight <[email protected]>
Applied to master, thanks.
Regards,
Arnout
Quoted 11 lines
--- utils/getdeveloperlib.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)utils/getdeveloperlib.py +0
-0@@ -249,7 +249,10 @@ def parse_developers(): if len(dev_files) == 0:
utils/getdeveloperlib.py def parse_developers(): · line 258
Quoted 10 lines
utils/getdeveloperlib.py +4
-1print("WARNING: '%s' doesn't match any file" % fname, file=sys.stderr) - files += [os.path.relpath(f, brpath) for f in dev_files] + for f in dev_files: + dev_file = os.path.relpath(f, brpath) + dev_file = dev_file.replace(os.sep, '/') # force unix sep + files.append(dev_file) elif line == "": if not name: continue
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
Quoted 8 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
"James" == James Knight <[email protected]> writes:
Force relative file path resolution of DEVELOPERS file entries to use forward-slash separators since pattern matching assumes forward slashes. This is to help permit uses invoking
get-developerson Platforms whereos.sepmay not be a forward slash.Signed-off-by James Knight <[email protected]>
Committed to 2021.02.x, 2021.05.x and 2021.08.x, thanks.
Signature · 5 lines
Bye, Peter Korsgaard _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot