예제 #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
파일: dag.py 프로젝트: Lin-Buo-Ren/git-cola
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)