seunlanlege / vscode-action-buttons

VsCode extension for custom status bar buttons
88 stars 24 forks source link

Problem occurs when using predefined vars #53

Open colourfulspring opened 3 years ago

colourfulspring commented 3 years ago

I write this code in my settings.json file:

"actionButtons": {
        "defaultColor": "white", // Can also use string color names.
        "commands": [
            {
                "name": "Run Cpp",
                "color": "white",
                "command": "g++ ${fileBasename} -o ${fileBasenameNoExtension} && ./${fileBasenameNoExtension}",
            }
        ]
    },

But after I click the button generated by the code, this command runs on the terminal : (the name of my cpp file is Solution.cpp)

g++ Solution.cpp -o Solution && ./${fileBasenameNoExtension}

I have no idea about why the latter ${fileBasenameNoExtension} remains uninterpreted. Can you help me? Thanks!!