VSCode syntax highlighting for custom shebang

后端 未结 3 1473
逝去的感伤
逝去的感伤 2021-02-08 19:28

At work we run python under a custom environment, and thus we use a non-standard shebang. I tested that VSCode recognizes python files without a .py extension if they h

3条回答
  •  面向向阳花
    2021-02-08 20:17

    To complement Matt Bierner's helpful answer:

    The JSON settings Matt references are in /package.json files in the following locations:

    On GitHub:

    • https://github.com/Microsoft/vscode/tree/master/extensions
    • E.g., for Python: https://github.com/Microsoft/vscode/blob/master/extensions/python/package.json

    When installed:

    • In the resources/app/extensions subfolder of the VSCode installation folder; e.g.:

      • Windows (32-bit version):

        C:\Program Files (x86)\Microsoft VS Code\resources\app\extensions
        
      • macOS:

        /Applications/Visual Studio Code.app/Contents/Resources/app/extensions
        
    • E.g, for Python:

      • Windows (32-bit version):

        C:\Program Files (x86)\Microsoft VS Code\resources\app\extensions\python\package.json
        
      • macOS:

        /Applications/Visual Studio Code.app/Contents/Resources/app/extensions/python/package.json
        

提交回复
热议问题