diff --git a/Frontend/env-example b/Frontend/env-example new file mode 100644 index 0000000..407c780 --- /dev/null +++ b/Frontend/env-example @@ -0,0 +1,2 @@ +VITE_SUPABASE_URL=https://your-project.supabase.co +VITE_SUPABASE_ANON_KEY=your-anon-key-here \ No newline at end of file diff --git a/README.md b/README.md index 22a0d8a..b99da38 100644 --- a/README.md +++ b/README.md @@ -86,56 +86,58 @@ Ensure you have the following installed: ```sh git clone https://github.com/AOSSIE-Org/InPact.git cd inpact - ``` -#### 2. Install Frontend Dependencies +#### 2. Frontend Setup +1. Navigate to the frontend directory: ```sh -cd Frontend -npm install +cd frontend ``` -#### 3. Install Backend Dependencies - +2. Install dependencies: ```sh -cd Backend -pip install -r requirements.txt +npm install ``` -#### 4. Backend Setup +3. Create a `.env` file using `.env.example` file: -1. Navigate to the backend directory: +4. Get your Supabase credentials: + - Go to [Supabase](https://supabase.com/) + - Log in and create a new project (or use existing) + - Go to Project Settings -> API + - Copy the "Project URL" and paste it as VITE_SUPABASE_URL + - Copy the "anon public" key and paste it as VITE_SUPABASE_ANON_KEY + +#### 3. Backend Setup + +1. Navigate to the backend directory: ```sh -cd backend +cd ../backend ``` -2. Download the required dependencies: - +2. Install dependencies: ```sh pip install -r requirements.txt ``` 3. Start the redis server using docker: - ```sh docker compose up -d ``` 4. Navigate to the app directory: - ```sh cd app ``` +5. Create a `.env` file using `.env.example` as a reference. -5. Create a `.env` file using `.env-example` as a reference. 6. Obtain Supabase credentials: - - Go to [Supabase](https://supabase.com/) - - Log in and create a new project. - - Click on the project and remember the project password. - - Go to the **Connect** section at the top. + - Log in and create a new project + - Click on the project and remember the project password + - Go to the **Connect** section at the top - Select **SQLAlchemy** and copy the connection string: ```sh @@ -158,29 +160,25 @@ cd app dbname=postgres ``` - - Paste this in the `.env` file. - 7. Get the Groq API key: - - Visit [Groq Console](https://console.groq.com/) - - Create an API key and paste it into the `.env` file. + - Create an API key and paste it into the `.env` file 8. Start the backend server: - ```sh uvicorn main:app --reload ``` -#### 5. Start Development Servers +#### 4. Start Development Servers - **Frontend**: +1. Start the frontend server (from the frontend directory): ```sh npm run dev ``` -- **Backend**: - +2. Start the backend server (from the backend/app directory): ```sh uvicorn main:app --reload ```