Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to run program on ( ubuntu bash windows 10 ) from windows task scheduler

I need to execute task every 5 minute in ubuntu bash and I like to use windows task scheduler. I don't know how to write a .bat file to start application in ubuntu bash. I tested these and did not work. c:\Windows\System32\bash.exe -l [program_name args]

like image 259
amin saffar Avatar asked Mar 10 '23 04:03

amin saffar


1 Answers

can run command on ubuntu bash with add -c flag in args

c:\Windows\System32\bash.exe -c <command>

and write it in .bat file and then add to windows task scheduler.

like image 50
amin saffar Avatar answered Mar 11 '23 18:03

amin saffar