atom-jinja2 icon indicating copy to clipboard operation
atom-jinja2 copied to clipboard

support for file format based on shebang header

Open ssbarnea opened this issue 7 years ago • 0 comments

It would be very useful to enable file format detection based on shebang lines. Here are few examples:

#!/bin/bash ...
#!/bin/sh ...
(shell)

#!/usr/bin/env ansible-playbook -i ../hosts -K
(yaml)

#!/usr/bin/env python
#!/usr/bin/env python2
#!/usr/bin/env python3
#!/usr/bin/env python2.7
(python)

References

  • http://stackoverflow.com/questions/10376206/what-is-the-preferred-bash-shebang
  • http://stackoverflow.com/questions/6908143/should-i-put-shebang-in-python-scripts-and-what-form-should-it-take
  • https://en.wikipedia.org/wiki/Shebang_(Unix)

ssbarnea avatar Mar 29 '17 10:03 ssbarnea