{"_id":"@bujhmt/nx-kysely-migrations","name":"@bujhmt/nx-kysely-migrations","dist-tags":{"latest":"1.0.0"},"versions":{"1.0.0":{"name":"@bujhmt/nx-kysely-migrations","version":"1.0.0","description":"Nx generator for scaffolding Kysely migration files.","license":"MIT","author":{"name":"bujhmt"},"keywords":["nx","nx-plugin","kysely","migration","migrations","generator"],"repository":{"type":"git","url":"git+https://github.com/bujhmt/packages.git","directory":"packages/nx-kysely-migrations"},"homepage":"https://github.com/bujhmt/packages/tree/main/packages/nx-kysely-migrations#readme","bugs":{"url":"https://github.com/bujhmt/packages/issues"},"publishConfig":{"access":"public"},"main":"./dist/index.js","module":"./dist/index.js","types":"./dist/index.d.ts","exports":{"./package.json":"./package.json",".":{"@bujhmt/source":"./src/index.ts","types":"./dist/index.d.ts","import":"./dist/index.js","default":"./dist/index.js"}},"scripts":{"build":"nx build nx-kysely-migrations","prepublishOnly":"npm run build","publish:npm":"npm publish"},"nx":{"targets":{"build":{"executor":"@nx/js:tsc","outputs":["{options.outputPath}"],"options":{"outputPath":"packages/nx-kysely-migrations/dist","main":"packages/nx-kysely-migrations/src/index.ts","tsConfig":"packages/nx-kysely-migrations/tsconfig.lib.json","rootDir":"packages/nx-kysely-migrations/src","generatePackageJson":false,"assets":[{"input":"./packages/nx-kysely-migrations/src","glob":"**/!(*.ts)","output":"."},{"input":"./packages/nx-kysely-migrations/src","glob":"**/*.d.ts","output":"."}]}}},"tags":["scope:public"]},"dependencies":{"@nx/devkit":"22.7.3","tslib":"^2.3.0"},"generators":"./generators.json","_id":"@bujhmt/nx-kysely-migrations@1.0.0","gitHead":"98f33e1f06d648643a0d02aa9bbb734b81980d06","_nodeVersion":"22.15.1","_npmVersion":"10.9.2","dist":{"integrity":"sha512-P7iv+9Jw3I39Z+4o7zNuhnFFKPoVKP07R6hnSG0h+q5WqohCcnCZeU6m5U3hxSbVB7elE11jADT2BzvIRzOIDQ==","shasum":"70ba5088dfe3dcd894c417ff7b3bc8819a557151","tarball":"https://registry.npmjs.org/@bujhmt/nx-kysely-migrations/-/nx-kysely-migrations-1.0.0.tgz","fileCount":12,"unpackedSize":7478,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIQCfzjTA9lhTcbCCMNNAIYVhgbmsuyBzZAObCY82bM1T3gIgF2ECQm17lAOSVoyQ0Kw6ofI/ETwmvvHaguNvdSuNz7Y="}]},"_npmUser":{"name":"bujhmt","email":"bujhmt99999@gmail.com"},"directories":{},"maintainers":[{"name":"bujhmt","email":"bujhmt99999@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/nx-kysely-migrations_1.0.0_1779531805904_0.03539813612645615"},"_hasShrinkwrap":false}},"time":{"created":"2026-05-23T10:23:25.784Z","1.0.0":"2026-05-23T10:23:26.054Z","modified":"2026-05-23T10:23:26.233Z"},"maintainers":[{"name":"bujhmt","email":"bujhmt99999@gmail.com"}],"description":"Nx generator for scaffolding Kysely migration files.","homepage":"https://github.com/bujhmt/packages/tree/main/packages/nx-kysely-migrations#readme","keywords":["nx","nx-plugin","kysely","migration","migrations","generator"],"repository":{"type":"git","url":"git+https://github.com/bujhmt/packages.git","directory":"packages/nx-kysely-migrations"},"author":{"name":"bujhmt"},"bugs":{"url":"https://github.com/bujhmt/packages/issues"},"license":"MIT","readme":"# @bujhmt/nx-kysely-migrations\n\nNx generator for scaffolding [Kysely](https://kysely.dev) migration files.\n\nKysely has no built-in \"make migration\", so files are created by hand: pick a sortable\ntimestamp prefix, name the file, write the `up`/`down` boilerplate. This does it in one command.\n\n## Usage\n\n```bash\n# positional\nnpx nx g @bujhmt/nx-kysely-migrations:create <path> <name>\nnpx nx g @bujhmt/nx-kysely-migrations:create apps/api/src/db/migrations create_users\n\n# named flags (equivalent)\nnpx nx g @bujhmt/nx-kysely-migrations:create --path=apps/api/src/db/migrations --name=create_users\n```\n\nCreates `<path>/<timestamp>_<name>.ts` with an `up`/`down` skeleton. The timestamp is a\ncompact UTC `YYYYMMDDHHmmss` — filesystem-safe and alphabetically sorted, which is how\nKysely orders migrations. Omit an argument and the generator prompts for it.\n\n| Option | Index | Required | Description                          |\n| ------ | ----- | -------- | ------------------------------------ |\n| `path` | 0     | yes      | Folder to place the migration in     |\n| `name` | 1     | yes      | Migration name (e.g. `create_users`) |\n\n## In another workspace\n\n```bash\nnpm i -D @bujhmt/nx-kysely-migrations\n```\n\nRunning the migrations themselves is up to your project (Kysely `Migrator` +\n`FileMigrationProvider` pointed at the folder above) — this plugin only creates files.\n\n## Develop\n\n```bash\nnx build nx-kysely-migrations   # CommonJS output + templates + generators.json\nnx lint nx-kysely-migrations\n```\n\nThe template lives at `src/generators/create/files/__filename__.ts.template`. The\n`.template` suffix keeps it out of `tsc` (so the `kysely` import doesn't break the build)\nand lets it ship to `dist` as an asset; `generateFiles` strips the suffix on generation.\n","readmeFilename":"README.md","_rev":"1-21c1f444c29f9adc0ded4b0860e787c4"}