Skip to content

zainfathoni/kelas.rumahberbagi.com

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Kelas Rumah Berbagi

All Contributors

Build Status MIT License

Online course platform for Rumah Berbagi.

Documentation

Getting started

System Requirements

Development

To get started running the project locally, please follow the steps below.

First, clone the repository.

git clone https://github.com/zainfathoni/kelas.rumahberbagi.com.git

or if you're cloning using SSH.

git clone [email protected]:zainfathoni/kelas.rumahberbagi.com.git

Then go to the directory and copy the example environment variables into an ignored .env file

cd kelas.rumahberbagi.com
cp .env.example .env

Run this command to perform the initial setup while making sure that the app can run properly in your local.

npm run setup

Finally, run the development server to start developing.

npm run dev

Open http://localhost:3000 with your browser to see the result. This starts your app in development mode, rebuilding assets on file changes.

Testing

Run this command to start the end-to-end testing locally.

npm run test:e2e:run

Here's what that script does (along with the corresponding NPM commands):

  1. It builds the app (npm run build)
  2. It starts the server using the test database (npm run start:e2e)
  3. After http://localhost:3000/ is available, it starts testing (npm t a.k.a. npm test a.k.a. npm run test)

If you want, you can also manually run those commands above.

Tools & References

Tools

Code Editor

If you're using Visual Studio Code, you can install the recommended extensions for this project by using @recommended filter.

Recommended VS Code Extensions

References

Frequently Used Commands

Prisma commands

Learn more about this Prisma schema file in the docs: https://pris.ly/d/prisma-schema

Commands to know:

  • npx prisma generate - update TypeScript definitions based on this schema
  • npx prisma db push - push the schema changes to the database
  • npx prisma studio - open the Studio, which allows you to edit the schema.
  • npx prisma migrate reset - reset the migrations to the last version. This will reset the DB and run the seed script
  • npx prisma migrate dev --name <descriptive-name> - generate a migration file for any changes you make to the schema (this will be committed).

PlanetScale commands

Learn more about Planetscale CLI in the docs: https://docs.planetscale.com/reference/planetscale-cli

Commands to know:

  • pscale connect <DATABASE_NAME> <BRANCH_NAME> --port 3309 - create a secure connection to a database branch for a local client
  • pscale database dump <DATABASE_NAME> <BRANCH_NAME> --output prisma/dumps/xx - backup and dump the specified database

Fly Setup ⚠️ Warning, the deployment setup is untested yet ⚠️

  1. Install Fly

  2. Sign up and log in to Fly

    flyctl auth signup
  3. Setup Fly. It might ask if you want to deploy, say no since you haven't built the app yet.

    flyctl launch

Deployment

If you've followed the setup instructions already, all you need to do is run this:

npm run deploy

You can run flyctl info to get the url and ip address of your server.

Check out the fly docs for more information.

Contributing

See our contribution guidelines in these languages:

When contributing to our project, please use English when communicating with other people in issues and/or pull requests. Click here to read why. (Bahasa Indonesia)

Important links

Description Link
Project overview rbagi.id/github-project
Epics list rbagi.id/epic
Issues board rbagi.id/board
Issue shortlink rbagi.id/gh/:issue-id
First-time contributors link rbagi.id/contribute

Contributors ✨

Thanks goes to these wonderful people (emoji key):


Zain Fathoni

💻 📖 🎨 🚧 🔧 ⚠️ 📆 🤔

Reza Rachmanuddin

🐛 💻 ⚠️

febrifahmi

💻

Guntoro Yudhy Kusuma

💻

Nurfitra Pujo Santiko

💻 ⚠️

Achmad Wahyu

💻 ⚠️

This project follows the all-contributors specification. Contributions of any kind welcome!