Skip to content

Commit

Permalink
fix path sep
Browse files Browse the repository at this point in the history
  • Loading branch information
masakitenchi committed May 18, 2024
1 parent 9e98e81 commit 7a794f5
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions update_gitattribute.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,13 +38,11 @@ def build_dict():
for cur, dirs, _ in os.walk(subdir_path):
for directory in dirs:
if 'About.xml' in os.listdir(os.path.join(cur, directory)):
path = os.path.join(cur, directory, 'About.xml').replace("\\", "/")
path = os.path.join(cur, directory, 'About.xml')
#print(path)
root = ET.parse(path).getroot()
package_id = root.find("packageId").text.lower()
folder_dict[package_id] = "/".join(
entry.path.split(os.path.sep)[0:2]
)
folder_dict[package_id] = entry.path
break


Expand Down

0 comments on commit 7a794f5

Please sign in to comment.