Skip to content

Commit

Permalink
pass in sctFileName to manifest
Browse files Browse the repository at this point in the history
  • Loading branch information
David Hasani committed Oct 19, 2024
1 parent b4c97ad commit a390ea1
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions packages/core/src/codewhisperer/models/model.ts
Original file line number Diff line number Diff line change
Expand Up @@ -332,6 +332,7 @@ export class ZipManifest {
target: string | undefined
schema: string | undefined
host: string | undefined
sctFileName: string | undefined
}
| undefined
} = { sqlConversion: undefined }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -320,13 +320,14 @@ export async function zipCode({ dependenciesFolder, humanInTheLoopFlag, projectP
if (transformByQState.getMetadataPathSQL() && zipManifest instanceof ZipManifest) {
// user is doing a SQL conversion since metadataPath is defined
// also, it must be a ZipManifest since only other option is HilZipManifest which is not used for SQL conversions
const metadataZip = new AdmZip(transformByQState.getMetadataPathSQL())
zipManifest.requestedConversions.sqlConversion = {
source: transformByQState.getSourceDB(),
target: transformByQState.getTargetDB(),
schema: transformByQState.getSchema(),
host: transformByQState.getSourceServerName(),
sctFileName: metadataZip.getEntries().filter((entry) => entry.entryName.endsWith('.sct'))[0].entryName,
}
const metadataZip = new AdmZip(transformByQState.getMetadataPathSQL())
// TO-DO: later make this add to path.join(zipManifest.dependenciesRoot, 'qct-sct-metadata', entry.entryName) so that it's more organized
metadataZip
.getEntries()
Expand Down

0 comments on commit a390ea1

Please sign in to comment.