Пример #1
0
def cmd_pull(args):
    context = application_init(args, update=True)
    from cola.widgets import remote
    view = remote.pull()
    if args.rebase:
        view.set_rebase(True)
    return application_start(context, view)
Пример #2
0
def cmd_pull(args):
    context = application_init(args, update=True)
    from cola.widgets import remote
    view = remote.pull()
    if args.rebase:
        view.set_rebase(True)
    return application_start(context, view)
Пример #3
0
def main():
    """Start a git-cola-sequence-editor session"""
    args = parse_args()
    context = app.application_init(args)
    view = new_window(context, args.filename)
    app.application_run(context, view, start=view.start, stop=stop)
    return view.status
Пример #4
0
def cmd_fetch(args):
    # TODO: the calls to update_status() can be done asynchronously
    # by hooking into the message_updated notification.
    context = application_init(args)
    from cola.widgets import remote
    context.model.update_status()
    view = remote.fetch()
    return application_start(context, view)
Пример #5
0
def cmd_tag(args):
    context = application_init(args)
    from cola.widgets.createtag import new_create_tag
    view = new_create_tag(name=args.name,
                          ref=args.ref,
                          sign=args.sign,
                          settings=args.settings)
    return application_start(context, view)
Пример #6
0
def cmd_fetch(args):
    # TODO: the calls to update_status() can be done asynchronously
    # by hooking into the message_updated notification.
    context = application_init(args)
    from cola.widgets import remote
    context.model.update_status()
    view = remote.fetch()
    return application_start(context, view)
Пример #7
0
def cmd_archive(args):
    context = application_init(args, update=True)
    if args.ref is None:
        args.ref = context.model.currentbranch

    from cola.widgets.archive import GitArchiveDialog
    view = GitArchiveDialog(args.ref)
    return application_start(context, view)
Пример #8
0
def cmd_archive(args):
    context = application_init(args, update=True)
    if args.ref is None:
        args.ref = context.model.currentbranch

    from cola.widgets.archive import GitArchiveDialog
    view = GitArchiveDialog(args.ref)
    return application_start(context, view)
Пример #9
0
def cmd_cola(args):
    status_filter = args.status_filter
    if status_filter:
        status_filter = core.abspath(status_filter)

    context = application_init(args)
    from cola.widgets.main import MainView
    view = MainView(context.model, settings=args.settings)
    if args.amend:
        cmds.do(cmds.AmendMode, True)

    if status_filter:
        view.set_filter(core.relpath(status_filter))

    return application_start(context, view)
Пример #10
0
def cmd_cola(args):
    status_filter = args.status_filter
    if status_filter:
        status_filter = core.abspath(status_filter)

    context = application_init(args)
    from cola.widgets.main import MainView
    view = MainView(context.model, settings=args.settings)
    if args.amend:
        cmds.do(cmds.AmendMode, True)

    if status_filter:
        view.set_filter(core.relpath(status_filter))

    return application_start(context, view)
Пример #11
0
def cmd_grep(args):
    context = application_init(args)
    from cola.widgets import grep
    text = subprocess.list2cmdline(map(core.decode, args.args))
    view = grep.new_grep(text=text, parent=None)
    return application_start(context, view)
Пример #12
0
def cmd_am(args):
    context = application_init(args)
    from cola.widgets.patch import new_apply_patches
    view = new_apply_patches(patches=args.patches)
    return application_start(context, view)
Пример #13
0
def cmd_dag(args):
    """Run git-dag via the `git cola dag` sub-command"""
    context = app.application_init(args)
    view = git_dag(context, args=args, settings=args.settings, show=False)
    return app.application_start(context, view)
Пример #14
0
def cmd_stash(args):
    context = application_init(args)
    from cola.widgets.stash import stash
    view = stash()
    return application_start(context, view)
Пример #15
0
def cmd_find(args):
    context = application_init(args)
    from cola.widgets import finder
    paths = core.list2cmdline(args.paths)
    view = finder.finder(paths=paths)
    return application_start(context, view)
Пример #16
0
def cmd_diff(args):
    context = application_init(args)
    from cola.difftool import diff_expression
    expr = core.list2cmdline(args.args)
    view = diff_expression(None, expr, create_widget=True)
    return application_start(context, view)
Пример #17
0
def cmd_branch(args):
    context = application_init(args, update=True)
    from cola.widgets.createbranch import create_new_branch
    view = create_new_branch()
    return application_start(context, view)
Пример #18
0
def cmd_branch(args):
    context = application_init(args, update=True)
    from cola.widgets.createbranch import create_new_branch
    view = create_new_branch(settings=args.settings)
    return application_start(context, view)
Пример #19
0
def cmd_config(args):
    context = application_init(args)
    from cola.widgets.prefs import preferences
    view = preferences()
    return application_start(context, view)
Пример #20
0
def cmd_find(args):
    context = application_init(args)
    from cola.widgets import finder
    paths = subprocess.list2cmdline(map(core.decode, args.paths))
    view = finder.finder(paths=paths)
    return application_start(context, view)
Пример #21
0
def cmd_browse(args):
    context = application_init(args)
    from cola.widgets.browse import worktree_browser
    view = worktree_browser(update=False, settings=args.settings)
    return application_start(context, view)
Пример #22
0
def cmd_diff(args):
    context = application_init(args)
    from cola.difftool import diff_expression
    expr = subprocess.list2cmdline(map(core.decode, args.args))
    view = diff_expression(None, expr, create_widget=True)
    return application_start(context, view)
Пример #23
0
def cmd_dag(args):
    context = application_init(args)
    from cola.widgets.dag import git_dag
    view = git_dag(context.model, args=args, settings=args.settings)
    return application_start(context, view)
Пример #24
0
def cmd_config(args):
    context = application_init(args)
    from cola.widgets.prefs import preferences
    view = preferences()
    return application_start(context, view)
Пример #25
0
def cmd_browse(args):
    context = application_init(args)
    from cola.widgets.browse import worktree_browser
    view = worktree_browser(update=False, settings=args.settings)
    return application_start(context, view)
Пример #26
0
def cmd_merge(args):
    context = application_init(args, update=True)
    from cola.widgets.merge import MergeView
    view = MergeView(context.cfg, context.model, parent=None)
    return application_start(context, view)
Пример #27
0
def cmd_dag(args):
    context = application_init(args)
    from cola.widgets.dag import git_dag
    view = git_dag(context.model, args=args, settings=args.settings)
    return application_start(context, view)
Пример #28
0
def cmd_find(args):
    context = application_init(args)
    from cola.widgets import finder
    paths = core.list2cmdline(args.paths)
    view = finder.finder(paths=paths)
    return application_start(context, view)
Пример #29
0
def cmd_merge(args):
    context = application_init(args, update=True)
    from cola.widgets.merge import MergeView
    view = MergeView(context.cfg, context.model, parent=None)
    return application_start(context, view)
Пример #30
0
def cmd_am(args):
    context = application_init(args)
    from cola.widgets.patch import new_apply_patches
    view = new_apply_patches(patches=args.patches)
    return application_start(context, view)
Пример #31
0
def cmd_grep(args):
    context = application_init(args)
    from cola.widgets import grep
    text = core.list2cmdline(args.args)
    view = grep.new_grep(text=text, parent=None)
    return application_start(context, view)
Пример #32
0
def cmd_push(args):
    context = application_init(args, update=True)
    from cola.widgets import remote
    view = remote.push()
    return application_start(context, view)
Пример #33
0
def cmd_push(args):
    context = application_init(args, update=True)
    from cola.widgets import remote
    view = remote.push()
    return application_start(context, view)
Пример #34
0
def cmd_remote(args):
    context = application_init(args)
    from cola.widgets import editremotes
    view = editremotes.new_remote_editor()
    return application_start(context, view)
Пример #35
0
def cmd_remote(args):
    context = application_init(args)
    from cola.widgets import editremotes
    view = editremotes.new_remote_editor()
    return application_start(context, view)
Пример #36
0
def cmd_stash(args):
    context = application_init(args)
    from cola.widgets.stash import stash
    view = stash()
    return application_start(context, view)
Пример #37
0
def cmd_tag(args):
    context = application_init(args)
    from cola.widgets.createtag import new_create_tag
    view = new_create_tag(name=args.name, ref=args.ref, sign=args.sign,
                          settings=args.settings)
    return application_start(context, view)
Пример #38
0
def cmd_dag(args):
    """Run git-dag via the `git cola dag` sub-command"""
    context = app.application_init(args)
    view = git_dag(context, args=args, settings=args.settings, show=False)
    return app.application_start(context, view)