As we've rebranded EdgeDB to Gel, you may need to update your project to reflect the new packages names. This guide walks you through the manual steps to migrate your project.
If you prefer an automated solution, you can use our codemod tool which will handle all of these changes automatically.
$
npx @gel/codemod </path/to/your/project>
Package dependencies
Update your package.json
by replacing the following dependencies:
Old package |
New package |
---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Package scripts
In your package.json
scripts, replace any instances of @edgedb/generate
with @gel/generate
.
{ "scripts": { "generate": "npx @edgedb/generate queries" "generate": "npx @gel/generate queries" } }
Import statements
Update all import statements in your TypeScript/JavaScript files:
import * as edgedb from 'edgedb'; import { something } from '@edgedb/auth'; import { other } from '@edgedb/auth-nextjs/app'; import * as gel from 'gel'; import { something } from '@gel/auth'; import { other } from '@gel/auth-nextjs/app';
If you're using namespace imports with a custom identifier, update the identifier usage throughout the file:
import * as myEdgeDB from 'edgedb'; myEdgeDB.createClient(); import * as gel from 'gel'; gel.createClient();
We've also renamed EdgeDBError
to GelError
. Make sure to update any references to EdgeDBError
in your codebase.
File extensions
Rename files with the following extensions:
-
.esdl
β.gel
Configuration file
Rename and update configuration files:
-
Rename
edgedb.toml
togel.toml
-
In the
gel.toml
file, replace the section header[edgedb]
with[instance]
After migration
After completing these steps:
-
Install the updated dependencies:
Copy$
npm install # or yarn install # or pnpm install
-
Verify your application works as expected.
-
Update any documentation or
README
files to reflect the new package names.
New projects
If you want to scaffold a new project using our starter kit, we've updated the package name from @edgedb/create
to @gel/create
. You can use the following command:
$
npm create @gel
Need help?
Join our Discord community for support: https://discord.gg/gel