Terminus icon indicating copy to clipboard operation
Terminus copied to clipboard

How can I use same shortcut execute python or groovy

Open brucmao opened this issue 2 years ago • 2 comments

This is the way I currently execute python

{
        "keys":["f5"],
        "caption":"Terminus: save & Python",
        "command":"chain",
        "args":
        {
            "commands":[
                ["save"],
                ["terminus_open",
                    {
                        "cwd" :"${file_path:${folder}}",
                        "cmd" : [ "python","-i","$file" ],
                        "post_window_hooks": [                
                            ["carry_file_to_pane", {"direction": "down"}]                
                        ]
                    },
                ],
           ]
        }
    }

I want to execute python and groovy with the same shortcut key f5

brucmao avatar Jul 17 '22 03:07 brucmao

Could you elaborate? What is groovy?

randy3k avatar Jul 18 '22 18:07 randy3k

Apache Groovy is a powerful, optionally typed and dynamic language

here is groovy build system, I build groovy with shortcuts ctrl+b

groovy.sublime-build

{
    "cmd": ["groovy","$file"],
    "selector": "source.groovy",
    "file_regex": "[ ]*at .+[(](.+):([0-9]+)[)]",

    "windows": {
        "shell": "cmd.exe"
    }

}

brucmao avatar Jul 19 '22 01:07 brucmao