Release Kaleido 0.3.0 with categories, alphabet jumps and audio preferences
All checks were successful
Validate and publish Kaleido / android (push) Successful in 2m24s
All checks were successful
Validate and publish Kaleido / android (push) Successful in 2m24s
This commit is contained in:
parent
54519d4581
commit
0c62d7414e
31 changed files with 1051 additions and 80 deletions
|
|
@ -1,7 +1,7 @@
|
|||
"""Stage a locally signed APK for Git distribution and tag-triggered Forgejo releases."""
|
||||
import hashlib, json, pathlib, re, shutil, subprocess
|
||||
ROOT=pathlib.Path(__file__).resolve().parents[1]
|
||||
version=dict(l.split('=',1) for l in (ROOT/'version.properties').read_text().splitlines() if '=' in l)
|
||||
version=dict(l.split('=',1) for l in (ROOT/'version.properties').read_text(encoding='utf-8').splitlines() if '=' in l)
|
||||
apk=ROOT/'app/build/outputs/apk/release/app-release.apk'
|
||||
if not apk.exists():raise SystemExit('Run Build.ps1 -Release first.')
|
||||
out=ROOT/'distribution';out.mkdir(exist_ok=True)
|
||||
|
|
@ -11,8 +11,8 @@ digest=hashlib.sha256(apk.read_bytes()).hexdigest()
|
|||
repo='https://git.elijahkuntz.com/Elijah/Kaleido'
|
||||
tag='v'+version['versionName']
|
||||
# Only this version's section, matching the release body the app shows as notes.
|
||||
changelog=(ROOT/'CHANGELOG.md').read_text() if (ROOT/'CHANGELOG.md').exists() else ''
|
||||
changelog=(ROOT/'CHANGELOG.md').read_text(encoding='utf-8') if (ROOT/'CHANGELOG.md').exists() else ''
|
||||
section=re.search(r'^## v?'+re.escape(version['versionName'])+r'[ \t]*$(.*?)(?=^## |\Z)',changelog,re.M|re.S)
|
||||
manifest={'version':version['versionName'],'versionCode':int(version['versionCode']),'url':repo+'/raw/tag/'+tag+'/distribution/Kaleido.apk','checksumUrl':repo+'/raw/tag/'+tag+'/distribution/Kaleido.apk.sha256','notes':section.group(1).strip() if section else ''}
|
||||
(out/'latest.json').write_text(json.dumps(manifest,indent=2)+'\n')
|
||||
(out/'latest.json').write_text(json.dumps(manifest,indent=2)+'\n',encoding='utf-8')
|
||||
print('Packaged',tag,'SHA-256',digest)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue