Your Trusted Companion
Through our innovative diary writing web application, we hope to empower individuals to cultivate a lifelong habit of self-reflection and personal growth. We strive to provide a secure and private environment for users to express their deepest thoughts and emotions, reflect on their experiences, and gain insights into their lives. Our mission is to inspire and support people on their journey of self-discovery, fostering greater self-awareness and assisting them in living more fulfilling and meaningful lives.
You should have installed Python and PostgreSQL inorder to run the project.
git clone https://github.com/Abekaesh/Diary.git
cd Diary
python3 -m venv venv
source venv/bin/activate
pip install flask
pip install flask_session
pip install psycopg2-binary
pip install functools
sudo -i -U postgres
psql
CREATE DATABASE diary;
\c diary
CREATE TABLE users (
user_id INT PRIMARY KEY,
name VARCHAR(255),
email VARCHAR(255),
password VARCHAR(255)
);
CREATE TABLE diary_entry (
entry_id INT PRIMARY KEY,
user_id INT,
entry_text TEXT,
created_at DATE DEFAULT CURRENT_DATE,
FOREIGN KEY (user_id) REFERENCES users(user_id)
);
CREATE TABLE tags (
tag_id INT PRIMARY KEY,
tag_name VARCHAR(255)
);
CREATE TABLE entry_tag (
entry_id INT,
tag_id INT,
PRIMARY KEY (entry_id, tag_id),
FOREIGN KEY (entry_id) REFERENCES diary_entry(entry_id),
FOREIGN KEY (tag_id) REFERENCES tags(tag_id)
);
python3 -m flask run