# Python-Study

## Example 启动示例

1. config envirement 配置环境

    ```shell
    # linux part
    python3 -m venv .venv
    source .venv/bin/activate
    pip3 install -r requirements.txt

    # windows part
    python -m venv .venv
    .venv/Scripts/activate
    pip install -r requirements.txt
    ```

2. config config.yaml 配置配置文件(可选)

    ```shell
    # 配置配置文件参考docs文档
    # 如果你需要相应外部API
    # 可以不需要配置测试实现最基本的 echo 功能
    ```

3. run 运行

    ```shell
    # linux part
    python3 main.py

    # windows part
    python main.py
    ```

## Naming Conventions 命名规范

1. 大写下划线只用于表达常量

    > upper underscore only for constant value

    ```python
    CONSTANT_VALUE = 1
    ```

2. 大写驼峰只用于表示类定义时的名字

    > camel case only for class definition name

    ```python
    class ClassName:
        pass 
    ```

3. 其余全部使用小写下划线包括(module, variable, function, method)

    > lower underscore for other names

    ```python
    from module_name import *
    def func_name():
        var_name = 1
        pass
    ```

## Dev Manual 开发手册