-
Notifications
You must be signed in to change notification settings - Fork 39
Getting Started
Your machine should have Yarn or Npm installed.
Note: Preferable versions
Version | |
---|---|
node | 16 |
npm | 6 |
yarn | 1.16 |
lerna | 4 |
- Check the node and npm versions by running the following commands.
node -v
npm -v
- Install lerna globally by running the following command.
npm i lerna -g
- Install yarn
npm i yarn -g
You can get your own fork/copy of Frontend by using the Fork
button.
You need to clone (download) it to a local machine using
git clone https://github.com/rudrakshi99/Farmer-Call-Center.git
This makes a local copy of the repository in your machine.
Once you have cloned the Farmer-Call-Center repository in GitHub, move to that folder first using the change directory command.
This will change the directory to a folder
cd Farmer-Call-Center
Move to this folder for all other commands.
Run the following commands to see that your local copy has a reference to your forked remote repository in GitHub
git remote -v
By running the above command, you can see that the local copy has a reference to the forked remote repository in GitHub.
origin https://github.com/Your_Username/Farmer-Call-Center.git (fetch)
origin https://github.com/Your_Username/Farmer-Call-Center.git (push)
- Install the Dependencies from
npm
$ npm i
- Run the Server and see the demo at http://localhost:3000/
$ npm start
Fork Farmer Call Center Backend repository and clone at your local
- Fork and Clone the repo using
$ git clone https://github.com/rudrakshi99/Farmer-Call-Center.git
- Change Branch to
backend
using
$ git checkout backend
Creating Virtual Environment
A virtual environment is a tool that helps keep dependencies required and the project isolated. If you wish to install a new library and write
pip install name_of_library
on the terminal without activating an environment, all the packages will be installed globally which is not a good practice if you’re working with different projects on your computer.
If this sounds a bit complicated, don’t worry so much because a virtual environment is just a directory that will contain all the necessary files for our project to run.
Installing venv (required once)
Windows
py -m pip install --user virtualenv
py -m venv env
Linux
python3 -m pip install --user virtualenv
python3 -m venv env
You have to start virtual environment everytime you start new terminal -
Windows
Using gitbash
. env/Scripts/activate
Using Powershell
. env\Scripts\activate
Linux
source env/bin/activate
Windows
pip install -r requirements.txt
Linux
pip install -r requirements.txt
Windows
py app.py
Linux
python3 app.py
deactivate