Added shortcut for creating user

This commit is contained in:
Khalim Conn-Kowlessar 2023-07-10 19:19:08 +01:00
parent 6d81f131b9
commit b3cdf6ac27
2 changed files with 3 additions and 2 deletions

View file

@ -74,7 +74,7 @@ Which will commit changes to the database. The database changes will be pushed t
In order to insert a user into the database, simply run
```
node -r esbuild-register src/app/db/create_user.ts khalim@hestia.homes Khalim
npm run create_users -- {email} {firstName}
```
Since we're using just the built in process arguments to read command line arguments, the ordering of arguments needs to be email address and then name

View file

@ -8,7 +8,8 @@
"start": "next start",
"lint": "next lint",
"migration:generate": "drizzle-kit generate:pg --config=drizzle.config.ts",
"migration:push": "node -r esbuild-register src/app/db/migrate.ts"
"migration:push": "node -r esbuild-register src/app/db/migrate.ts",
"create_user": "node -r esbuild-register src/app/db/create_user.ts"
},
"dependencies": {
"@headlessui/react": "^1.7.14",