Skip to content

Better shebang support needed #1030

@nazar-pc

Description

@nazar-pc

Currently

``#!/usr/bin/env node``

compiles to

// Generated by LiveScript 1.5.0
#!/usr/bin/env node
(function(){

}).call(this);

I know there are options that allow to remove Generated by line as well as function wrapper, but I believe this should work properly even if those are not used.

Ideally, LiveScript should blindly preserve anything that is on the first line and starts with #!, without any need for backticks or additional CLI options.

TL;DR:

#!/usr/bin/env node
console.log 'Hello'

should compile to

#!/usr/bin/env node
// Generated by LiveScript 1.5.0
(function(){
  console.log('Hello');
}).call(this);

by default.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions