mirror of
https://github.com/fhswf/aki_prj23_transparenzregister.git
synced 2025-05-14 15:28:47 +02:00
Reworked the about page for a nicer version of the git hash (#283)
The git hash looks currently like this: `Build from GiT Revision: ('d3189f78c47d812f447739f97876ced01227e1fd',)` After this change it should look like this: `Build from GiT Revision: d3189f78c47d812f447739f97876ced01227e1fd`
This commit is contained in:
parent
fca53c5e0c
commit
6526549bdd
@ -25,6 +25,11 @@ def layout() -> list[html]:
|
|||||||
Returns:
|
Returns:
|
||||||
A list of html element making up this page.
|
A list of html element making up this page.
|
||||||
"""
|
"""
|
||||||
|
git_revision = os.getenv("GIT_HASH", "Running locally")
|
||||||
|
for _ in "',()":
|
||||||
|
git_revision = git_revision.replace(_, "")
|
||||||
|
|
||||||
|
git_revision = git_revision.strip()
|
||||||
return [
|
return [
|
||||||
header_elements.create_selection_header("About"),
|
header_elements.create_selection_header("About"),
|
||||||
html.H3("About Us"),
|
html.H3("About Us"),
|
||||||
@ -40,9 +45,7 @@ def layout() -> list[html]:
|
|||||||
html.Ul(
|
html.Ul(
|
||||||
[
|
[
|
||||||
html.Li(f"Software Version: {__version__}"),
|
html.Li(f"Software Version: {__version__}"),
|
||||||
html.Li(
|
html.Li(f"Build from GiT Revision: {git_revision}"),
|
||||||
f"Build from GiT Revision: {os.getenv('GIT_HASH', 'Running locally'), }"
|
|
||||||
),
|
|
||||||
]
|
]
|
||||||
),
|
),
|
||||||
]
|
]
|
||||||
|
Loading…
x
Reference in New Issue
Block a user