Command-line interface for managing (pseudo) employees, managers, and departments in a MySQL database.
-
Add departments, roles, employees
-
View departments, roles, employees
-
Update employee roles
-
Update employee managers
- Clone the repo or download the code as a zip.
git clone https://github.com/LemonPocky/coding-quiz.git
- If downloaded as zip, unzip the contents. Place the folder in an easily accessible location on your computer.
- Install MySQL if necessary. Import schema.sql and seed.sql into MySQL to create and populate the database.
mysql -u <username> -p employee_cms_db < schema.sql
mysql -u <username> -p employee_cms_db < seed.sql
Note: You do not need to run seed.sql if you have your own data to insert into the database.
- While in the root folder, run "npm install".
npm install
- Make a copy of ".env.EXAMPLE" and rename it to ".env". Fill out the username and password details.
Run the program with:
node index.js