diff --git a/CHANGELOG.md b/CHANGELOG.md index 3f50825e..76f368ed 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,6 +11,8 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). ### Improvements - AUR: - Optional dependencies are not checked by default in their installation popup. +- Flatpak: + - History panel now shows formatted dates - History panel can now me maximized, minimized and allows to copy column content. - Minor UI improvements diff --git a/bauh/gems/flatpak/flatpak.py b/bauh/gems/flatpak/flatpak.py index c1a00124..13f6ca04 100755 --- a/bauh/gems/flatpak/flatpak.py +++ b/bauh/gems/flatpak/flatpak.py @@ -1,5 +1,6 @@ import re import subprocess +from datetime import datetime from io import StringIO from typing import List @@ -196,7 +197,11 @@ def get_app_commits_data(app_ref: str, origin: str) -> List[dict]: commit = {} for idx, data in enumerate(res): - commit[data[0].strip().lower()] = data[1].strip() + attr = data[0].strip().lower() + commit[attr] = data[1].strip() + + if attr == 'date': + commit[attr] = datetime.strptime(commit[attr], '%Y-%m-%d %H:%M:%S +0000') if (idx + 1) % 3 == 0: commits.append(commit)