Use folder path as a command line parameter

Hi, I'm new to opus and I don't really know how to do something like this.

I would like to select a folder and when I click on an icon the path to the folder is applied as a parameter of a command line.

A simple example:

I select the folder c:\software, click on an icon and run the dir command in that folder

dir c:\software


Quick demo:



Thanks @lxp