Skip to content

ayush0402/humara-ghar

Repository files navigation

Built with nextjs, tailwindcss, supabase, and love ♥.


If you wish to just develop follow the steps below.

Clone and run locally

  1. You'll first need a Supabase project which can be made via the Supabase dashboard

Dev Environment Setup

Install Dependencies

  • Run npm i to install dependencies for your project.

Supabase Login in Terminal

  • If you haven't used Supabase in your terminal before, log in by creating an access token here.
  • Copy the access token generated.
  • Run npx supabase login in your terminal.
  • When prompted for an access token, paste the token you copied earlier to log in.

Linking Your Project to Supabase

  • Run npx supabase link --project-ref {projectRef} in your terminal.
    • Your project reference is available in the project settings section within the Supabase dashboard.
  • After running the command, you'll be prompted for the database password you saved earlier. Enter it to complete the linking process.

Pushing Migration Files to Supabase Project

  • Execute npx supabase db push . in your terminal.
  • This command will push all necessary configurations (teams, admin panel, projects, etc.) into your Supabase project.
  • Your Supabase project will now be ready for use.
  1. Rename .env.local.example to .env.local and update the following:

    NEXT_PUBLIC_SUPABASE_URL=[INSERT SUPABASE PROJECT URL]
    NEXT_PUBLIC_SUPABASE_ANON_KEY=[INSERT SUPABASE PROJECT API ANON KEY]
    

    Both NEXT_PUBLIC_SUPABASE_URL and NEXT_PUBLIC_SUPABASE_ANON_KEY can be found in your Supabase project's API settings

  2. You can now run the Next.js local development server:

    npm run dev