Install Python in WinPE,
This article describes how to install Python in WinPE for your reference. The details are as follows:
1. Download the Python Windows installation package. The latest version is 3.3.0.
:Http://www.python.org/getit/
2. Install Python in Windows. If it is WinPE 64bit, install Python 64bit.
* Select "Install just for me" and click "Next" for the remaining steps.
Iii. Decompress WinPE and start the image boot. wim
Dism.exe/mount-wim/WimFile:. \ boot. wim/index: 1/MountDir:. \ mount
4. Copy the installed Python file to the WinPE startup image.
For example, the default installation folder of Python3.3.0 is C: \ Python33. Copy the folder to the root directory of the WinPE startup image.
5. Add the following command to Windows \ system32 \ startnet. cmd:
Associate Python File Extension: assoc. py = PythonFile
Specify the command to call the Python file: ftype PythonFile = X: \ Python33 \ Python.exe "% 1" % *
* Note that % 1 should be enclosed by "". Otherwise, the path with spaces cannot be executed.
Vi. encapsulate WinPE Boot Image
Dism.exe/unmount-wim/mountdir:. \ mount/commit
7. Start WinPE and verify whether the Python script can be executed.
The above is all the content of this article, hoping to help you learn.