Welcome to FoodFlow Protocol! This is a complete software platform that helps farmers sell directly to citizens, check crop prices, and get AI tips for their crops.
This guide is written for anyone. You do not need to be a programmer to run this project. Just follow these steps exactly!
Before we start, your computer needs two free tools to run this software: Node.js and Git make sure to install them.
- Go to this website: https://nodejs.org/
- Download the LTS Version (Recommended for Most Users).
- Run the installer and click "Next" until it finishes.
- To check if it worked:
- Press
Windows Key + R - Type
cmdand hit Enter. - Type
node -vand hit Enter. You should see a number likev18.x.xorv20.x.x.
- Press
- Go to: https://git-scm.com/download/win
- Download "64-bit Git for Windows Setup".
- Install it with default settings.
Now let's get the FoodFlow code running on your computer.
If you are reading this on GitHub:
- Click the distinct green Code button at the top right.
- Select Download ZIP.
- Extract the ZIP folder to your Desktop. Rename the folder to
FoodFlow.
We will use command lines to start the app. It looks scary, but it's easy!
- Open the
FoodFlowfolder you just extracted. - Right-click anywhere in empty space inside the folder -> select "Open in Terminal" (or "Open PowerShell window here").
Copy and paste these commands one by one into that terminal window. Press Enter after each line:
cd backend
npm installWait for it to finish downloading...
Now, let's set up the database (where user data is stored):
npx prisma migrate dev
node prisma/seed.jsYou should see a message saying "Seeding finished".
Now we need a second terminal for the visual part.
- Go back to your
FoodFlowfolder in File Explorer. - Right-click again -> "Open in Terminal".
- Type these commands:
cd frontend
npm installFor Windows:
- Double-click
start_app.bat.
For Mac / Linux / WSL:
- Open Terminal in the folder.
- Run:
sh start_app.sh
It will automatically open everything for you!
If the script doesn't work, do this manually:
- Start Backend (Terminal 1):
cd backend npm install # (Only if you see "Module not found" errors) npx prisma generate # (Fixes prisma client issues) npm start
- Start Frontend (Terminal 2):
cd frontend npm install # (Only if first time) npm run dev
It will say something like: Local: http://localhost:5173/
- Open Chrome/Edge and type
http://localhost:5173.
🎉 Congratulations! You are now running FoodFlow Protocol locally!
To upload your latest changes to GitHub "instantly", verify you have Git installed and run these commands in your main terminal:
Windows (One-Click):
Double-click upload_changes.bat (if created) or run:
git add .
git commit -m "Update code"
git pushMac / Linux:
sh upload_changes.shTo test the features, use these pre-made accounts:
(Selling crops, AI analysis, Weather map)
- Email:
ravi@farmer.com - Password:
password123
(Buying, Chatting, Viewing Prices)
- Email:
priya@citizen.com - Password:
password123
Q1: The npm install command failed!
- Make sure you are connected to the internet.
- Try restarting your computer and try again.
Q2: It says "Port already in use"?
- This means the app is already running in another window.
- Find the other black terminal window and close it. Then try again.
Q3: I see a white screen or error?
- Make sure BOTH terminal windows (Backend and Frontend) are open and running. If you close the Backend window, the website won't load data.
Need more help? Contact our support team! Veeranarayana Gorantla - Linkedin