https://github.com/tardo/gmg
Web application to analyze the content of public forums
https://github.com/tardo/gmg
Last synced: 2 months ago
JSON representation
Web application to analyze the content of public forums
- Host: GitHub
- URL: https://github.com/tardo/gmg
- Owner: Tardo
- Created: 2022-05-07T21:07:26.000Z (about 3 years ago)
- Default Branch: master
- Last Pushed: 2023-02-16T06:03:34.000Z (over 2 years ago)
- Last Synced: 2025-02-12T23:41:29.328Z (4 months ago)
- Language: Python
- Size: 1.11 MB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- Roadmap: ROADMAP.md
Awesome Lists containing this project
README
# Give Me the Garbage
_Web application to analyze the content of public forums_
### INSTALLATION
#### Automatic Mode (recommended)
```shell
copier copy gh:Tardo/gmg-template gmg
cd gmg
docker-compose up
```See 'gmg-template' repo for more info: https://github.com/tardo/gmg-template
#### Manual Mode
```shell
python -m pip install --upgrade pip
pip install poetry
curl -L https://raw.githubusercontent.com/tj/n/master/bin/n -o n
bash n latest
npm install --global npm
npm install --global postcss postcss-cli rollup
git clone [email protected]:Tardo/gmg.git
cd gmg
poetry install
poetry run npm install
poetry run npm run srv:dev
```Now can visit: http://localhost:8000
\*\* Check the `gmg.conf` file to enable various debug options. You will need
restart the service every time you edit this file.### Translations
#### Add a new language
\*\*\* _You will need install 'pybabel'_
\*\* Do this using the project directory!
- Generate .pot file
```shell
pybabel extract -F babel.cfg -o messages.pot .
```- Generate folder structure and .po file (Omit if you already do it)
```shell
pybabel init -i messages.pot -d translations -l
```#### Update translations with new strings
```shell
poetry run npm run upd:translations
```- Edit .po file(s) using for example '[poedit](http://poedit.net/download)'
- Update again to compile .mo with the lastest changes:
```shell
poetry run npm run upd:translations
```### Migrate Database Changes
1. Create commit
```shell
poetry run flask db migrate -m "COMMIT MESSAGE"
```3. Review migrations/versions/...py script
4. Apply the changes
```shell
poetry run flask db upgrade
```### Possible Problems
- Get the exception `UnkownTimeZoneError`: To fix this configure the time zone
of your system: `dpkg-reconfigure tzdata`