mirror of
https://gitlab.com/dslackw/slpkg.git
synced 2025-01-30 20:34:38 +01:00
fix alien repository checksums
This commit is contained in:
parent
a49fae0225
commit
b3b2058c06
1 changed files with 4 additions and 2 deletions
|
@ -31,7 +31,7 @@ def pkg_checksum(binary, repo):
|
||||||
'''
|
'''
|
||||||
Return checksum from CHECKSUMS.md5 file by repository
|
Return checksum from CHECKSUMS.md5 file by repository
|
||||||
'''
|
'''
|
||||||
md5 = "None"
|
md5, end = "None", "/"
|
||||||
if repo == "slack_patches" and _m.slack_rel == "stable":
|
if repo == "slack_patches" and _m.slack_rel == "stable":
|
||||||
CHECKSUMS_md5 = URL(mirrors("CHECKSUMS.md5", "patches/")).reading()
|
CHECKSUMS_md5 = URL(mirrors("CHECKSUMS.md5", "patches/")).reading()
|
||||||
elif repo == "slack_patches" and _m.slack_rel == "current":
|
elif repo == "slack_patches" and _m.slack_rel == "current":
|
||||||
|
@ -43,7 +43,9 @@ def pkg_checksum(binary, repo):
|
||||||
f = open(lib, "r")
|
f = open(lib, "r")
|
||||||
CHECKSUMS_md5 = f.read()
|
CHECKSUMS_md5 = f.read()
|
||||||
f.close()
|
f.close()
|
||||||
|
if repo == "alien":
|
||||||
|
end = ""
|
||||||
for line in CHECKSUMS_md5.splitlines():
|
for line in CHECKSUMS_md5.splitlines():
|
||||||
if line.split('/')[-1] == binary:
|
if line.endswith("%s%s" % (end, binary)):
|
||||||
md5 = line.split()[0]
|
md5 = line.split()[0]
|
||||||
return md5
|
return md5
|
||||||
|
|
Loading…
Add table
Reference in a new issue