Python environment variable configuration-Test article

Source: Internet
Author: User

Support Python2 's Chinese code
# -*- coding: UTF-8 -*-
Meaning of calling Python
#!/usr/bin/python是告诉操作系统执行这个脚本的时候,调用 /usr/bin 下的 python 解释器;相当于写死了python路径;#!/usr/bin/env python (推荐)这种用法是为了防止操作系统用户没有将 python 装在默认的 /usr/bin 路径里。当系统看到这一行的时候,首先会到 env 设置里查找 python 的安装路径,再调用对应路径下的解释器程序完成操作。会去环境设置寻找 python 目录,推荐这种写法
CONEMU Configuring environment variables
alias cl=conda env listalias cc=conda create -n $*alias coa=activate $*alias cod=deactivatealias cr=conda remove --all -n $*
Cmd
######################################################### 查看conda环境信息conda info -envs  or conda env list  ## 安装完整版本python2conda create -n XXX python=2 anaconda## 移除conda remove --all -n XXX## 创建只有django的python2环境. conda create -n XXX python=2 django## 输出配置pip freeze > PATH\FILENAME.txt## 导入配置pip install -r PATH\FILENAME.txt## 克隆整个环境conda create --clone SOURCE_NAME -n NEW_NAME##在ConEmu里打开VSCcode .##install jupyterpip install jupyter## 创建jupyter配置文件jupyter notebook --generate-config       # 用vsc修改该文件 : jupyter_notebook_config.pyc.NotebookApp.notebook_dir = u’PATCH’#######################################################
Configure get mirror Source address, in order to speed up
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/conda config --set show_channel_urls yes

Python environment variable configuration-Test article

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.