mirror of
https://github.com/supabase/setup-cli.git
synced 2025-12-08 16:16:25 +00:00
Compare commits
4 Commits
aba4e4392d
...
bump-defau
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a35ea70530 | ||
|
|
d3753c9dbc | ||
|
|
d9e25d90f6 | ||
|
|
dadb6ee5a7 |
11
README.md
11
README.md
@@ -34,7 +34,7 @@ A specific version of the `supabase` CLI can be installed:
|
||||
steps:
|
||||
- uses: supabase/setup-cli@v1
|
||||
with:
|
||||
version: 2.20.3
|
||||
version: 2.33.0
|
||||
```
|
||||
|
||||
Run `supabase db start` to execute all migrations on a fresh database:
|
||||
@@ -44,8 +44,9 @@ steps:
|
||||
- uses: supabase/setup-cli@v1
|
||||
with:
|
||||
version: latest
|
||||
- run: supabase init
|
||||
- run: supabase db start
|
||||
# Optionally connect to the local database using psql
|
||||
- run: psql 'postgres://postgres:postgres@localhost:54322/postgres' -c ''
|
||||
```
|
||||
|
||||
Since Supabase CLI relies on Docker Engine API, additional setup may be required
|
||||
@@ -57,7 +58,7 @@ The actions supports the following inputs:
|
||||
|
||||
| Name | Type | Description | Default | Required |
|
||||
| --------- | ------ | ---------------------------------- | -------- | -------- |
|
||||
| `version` | String | Supabase CLI version (or `latest`) | `2.20.3` | false |
|
||||
| `version` | String | Supabase CLI version (or `latest`) | `2.33.0` | false |
|
||||
|
||||
## Advanced Usage
|
||||
|
||||
@@ -66,11 +67,10 @@ Check generated TypeScript types are up-to-date with Postgres schema:
|
||||
```yaml
|
||||
steps:
|
||||
- uses: supabase/setup-cli@v1
|
||||
- run: supabase init
|
||||
- run: supabase db start
|
||||
- name: Verify generated types match Postgres schema
|
||||
run: |
|
||||
supabase gen types typescript --local > schema.gen.ts
|
||||
supabase gen types --local > schema.gen.ts
|
||||
if ! git diff --ignore-space-at-eol --exit-code --quiet schema.gen.ts; then
|
||||
echo "Detected uncommitted changes after build. See status below:"
|
||||
git diff
|
||||
@@ -83,6 +83,7 @@ Release job to push schema changes to a Supabase project:
|
||||
```yaml
|
||||
env:
|
||||
SUPABASE_ACCESS_TOKEN: ${{ secrets.ACCESS_TOKEN }}
|
||||
# Optionally set the postgres password for linking project database
|
||||
SUPABASE_DB_PASSWORD: ${{ secrets.DB_PASSWORD }}
|
||||
# Retrieve <project-id> from dashboard url: https://app.supabase.com/project/<project-id>
|
||||
PROJECT_ID: <project-id>
|
||||
|
||||
@@ -5,7 +5,7 @@ inputs:
|
||||
version:
|
||||
description: Version of Supabase CLI to install
|
||||
required: false
|
||||
default: 2.20.3
|
||||
default: 2.33.0
|
||||
outputs:
|
||||
version:
|
||||
description: Version of installed Supabase CLI
|
||||
|
||||
Reference in New Issue
Block a user