Step 1 : Install Supabase CLI using npm
standard installation
npm install -g supabase
I personally use
npx supabase ...
Step 2 : Login to Supabase CLI
npx supabase login
Step 3: Link Your Project
It's time to connect your local setup to your Supabase project. For this, you'll need your project's reference ID. This assumes you have already run supabase init
in your project and have a configuration. If you haven't it'll prompt you to run that command first.
You can find the project ref in your Supabase dashboard (it's that long string of letters and numbers).
npx supabase link --project-ref YOUR_PROJECT_REF_ID
Replace YOUR_PROJECT_REF_ID
with your actual project reference ID.
Step 4 : Reset the DB
supabase db reset --linked
### Step 5 : Lets Discuss
Ways to avoid reseting database after migration failure 😂
Top comments (0)