Creating Plugins - monknomo/pywin GitHub Wiki
PyWin can be extended by adding files that windows can execute (batch file, vbscript, powershell script, other) to the %PYWIN_HOME%\lib\commands directory. PyWin passes arguments to scripts in this form "script.bat script_name other args following" Each script should parse "script.bat --script --help" and echo something helpful.
Simple PyWin Extension Example
example.bat
@@echo off
SHIFT
IF "%1"=="--help" (
goto Help
)
echo This is an example script
goto End
:Help
echo --example provides an example to people who would extend pywin
goto End
:End
Placing this example into the %PYWIN_HOME%\lib\commands directory will add an additional --example command to pywin. It will echo "This is an example script" when "pywin --example" is called. It will echo "--example provides an example to people who would extend pywin" when "pywin --help" or "pywin --example --help" are called.