Skip to content

ystv/internal-site

This branch is 321 commits behind main.

Folders and files

NameName
Last commit message
Last commit date

Latest commit

fcdacc2 · Jan 28, 2024
Oct 8, 2023
Jul 12, 2023
Sep 21, 2023
Oct 10, 2023
Jan 28, 2024
Jan 25, 2024
Dec 12, 2023
Jan 25, 2024
Jan 25, 2024
Sep 21, 2023
Sep 20, 2023
Sep 21, 2023
Jan 12, 2024
Sep 21, 2023
Sep 20, 2023
Oct 1, 2023
Jul 14, 2023
Jul 12, 2023
Oct 2, 2023
Jan 13, 2024
Dec 12, 2023
Oct 10, 2023
Nov 2, 2023
Jan 28, 2024
Oct 9, 2023
Oct 23, 2023
Oct 19, 2023
Oct 19, 2023
Oct 19, 2023
Oct 9, 2023
Oct 19, 2023
Jan 28, 2024

Repository files navigation

YSTV Calendar

This is the repo for https://internal.ystv.co.uk. (Don't question the name.)

Getting Started

To set up a local copy of the new calendar, you will need

Then, clone this repository:

git clone [email protected]:ystv/experimental-hypothetical-new-internal-site-idea.git

In the new folder, copy the .env file to .env.local.

Then run yarn to install all the dependencies.

You will also need to set up the following:

Postgres Database

Once you have PostgreSQL installed, run createdb calendar_2023.

Now run yarn prisma:migrateDev to set up the database tables. If you get a permissions error, check your PostgreSQL authentication settings - you should have a local all all peer line in your pg_hba.conf. You may also need to run yarn prisma:seed to set up initial data.

Google OAuth Keys

Go to https://console.developers.google.com and create a new project. Go to "OAuth Consent Screen" and fill out all the information (it doesn't matter for testing) - make sure you select "External" as the very first step. Then go to "Credentials". Create an OAuth Client ID, select "Web Application" as the type, and copy the Client ID.

Edit your .env.local and add the Client ID on the GOOGLE_CLIENT_ID= line.

Slack Integration (Optional)

If you would like to setup the optional slack integration, head over to the Slack Setup docs to get started.

Running

Finally, run the development server:

yarn dev

Open http://localhost:3000 with your browser to see the result.

To get admin permissions, sign in once with Google, then run yarn do promoteUser <your email>.

Structure

  • app/ - pages
  • features/ - business logic functinality
  • lib/ - low level utilities (auth, db, etc.)

Development

We use Linear to track issues - to access it, sign in with your @ystv.co.uk Google account (ask a Computing Team member if you don't have one).