0

I have created a selenium automation code and I wanna share it with my friends, I want to make it fully automated, so I made a setup.py file that will automatically install all pip requirements. I want to make something like a .bat file which will install python in windows by just double-clicking on it. Is it even possible? Thanks :)

Update: The possible solution that I found

I was unable to find a way to Download python using just CMD but if you have python.exe in your system then you can use the below Method to install it (you can also make .bat file to automate it.)

  1. Install the python.exe file on your computer from the official site.

  2. Open CMD and change Your directory to the path where you have python.exe

  3. Past this code in your Command prompt make sure to change the name with your file version In the below code(e.g python-3.8.5.exe)

python-3.6.0.exe /quiet InstallAllUsers=1 PrependPath=1 Include_test=0

It will also set the path Variables.

1

2 Answers 2

2

If you have cURL, you can use that from cmd:

curl https://www.python.org/ftp/python/3.8.5/python-3.8.5.exe --output "%TMP%\python-3.8.5.exe" && "%TMP%\python-3.8.5.exe" /silent

It should download and install Python 3.8.5 x86

Sign up to request clarification or add additional context in comments.

Comments

0

I don't know if you can install python using command line in Windows.

But maybe you can "bundle" your entire application (including python itself) using pyinstaller:

https://www.infoworld.com/article/3543792/how-to-use-pyinstaller-to-create-python-executables.html

This way you can send your entire application as a executable (*.exe) file.

Another option is to download portable-python:

https://sourceforge.net/projects/portable-python/

And your friends can use wget from windows command line to download portable-python.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.