add commit to bottom nav
This commit is contained in:
@@ -85,10 +85,14 @@ def create_app():
|
||||
|
||||
@app.context_processor
|
||||
def inject_constants():
|
||||
commit = ""
|
||||
with open('.git/refs/heads/main') as f:
|
||||
commit = f.read().strip()
|
||||
return {
|
||||
"InfoboxIcons": InfoboxIcons,
|
||||
"InfoboxHTMLClass": InfoboxHTMLClass,
|
||||
"InfoboxKind": InfoboxKind,
|
||||
"__commit": commit,
|
||||
}
|
||||
|
||||
@app.context_processor
|
||||
|
Reference in New Issue
Block a user