Princeton Courses is a web app that you can run on any modern computer. Follow these instructions to run an installation of Princeton Courses on your computer.
- To run Princeton Courses on a computer, you must have Node.js and the Heroku CLI (command line interface) installed. If running both
node -vandheroku -vreturns a reasonable-looking version number, then these are correctly installed. - Clone the Princeton Courses git repository to your computer by running
git clone https://github.com/sebthedev/PrincetonCourses.gitor by using the GitHub app. cdinto your clone of the repository and runnpm installto install Princeton Courses’ dependencies.- In this folder, create a file named
.envwhich will be used to store environment variables. Add a new line to this file with the textMONGODB_URI='DATABASE_URL'whereDATABASE_URLis replaced with themongodb://address of your MongoDB server and database. If you don’t have a MongoDB database already, you can host a database locally on your computer (instructions) or use a service like MongoDB Atlas. Save this file. - Populate your database with the details about all the courses by running the following commands. For the current importer workflow, GitHub Actions instructions, and dry-run limitations, see importingData.md.
node importers/importBasicCourseDetails.jsnode importers/scrapeEvaluations.js(Press the return key when prompted.)node importers/importDepartments.jsnode importers/insertMostRecentScoreIntoUnevaluatedSemesters.jsnode importers/setNewCourseFlag.js