1 year ago

#164787

test-img

tmp

Custom buildscript for vscode extension

I am trying to build an extension for vscode for a specific file format. Now I want to run a custom build script (a batch file that is placed inside the custom extension) that gets exectued when the user presses ctrl+shift+B

I successfully created such a behaviour in a sublime3 extension where the sublime-build script looks like that:

{
    "working_dir": "${project_path:${folder:${file_path}}}",
    "shell": true,
    "osx":
    {
        "cmd": ["cd '$packages/myextension/buildscript/'  && ./mybuildscript.sh $file"]
    },
    "windows":
    {
        "shell_cmd": "cd '$packages/myextension/buildscript/'  && ./mybuildscript.bat $file",
    },
    "linux":
    {
        "cmd": ["cd '$packages/myextension/buildscript/'  && ./mybuildscript.sh $file"]
    }
}

Can you provide an example how something similar can be done in the vscode extension?

shell

visual-studio-code

vscode-extensions

build-script

0 Answers

Your Answer

Accepted video resources