This application is designed for reserving rooms at the 370J Media Commons Room.
- Google App Script: For backend scripting and integration.
- React & Google App Script: Utilizing React-Google-Apps-Script for a responsive front-end experience.
- clasp: For Google Apps Script project management and deployment.
We employ GitHub workflows for our deployment process. Pushing or merging to different branches will automatically trigger different Google App Script deploys:
main
branch: triggers the DEVELOPMENT deploy, which serves from localhost and reads/writes the development calendarsstaging
branch: triggers the STAGING deploy, which serves from the GAS project and reads/writes the development calendarsprod
branch: triggers the PRODUCTION deploy, which serves from the GAS project and reads/writes the production calendars
The NODE_ENV
environment variable controls where we serve from, and the CALENDAR_ENV
environment variable controls which calendars we use. These values are specified in the package.json
commands triggered by the workflows
Before setting up the project, ensure you have the following:
.clasprc.json
file from another developer.deploymentId
for Google Apps Script.
When developing locally, please follow the flow below.
-
Clone the Repository:
-
Configure
.clasprc.json
: Set up the.clasprc.json
file with the necessary credentials. -
Install Packages:
npm install
-
Upload Local Code to Google App Script:
npm run start
Please continue running this and execute the following command.
-
Create a New Version of Google App Script: Deploy using clasp, targeting your
deploymentId
:clasp deploy --deploymentId ${deploymentID} -d DEV_YOURNAME
-
Access the Application: You can now access the app at
https://script.google.com/a/macros/nyu.edu/s/${deploymentId}/exec
.