Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to use browserify with brfs without npm or node installed?

I'm using browserify with brfs (as described here: knockout integration with browserify) and am checking-in to a build controller that doesn't have Node installed, and doesn't have npm installed either. My solution is to check-in node.exe and then do the following to use browserify:

.\node.exe .\browserify\bin\cmd.js index.js -o app.js

Works great. However, I want to use brfs, and browserify expects this as a transform, e.g.

browserify -t brfs main.js > bundle.js

Now I can't figure this out because 'brfs' won't be aliased, and I can't figure out how to use my node.exe trick again. What I think I want is this, which obviously doesn't work because parenthesis don't work like this in cmd:

.\node.exe .\browserify\bin\cmd.js -t (.\node.exe .\brfs\bin\args.js) index.js -o app.js

How can I accomplish this?

like image 720
Eli Brown Avatar asked Nov 09 '22 22:11

Eli Brown


1 Answers

I figured it out - once I am running browserify using node.exe with my above method, as long as brfs is in my node_modules folder, node/browserify will search the node_modules folder for brfs. Thus, the following works:

.\node.exe .\browserify\bin\cmd.js -t brfs index.js -o app.js
like image 58
Eli Brown Avatar answered Nov 14 '22 21:11

Eli Brown