コード例 #1
0
ファイル: generate.py プロジェクト: banlyst/docs-tools
def redirects(args):
    c = fetch_config(args)

    if args.dry_run is True:
        print(''.join(make_redirect(c)))
    else:
        with BuildApp.context(c) as app:
            redirect_tasks(c, app)
コード例 #2
0
def redirects(args):
    c = fetch_config(args)

    if args.dry_run is True:
        print(''.join(make_redirect(c)))
    else:
        with BuildApp.new(pool_type=c.runstate.runner,
                          pool_size=c.runstate.pool_size,
                          force=c.runstate.force).context() as app:
            app.extend_queue(redirect_tasks(c))
コード例 #3
0
def redirects(args):
    c = fetch_config(args)

    if args.dry_run is True:
        print(''.join(make_redirect(c)))
    else:
        with BuildApp.new(pool_type=c.runstate.runner,
                          pool_size=c.runstate.pool_size,
                          force=c.runstate.force).context() as app:
            app.extend_queue(redirect_tasks(c))
コード例 #4
0
ファイル: generate.py プロジェクト: rawfalafel/docs-tools
def redirects(args):
    c = fetch_config(args)

    if args.dry_run is True:
        print("".join(make_redirect(c)))
    else:
        app = BuildApp(c)

        redirect_tasks(c, app)
        app.run()