iAffirm is to help encourage and spread positivity with the use of affirmative words. These affirmations are human written as users can enter their daily affirmations to the api, through a landing page. The affirmations are spread through tweets by the @iAffirmbot every 5 minutes at random.
Server: Python, Flask
To run this project, you will need to add the following environment variables to your .env file
FLASK_APP
FLASK_ENV
SECRET_KEY
DATABASE_URL
(for production environment)
DEV_DATABASE_URL
(for development environment)
TEST_DATABASE_URL
(for testing environment)
Clone the project
git clone https://github.com/LuluNwenyi/iAffirm.git
Go to the project directory
cd my-project
Create virtual environment
# FOR MACOS/LINUX
python3 -m venv venv
# FOR WINDOWS
py -m venv env
Activate virtual environment
# FOR MACOS/LINUX
source venv/bin/activate
# FOR WINDOWS
.\env\Scripts\activate
Install dependencies
pip install -r requirements.txt
Set environment variables
# FOR MACOS/LINUX
export FLASK_APP=app.py
export FLASK_ENV=development
export DEV_DATABASE_URL='sqlite:///dev.db'
export SECRET_KEY='mysecretkey'
# FOR WINDOWS
set FLASK_APP=app.py
set FLASK_ENV=development
set DEV_DATABASE_URL='sqlite:///dev.db'
set SECRET_KEY='mysecretkey'
Initiate the database
flask db init
Migrate the database changes
flask db migrate -m "commit message here"
Push the database changes
flask db upgrade
Start the server
flask run
For feedback or ideas/contributions, email [email protected].
If you'd like to support this project, feel free to buymeacoffee.