Yes we can use Woindows 10 for execution of bash script. You need to change following things to make it enabled.
![](https://i0.wp.com/dasbotask.com/wp-content/uploads/2020/11/image.png?resize=913%2C461&ssl=1)
![](https://i0.wp.com/dasbotask.com/wp-content/uploads/2020/11/image-2.png?resize=1024%2C756&ssl=1)
2) In search bar Search for Windows Features. Click Turn Windows feature on and off
![](https://i0.wp.com/dasbotask.com/wp-content/uploads/2020/11/image-3.png?resize=1024%2C659&ssl=1)
After reboot open browser and hit https://aka.ms/wslstore
will open store and install ubuntu.
![](https://i0.wp.com/dasbotask.com/wp-content/uploads/2020/11/image-4.png?resize=1024%2C799&ssl=1)
Now store a shell file given below to your desktop with .sh
file extension. Example : test.sh
#! /bin/bash
echo "Hello World"
Then go to terminal or cmd or powershell of windows and run the code like below.
C:\Users\username\Desktop> bash index.sh
Hello World
So you need to write bash before the shell file and it will execute and return the value.
Suggestions