mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
maven_artifact: check whether snapshot is the latest snapshot
This commit is contained in:
parent
d24f02fd39
commit
5f743c4fdc
1 changed files with 4 additions and 1 deletions
|
@ -332,7 +332,10 @@ def main():
|
||||||
if os.path.isdir(dest):
|
if os.path.isdir(dest):
|
||||||
dest = dest + "/" + artifact_id + "-" + version + "." + extension
|
dest = dest + "/" + artifact_id + "-" + version + "." + extension
|
||||||
if os.path.lexists(dest):
|
if os.path.lexists(dest):
|
||||||
prev_state = "present"
|
if not artifact.is_snapshot():
|
||||||
|
prev_state = "present"
|
||||||
|
elif downloader.verify_md5(dest, downloader.find_uri_for_artifact(artifact) + '.md5'):
|
||||||
|
prev_state = "present"
|
||||||
else:
|
else:
|
||||||
path = os.path.dirname(dest)
|
path = os.path.dirname(dest)
|
||||||
if not os.path.exists(path):
|
if not os.path.exists(path):
|
||||||
|
|
Loading…
Reference in a new issue