Skip to content

Commit

Permalink
Remove duplicate targets in ios/BUILD.gn (#514)
Browse files Browse the repository at this point in the history
  • Loading branch information
xiaoyuin committed Nov 1, 2022
1 parent 342b1dc commit 0e6bb78
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions importer/process_ios_assets.py
Expand Up @@ -197,8 +197,13 @@ def process_assets():

gn_file.write("import(\"//build/config/ios/asset_catalog.gni\")\n\n")

imageset_names = set()
for file_name in file_names:
imageset_name = get_icon_name(file_name)
# GN targets do not allow duplicate names
if imageset_name in imageset_names:
continue
imageset_names.add(imageset_name)
imageset_folder_path = ios_directory + '/FluentIcons/Assets/IconAssets.xcassets/' + imageset_name + '.imageset'

gn_file.write("imageset(\"{}\")".format(imageset_name) + " {\n")
Expand Down

0 comments on commit 0e6bb78

Please sign in to comment.