Closed adius closed 6 years ago
pulp run
also generates such an app wrapper (which is really just something like require('./output/Main').main()
; but if you do pulp build --to app.js
you also get a directly runnable bundle.
Uhm aha, this does not seem particular intuitive or discoverable 😅
How about adding a pulp bundle
command, which is basically pulp build --to output/bundle.js
?
Another problem:
If I want to use it is a executable I still need to add #! /usr/bin/env node
to the top.
Would be cool if there was a command / flag as well. Maybe pulp bundle --executable
I think this is sufficiently clear in the README as well as in the output of pulp build --help
. I don't want to add more commands which do things which are already fairly straightforward.
I shouldn't have to read the documentation first for such an essential command.
pulp --help
should be enough.
And --to
is the last command in the command options section.
They should definitely not be sorted alphabetically, but by importance.
Or there should be an additional examples section where the most important usage scenarios are described (a la https://github.com/tldr-pages/tldr)
I want to use the compiled program with
node output/app.js
as a CLI program. The fileapp.js
generated bypulp server
works exactly like this, but neither do thepulp build
nor thepulp browserify
versions.Why is there no dedicated command to generate the
app.js
instead of having to misuse the server to build it?