How to run Batch files in a Repl?

I want to run “.bat”.
How can I run “.bat” on Replit?

Since Repls are Linux-based, they can’t directly run batch files. Instead, you’d have to use something like Wine which might work. Otherwise, you might want to convert it to PowerShell and since PowerShell is open-source and available on Linux, you can probably use it to run .ps1 files.

2 Likes

Thank you your reply!
You mean I should use PowerShell right?
How do I use PowerShell?
I have never used PowerShell.

Me neither. You could try Wine first though.

Alternatively convert your Batch script to Bash, which Linux natively supports.

What do you mean?
I don’t know the meaning of “Wine” or “Bash”.
In the short, what should I do?

Batch (.bat) is the language for cmd on windows, which doesn’t work directly on Linux (Which Replit runs). Bash (.sh) is both the language and the command interpreter on most Linux systems.

2 Likes

Thank you for yoyr repply.
I could know the diiference between cmd and PowerShell.
And then, I could run batch file in this way.
Thank you for your telling!

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.