Page 4 of 4
Re: External Tools plugin how-to?
Posted: 15.01.2024 18:12
by Stem75
with dot cmd /c {ContentAsTemp}.cmd
'C:-___TEMP-cudatext-.text1..cmd' is not recognized as an internal or external command,
operable program or batch file.
without dot cmd /c {ContentAsTemp}cmd
'C:-___TEMP-cudatext-.text1.cmd' is not recognized as an internal or external command,
operable program or batch file.
Re: External Tools plugin how-to?
Posted: 15.01.2024 18:33
by main Alexey
what is the target? run selected lines as CMD batch file?
if so i will try it soon.
Re: External Tools plugin how-to?
Posted: 15.01.2024 18:47
by Stem75
Basically yes.
Make a command with external tools --> CMD
make a button with plugins - config toolbar
write the script in editor
quick test - run the script without saving, just hitting the button. (better without having to select the text)
Re: External Tools plugin how-to?
Posted: 15.01.2024 19:27
by main Alexey
okay. tried this on Win10. yes, confirmed - for untitled ui-tab this does not work.
only for named file it works.
ExternalTools plugin needs improvement to make it work with untitled ui-tab, ie macro {Content........} needs improvement to allow to set EXTENSION for temp file (now extension is empty).
currently the author of ExtTools is busy so I cannot ask him to add this. need some programmer.
maybe try to configure the 'Runner' plugin for this. alternative plugin Runner.
Re: External Tools plugin how-to?
Posted: 15.01.2024 19:30
by main Alexey
[del]
Re: External Tools plugin how-to?
Posted: 15.01.2024 19:38
by main Alexey
okay. I made this tool.
I made new BAT file c:\work\r.bat.
this is the 'middle script' which has this code
Code: Select all
copy %1 c:\work\runsel.bat
c:\work\runsel.bat
now I changed the ExtTools plugin's tool like this:
- file name: cmd_exe (replace _ with dot)
- shell command: unchecked
- parameters: /c c:\\work\\r.bat {ContentAsTemp}
now my ExtTools tool works for untitled ui-tabs.
example untitled text:
result of ExtTools running:
C:\>copy C:\Temp\cudatext\.text3. c:\work\runsel.bat
1 file(s) copied.
C:\>c:\work\runsel.bat
C:\>echo aa
aa
C:\>echo bb
bb
C:\>echo dd
dd
Re: External Tools plugin how-to?
Posted: 15.01.2024 19:59
by Stem75
Nice. Thank you for the solution. It works here too.
I'll try with the Runner plugin also. WARNING! more questions coming.