The hard way to install Pygame and pip

Install setuptools and pip

Preparations: python has been installed and environment variables have been configured, please refer to 

http://blog.csdn.net/donggege214/article/details/52062855

Install setuptools

Download the setuptools source code setuptools-25.2.0.tar.gz

Address: https://pypi.python.org/pypi/setuptools 

This is a zip file, unzip it to the desktop, and go into the folder

Use cmd to enter the folder

Enter python setup.py install and press Enter

 

 

After the installation is successful, open a new command window, enter easy_install and press Enter to test

If it prompts: 
error: No urls, filenames, or requirements specified (see –help) 
, the installation is successful, and it prompts you that the command needs to be followed by parameters. 
If prompted: 
'easy_install' is not an internal or external command, nor is it a runnable program 
or batch file. 
Please check whether the environment variable path is configured with "C:\Python27\Scripts"

install pip

If setuptools is installed, you can use easy_install to install pip directly

If you still want to install it manually, it is exactly the same as installing setuptools (no screenshots are attached here)

Download the pip archive pip-8.1.2-py2.py3-none-any.whl

Address: https://pypi.python.org/pypi/pip

This is a zip file, unzip it to the desktop, and go into the folder

After holding down the shift key, right-click on an empty space in the folder and select: Open command window here

Enter python setup.py install and press Enter

After the installation is successful, you can open a new command window, enter pip and press Enter to test

If prompted: 
Did not provide a command 
, the installation was successful, because pip also needs to be followed by parameters. 
If prompted: 
'pip' is not an internal or external command, nor is it a runnable program 
or batch file. 
Please check whether the environment variable path is configured with "C:\Python27\Scripts"

After the installation is successful, enter pip

 

 

 

install pygame

Reference https://www.cnblogs.com/Jacklovely/p/6524572.html

After installing pygame successfully, it looks like this

 

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=324855296&siteId=291194637