Heyo! I copied some code off of Github, but the main file is in /builder/main.py
. But replit is saying there is no main.py found. Can someone help?
Hey @CarsonD-github!
Just click the ⋮ next to “Files” then click “Show hidden files”. Next click on the .replit
file and finally you can change the entrypoint
to "builder/main.py"
.
You can also change the second line from run="python main.py"
to run="python builder/main.py"
, though it won’t have an effect for languages with interpreters (such as Python) as shown in the comment on line 1.
Also see the docs on how to configure a Repl: https://docs.replit.com/programming-ide/configuring-repl
How do I do that but for a .BAT file?
.BAT
? You said it was Python
Yeah, it is but to startoff it runs build.bat
Replit uses Linux, and .bat
is for Windows, so AFAIK you can’t run batch files on Replit.
Damn… do you know where I can get a free Windows VM without downloading anything?
You could use the windows 10 installer I guess.
Pretty sure that’s impossible, feel free to correct me if I’m wrong.
Regardless, trying to run it on Replit would likely require sudo
access, which Replit does not allow.
Note for next time that I think this is against the community standards, so if you need to say something short like that, just use a reaction.
Not impossible, I’ve found some websites that let you have up to 20 minutes of free time before asking you to pay. But me and the bois just cleared our cookies, lol.
Even with a VM, you can’t do that on Replit I don’t think. Well I’ve never actually tried running a deb file, but regardless an EXE file definitely wouldn’t work to install it on a Repl, since that puts you back to point zero.
BUT
I didn’t look into your Repl a whole lot but if you are willing to rewrite the batch script, or even have an AI do it (like ChatGPT or Bing), then if you rewrite it as a Bash script (it’s a .sh file), then that’s Linux and you can run that in Repls.
wine
is a possible tool for executing Windows binaries, but it appears to be broken on Replit.
Actually, it is possible to run PowerShell files via Replit, which is basically “expanded batch”
I was going to bring that up, but I didn’t want to confuse OP a whole lot
Oh really? That’s cool. @CarsonD-github you could try converting your batch script to either PowerShell or Bash, whatever you prefer it looks like. I recommend Bash but if you’re more familiar with PS then check out that post I guess.