Skip to content

Commit

Permalink
chore: remove dependency on in-source compilation of bin/ directory (
Browse files Browse the repository at this point in the history
…#32476)

The `bin/cdk` binary relies on the fact that `bin/cdk.ts` undergoes an in-source compilation, producing `bin/cdk.js` which is then required.

This fails in a different setup where we only compile the `lib/` directory and nothing else.

So skip one level of indirection: just put the code that loads the actual CLI entry point directly in the bash wrapper.

----

*By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
  • Loading branch information
rix0rrr authored Dec 12, 2024
1 parent fe7d435 commit 6e28ffe
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
4 changes: 2 additions & 2 deletions packages/aws-cdk/bin/cdk
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/usr/bin/env node

// source maps must be enabled before importing files
process.setSourceMapsEnabled(true);
const { cli } = require("../lib/cli");

require('./cdk.js');
cli();
3 changes: 0 additions & 3 deletions packages/aws-cdk/bin/cdk.ts

This file was deleted.

0 comments on commit 6e28ffe

Please sign in to comment.