readme.md

This commit is contained in:
2025-07-28 22:21:43 +02:00
parent cc4a884c5c
commit 8bea2342d5
8 changed files with 41 additions and 8 deletions

View File

@@ -1,7 +1,7 @@
# Copyright (c) 2025 Martin Kayser (tebarius)
# Licensed under the MIT License. See LICENSE file in the project root.
import streamlit as st
import base64
import tools
standard_output = ('#### Um den HILFE-Text zu einzelnen Funktionen aufzurufen bitte die Funktion mit leerem'
@@ -11,15 +11,21 @@ st.set_page_config(
# we do also patching static-files of streamlit in the docker-container so bookmarks will have
# the same favicon and if posting links for example in whatsapp they will have the same title
page_title="tebarius Mysteryhelfer (web)",
page_icon="./favicon.ico",
page_icon="images/favicon.ico",
layout="wide"
)
st.logo('./logo.png', size='large')
st.logo('images/logo.png', size='large')
logo_col, title_col = st.columns([1,5])
logo_col, title_col = st.columns([1,4])
with logo_col:
st.image('./logo-mit-tb.png', width=150)
st.markdown(f'<a href="https://gitea.tebarius.duckdns.org/tebarius/Mysteryhelfer-web">'
f'<img src="data:image/png;base64,'
f'{base64.b64encode(open("images/logo-mit-tb.png", "rb").read()).decode()}" width="150">'
f'<img src="data:image/png;base64,'
f'{base64.b64encode(open("images/gitea.png", "rb").read()).decode()}" width="70">'
f'</a>',
unsafe_allow_html=True)
with title_col:
st.write('### tebarius Mysteryhelfer (web)')

View File

Before

Width:  |  Height:  |  Size: 159 KiB

After

Width:  |  Height:  |  Size: 159 KiB

BIN
app/images/gitea.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.6 KiB

View File

Before

Width:  |  Height:  |  Size: 366 KiB

After

Width:  |  Height:  |  Size: 366 KiB

View File

Before

Width:  |  Height:  |  Size: 30 KiB

After

Width:  |  Height:  |  Size: 30 KiB

View File

@@ -2608,6 +2608,7 @@ def adfgvx_dekodieren(eingabetext, pw):
ausgabetext += f"_dekodiert mit Variante 9-0,Z-A:_ \n{klartext_90za}"
return ausgabetext
# noch nicht implementierte Funktionen:
'''
def brainfuck_interpreter():
eingabetext = Eingabe.get(1.0, END)
@@ -2722,6 +2723,4 @@ den Code auszuführen.""" + "\n\n")
i = loop[-1]
i += 1
Ausgabe.insert(1.0, "".join(rv) + "\n")
'''

View File

@@ -2,5 +2,5 @@ services:
mysteryhelfer-web:
build: ./
ports:
- "80:8501"
- "8501:8501"
restart: unless-stopped

28
readme.md Normal file
View File

@@ -0,0 +1,28 @@
# <img src="./app/images/logo.png" alt="Logo" width="100" height=auto> tebarius Mysteryhelfer (web)
Dies ist die Umsetzung der [Desktop-App Mysteryhelfer](https://mysteryhelfer.tebarius.duckdns.org/) ([Sourcecode](https://gitea.tebarius.duckdns.org/tebarius/Mysteryhelfer)) als Web-App.
Für die Umsetzung kommt das Python-Framework [Streamlit](https://streamlit.io/) zum Einsatz, durch welches es mir möglich war, dieselben Funktionen zu implementieren wie sie für die Desktop-App genutzt werden. (Für die Funktionen war hier primär nur die Ausgabe anzupassen.)
Der einfachst Weg, um die App lokal laufen zu lassen, ist mit Docker, wobei ich hier mal 3 Möglichkeiten aufzeige:
1. mit vorgebautem Image:
- `docker run --rm -d -p 8501:8501 gitea.tebarius.duckdns.org/tebarius/mysteryhelfer`
2. mit vorgebautem Image und "docker compose"
- docker-compose.yml erstellen mit folgendem Inhalt:
```
services:
mysteryhelfer-web:
image: gitea.tebarius.duckdns.org/tebarius/mysteryhelfer
ports:
- "8501:8501"
restart: unless-stopped
```
- `docker compose up`
3. mit selbst gebautem Image aus dem Quellcode
- `git clone https://gitea.tebarius.duckdns.org/tebarius/Mysteryhelfer-web.git`
- `cd Mysteryhelfer-web`
- `docker compose up`
bei allen 3 Varianten ist die App anschließend im Browser unter http://127.0.0.1:8501/ aufrufbar