Modified readme for sqlite support

This commit is contained in:
Gourav Kumar 2022-01-10 07:51:31 +05:30
parent 8cf97d2475
commit ada26687a8
2 changed files with 7 additions and 1 deletions

View File

@ -5,7 +5,7 @@ DB_USER=abcd
DB_PWD="abcd!#$"
DB_HOST=localhost
DB_PORT=5432
DB_FILE="sample.sqlite"
DB_FILE="wordbot.sqlite"
# Keys
WORDBOT_TOKEN=0000000000:abcdefghij_kl_mn-op_qrst

View File

@ -11,6 +11,12 @@ This bot helps you learn new words for your GRE/GMAT preparations. All you have
6. Install all the addons from requirements.txt
7. Start the bot with the command `python word_bot.py`
### Database
Postgres and Sqlite databases are supported by the script natively. The included sqlite database will work out of the box. For connecting to sqlite, only the database file name is required, which is already provided in the .env.sample file. Hence, no changes to the database section will be required for sqlite.
If you wish to use PostgreSQL database, change the value of the DATABASE key in the .env file to `postgres`. Make sure you also populate the rest of the values for the database. In case of postgres, the DB_FILE variable will be ignored.
Have fun learning random words!
### To-do