maintainers/scripts/update.nix: auto-detect attrPath

This commit is contained in:
Jan Tojnar 2020-09-20 00:20:34 +02:00
parent b351de0971
commit c21a85c6a0
No known key found for this signature in database
GPG key ID: 7FAB2A15F7A607A4
4 changed files with 32 additions and 32 deletions

View file

@ -91,8 +91,8 @@ async def check_changes(package: Dict, worktree: str, update_info: str):
if len(changes) == 1:
# Dynamic data from updater take precedence over static data from passthru.updateScript.
if 'attrPath' not in changes[0]:
if 'attrPath' in package:
changes[0]['attrPath'] = package['attrPath']
# update.nix is always passing attrPath
changes[0]['attrPath'] = package['attrPath']
if 'oldVersion' not in changes[0]:
# update.nix is always passing oldVersion