Skip to content

Commit

Permalink
fix: resolve shim relative to tsconfig.json
Browse files Browse the repository at this point in the history
  • Loading branch information
wojpawlik committed Sep 27, 2023
1 parent dc34fd8 commit b559ef3
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
run: |
npm config set //registry.npmjs.org/:_authToken '${NPM_TOKEN}'
[[ "$GITHUB_REF_NAME" =~ - ]] && npm config set tag=next
npm pkg set version="$GITHUB_REF_NAME"
npm pkg set version="${GITHUB_REF_NAME/v/}"
npm publish --ignore-scripts
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "deno2node",
"version": "1.10.0",
"version": "1.10.1",
"description": "`tsc` replacement for transpiling Deno libraries to run on Node.js.",
"type": "module",
"bin": {
Expand Down
4 changes: 3 additions & 1 deletion src/_transformations/shim.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,9 @@ const isNodeSpecific = (sourceFile: SourceFile) =>
export function shimEverything(ctx: Context) {
if (!ctx.config.shim) return;
console.time("Shimming");
const shim = shimFile(ctx.project.addSourceFileAtPath(ctx.config.shim));
const shim = shimFile(
ctx.project.addSourceFileAtPath(ctx.resolve(ctx.config.shim)),
);
for (const sourceFile of ctx.project.getSourceFiles()) {
if (!isNodeSpecific(sourceFile)) {
shim(sourceFile);
Expand Down

0 comments on commit b559ef3

Please sign in to comment.