7

Python快速参考

 2 years ago
source link: https://wintrysec.github.io/2021/09/26/%E3%80%905%E3%80%91%E5%AE%89%E5%85%A8%E5%BC%80%E5%8F%91/Python/python%E5%BF%AB%E9%80%9F%E5%8F%82%E8%80%83/
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
neoserver,ios ssh client

IDE配置(代码编辑器)

下载:https://www.jetbrains.com/pycharm/download/#section=windows

激活:https://www.lookdiv.com密码lookdiv

配置解释器

使用本地python解释器(不用虚拟环境)

打开setting,选择项目设置解释器路径

1、然后在本项目设置脚本位置

2、Shift+F10运行脚本

基础语法学习

廖雪峰-Python教程 (Python3)

打包成exe文件

使用虚拟环境打包,要不然打包的文件会很大

先进入一个目录,比如桌面Desktop

pip  install virtualenv
virtualenv pyexe_build
cd pyexe_build\Scripts
activate
cd ..

pip install pyinstaller
pip install requests #安装需要的第三方库
pyinstaller -F main.py #打包目标python文件为exe,-w 选项用以隐藏cmd窗口

About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK