Skip to content

Commit 153327f

Browse files
Update README (#486)
* Revise README with setup and development details Updated the README to include setup instructions, prerequisites, and development guidelines. Signed-off-by: Daniel Miretsky <miretskyd@wit.edu> * clean up outdated info Signed-off-by: Daniel Miretsky <miretskyd@wit.edu> * wip Signed-off-by: Daniel Miretsky <miretskyd@wit.edu> * added codespace setup script and misc changes Signed-off-by: Daniel Miretsky <miretskyd@wit.edu> * Update command to use 'bash' for setup script Signed-off-by: Daniel Miretsky <miretskyd@wit.edu> * Reorganize setup instructions in README Reordered the steps for setting up Google OAuth and running the application in the README. Added a note about accessing the application URL. Signed-off-by: Daniel Miretsky <miretskyd@wit.edu> * Update README to change database setup instructions Signed-off-by: Daniel Miretsky <miretskyd@wit.edu> --------- Signed-off-by: Daniel Miretsky <miretskyd@wit.edu>
1 parent 2690fff commit 153327f

1 file changed

Lines changed: 69 additions & 22 deletions

File tree

README.md

Lines changed: 69 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,77 @@
1-
<p align="center">
2-
<img src="https://raw.githubusercontent.com/WITCodingClub/calendar/refs/heads/main/resources/W-Calendar-outlined-back-only.png" width="128" alt="WIT-calendar Icon"/>
3-
</p>
1+
# Getting Started
42

5-
<h3 align="center">
6-
<strong>WIT-Calendar</strong>
7-
</h3>
3+
This guide will walk you through setting up the application for development using GitHub Codespaces.
84

9-
<p align="center">
10-
<a href="https://calendar.witcc.dev">website</a> · <a href="https://chromewebstore.google.com/detail/wit-calendar/aceelinogfcceklkpacakdeddnaakicj">install</a> · <a href="https://stats.uptimerobot.com/QS76oPqfzz">status page</a>
11-
<br>
12-
(middle-click or ctrl/cmd+click to open in a new tab)
13-
</p>
5+
## Setup
146

15-
## Description
16-
WIT-Calendar is a Chrome extension that makes adding your classes to your calendar easy & quick!
17-
It supports all major calendars, including Google Calendar, Microsoft Outlook, and Apple Calendar.
18-
In the future, you will also be able to find "best times" to meet with fellow students, easily register for classes, and more!
7+
1. Create a new branch OR fork this repository
8+
9+
**If you create a new branch, make sure it is named properly.**
1910

20-
## How does it work?
21-
The Chrome extension gets your schedule, processes it, and then provides you with a calendar link. You can also optionally connect your Google account for automatic updates to your Google Calendar.
11+
2. Click the green "Code" button towards the right of the screen
2212

23-
You can also manage event alerts, colors, and titles from within the extension.
13+
3. Click the "Codespaces" tab at the top of the pop-up
2414

25-
## Development
26-
- See instructions for developing the extension [here](https://github.com/WITCodingClub/calendar-extension/blob/main/client/README.md).
15+
4. Click "Create codespace on `your-branch-name`"
2716

28-
- See instructions for developing the backend **(this repo)** [here](https://github.com/WITCodingClub/calendar-backend/blob/main/README.md).
17+
5. **Install dependencies:**
18+
19+
Run in a new terminal window:
20+
```bash
21+
bundle install
22+
```
23+
24+
6. **Set up Codespace:**
25+
26+
Run the following command in the terminal:
27+
28+
```bash
29+
bash bin/codespace-setup
30+
```
31+
32+
7. **Set up Rails credentials:**
33+
34+
This project uses Rails encrypted credentials for storing sensitive configuration like Google OAuth credentials and Active Record encryption keys.
35+
36+
* Uses `config/credentials/development.yml.enc`
37+
* Email @jasper [mayonej@wit.edu] for the development key to decrypt the credentials.
38+
* Paste the key into `config/credentials/development.key`
39+
40+
**Note: You'll need to create the `development.key` file. Ensure it is created in the correct directory (`config/credentials`).**
41+
42+
8. **Set up the database:**
43+
44+
```bash
45+
bin/rails db:create
46+
bin/rails db:migrate
47+
bin/rails db:seed
48+
```
49+
50+
9. **Set up Google OAuth:**
51+
52+
You will need to provide @jasper [mayonej@wit.edu] your Codespace URL to be added to the development project on Google Cloud.
53+
54+
a. In the bottom panel of your Codespace, click the Ports tab as shown below:
55+
<img width="739" height="418" alt="image" src="https://github.com/user-attachments/assets/c0c3daf6-0ce6-4384-8d4b-5d055f809f3a" />
56+
57+
b. Right click port 3000 and set the port visibility to "Public" as shown below:
58+
<img width="638" height="400" alt="image" src="https://github.com/user-attachments/assets/f71b9183-47e5-4b5c-98cb-6651b5e5f269" />
59+
60+
c. Right click the "Forwarded Address" for port 3000 and click "Copy Local Address" as shown below:
61+
<img width="1451" height="815" alt="image" src="https://github.com/user-attachments/assets/ad953767-609e-4e74-a8d8-583648f7b060" />
62+
63+
64+
10. **Run the application:**
65+
66+
```bash
67+
bin/dev
68+
```
69+
70+
This will start the web server, the background job worker, and the CSS watcher. You can access the application at `http://127.0.0.1:3000/users/sign_in` or `your-codespace-URL/users/sign_in` (see the previous step for instructions for getting your Codespace URL).
71+
72+
**Note:** If you click the "Open in Browser" on the notification that comes up within the Codespace after starting the server, you will be redirected to the root page of the server, which doesn't exist. You must manually append `/users/sign_in` to the end of the URL.
73+
74+
## Troubleshooting
75+
76+
If you run into any errors in the terminal you don't recogize, feel free to run them by @jasper [mayonej@wit.edu].
2977
30-
- See instructions for developing our landing/marketing page [here](https://github.com/WITCodingClub/calendar-website/blob/main/README.md)

0 commit comments

Comments
 (0)