Skip to content

Commit

Permalink
fix: migration successful now displays name of the migration file (ty…
Browse files Browse the repository at this point in the history
…peorm#8904)

Co-authored-by: Sudarshan Gaikaiwari <sudarshan.gaikaiwari@getcruise.com>
  • Loading branch information
sudarshang and Sudarshan Gaikaiwari authored Apr 18, 2022
1 parent 2d8afbe commit 49cbe23
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions src/commands/MigrationGenerateCommand.ts
Original file line number Diff line number Diff line change
Expand Up @@ -185,15 +185,14 @@ export class MigrationGenerateCommand implements yargs.CommandModule {
),
)
} else {
await CommandUtils.createFile(
path.dirname(fullPath) + "/" + filename,
fileContent,
)
const migrationFileName =
path.dirname(fullPath) + "/" + filename
await CommandUtils.createFile(migrationFileName, fileContent)

console.log(
chalk.green(
`Migration ${chalk.blue(
fullPath + extension,
migrationFileName,
)} has been generated successfully.`,
),
)
Expand Down

0 comments on commit 49cbe23

Please sign in to comment.