You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
lkrsnik 71de08ffed
Updated visuals and expanded website.
3 months ago
static Updated visuals and expanded website. 3 months ago
templates Updated visuals and expanded website. 3 months ago
translations Updated visuals and expanded website. 3 months ago
.gitignore Updated index page + Added about and result pages 6 months ago
Dockerfile Updated visuals and expanded website. 3 months ago
LICENSE Added licence 6 months ago
README.md Updated visuals and expanded website. 3 months ago
app.py Updated visuals and expanded website. 3 months ago
babel.cfg Updated visuals and expanded website. 3 months ago
gui.py Initial commit 8 months ago
messages.pot Updated visuals and expanded website. 3 months ago
requirements.txt Updated visuals and expanded website. 3 months ago
setup.py Updated visuals and expanded website. 3 months ago

README.md

Translations

Create .pot file

pybabel extract -F babel.cfg -o messages.pot .

Create language .po files

pybabel init -i messages.pot -d translations -l en pybabel init -i messages.pot -d translations -l sl

Compile changes

pybabel compile -d translations

Update commands

Install gettext (sudo apt install gettext)

pybabel extract -F babel.cfg -o messages.pot .
msgmerge translations/sl/LC_MESSAGES/messages.po messages.pot -o translations/sl/LC_MESSAGES/messages.po
msgmerge translations/en/LC_MESSAGES/messages.po messages.pot -o translations/en/LC_MESSAGES/messages.po

# check and delete fuzzy in .po files
pybabel compile -d translations

Deployment

docker build -t my-flask-app . docker run -p 8080:8080 my-flask-app