Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Fix main module shimming for inferred extensions #38

merged 1 commit into from Jul 24, 2012


None yet
2 participants

aseemk commented Jul 23, 2012

The native node binary, just like require(), allows specifying paths that aren't directly to the file; they can point to a folder or just the filename without the extension.

node-dev runs those files fine, but it just wasn't detecting the "main" module in those cases. Fixed by checking module.parent instead of using the passed-in path.

Added a simple test case; try e.g. node-dev test/main.

Fix main module shimming for inferred extensions.
E.g. `node-dev test/main` should work.

fgnass pushed a commit that referenced this pull request Jul 24, 2012

Merge pull request #38 from aseemk/master
Fix main module shimming for inferred extensions

@fgnass fgnass merged commit de86c3c into fgnass:master Jul 24, 2012


aseemk commented Jul 24, 2012

Awesome, thanks. Mind publishing to npm?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment