makemigrations.py 文件源码

python
阅读 31 收藏 0 点赞 0 评论 0

项目:dj-paypal 作者: HearthSim 项目源码 文件源码
def run(*args):
    """
    Check and/or create dj-stripe Django migrations.

    If --check is present in the arguments then migrations are checked only.
    """
    if not settings.configured:
        settings.configure(**DEFAULT_SETTINGS)

    django.setup()

    parent = os.path.dirname(os.path.abspath(__file__))
    sys.path.insert(0, parent)

    if "--check" in args:
        check_migrations()
    else:
        django.core.management.call_command("makemigrations", APP_NAME, *args)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号