Fixing deb building, putting changelog into cache for env without internet (e.g flatpak).
Some checks failed
continuous-integration/drone/push Build is failing

This commit is contained in:
Adsooi 2022-01-28 23:49:23 +01:00
parent 0e2c1bdae4
commit d0fb6e9a3a
Signed by: Ad5001
GPG key ID: EF45F9C6AFE20160
3 changed files with 18 additions and 6 deletions

View file

@ -145,6 +145,14 @@ class Helper(QObject):
@Slot()
def fetchChangelog(self):
runnable = ChangelogFetcher(self)
QThreadPool.globalInstance().start(runnable)
changelog_cache_path = path.join(path.dirname(path.realpath(__file__), "CHANGELOG.md"))
if path.exists(changelog_cache_path):
# We have a cached version of the changelog, for env that don't have access to the internet.
f = open(changelog_cache_path);
self.changelogFetched.emit("".join(f.readlines()).strip())
f.close()
else:
# Fetch it from the internet.
runnable = ChangelogFetcher(self)
^QThreadPool.globalInstance().start(runnable)