Skip to content

Commit

Permalink
Updated hashing
Browse files Browse the repository at this point in the history
  • Loading branch information
StrahinjaJacimovic committed Sep 24, 2024
1 parent 4619763 commit 344858e
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion scripts/package.py
Original file line number Diff line number Diff line change
Expand Up @@ -446,7 +446,9 @@ def str2bool(v):
execute = True
for each_metadata_package in live_packages:
if live_packages[each_metadata_package]['name'] == current_package_data['name']:
execute = False
# If package has been changed, update it either way
if current_package_data['hash'] == live_packages[each_metadata_package]['hash']:
execute = False
break
if execute:
upload_result = upload_asset_to_release(args.repo, release_id, os.path.join(repo_dir, f'{current_package_data['package_rel_path']}'), args.token)
Expand All @@ -463,6 +465,8 @@ def str2bool(v):
os.makedirs(os.path.join(repo_dir, 'tmp'), exist_ok=True)
if args.package_boards:
for each_package in metadata_content['packages']:
## Always update the new package hash values
metadata_full['packages'][each_package]['hash'] = packages[each_package]['hash']
if each_package not in metadata_full['packages']:
metadata_full['packages'].update(
{
Expand Down

0 comments on commit 344858e

Please sign in to comment.