示例#1
0
def detail():
    targets, type_ = parse_args('get_detail')
    if type_ == 'tag':
        res = get_tags_property(targets)
    else:
        res = get_paths_property(targets)
    return pack_result(res)
示例#2
0
def cp():
    res = copy(*parse_args('copy'))
    return pack_result(res)
示例#3
0
def rm():
    '''删除文件'''
    res = remove(*parse_args('remove'))
    return pack_result(res)
示例#4
0
def tab():
    '''获取命令行帮助信息'''
    return pack_result(tab_cmd(*parse_args('tab_cmd')))
示例#5
0
def help():
    '''获取命令行帮助信息'''
    return pack_result(help_cmd(*parse_args('help')))
示例#6
0
def alias():
    '''设置别名'''
    res = set_alias(*parse_args('alias'))
    return pack_result(res)
示例#7
0
def unfold():
    res = unfold_tag(*parse_args('unfold'))
    return pack_result(res)
示例#8
0
def newtag():
    result = new_tag(*parse_args('new_tag'))
    return pack_result(result)
示例#9
0
def open():
    res = open_file(*parse_args('open_file'))
    return pack_result(res)
示例#10
0
def cd():
    res = list_path(*parse_args('list_path'), cd=True)
    return pack_result(res)
示例#11
0
def changetag():
    return pack_result(change_tag(*parse_args('change_tag')))
示例#12
0
def rmtag():
    return pack_result(rm_tag(*parse_args('rm_tag')))
示例#13
0
def listPath():
    res = list_path(*parse_args('list_path'))
    return pack_result(res)
示例#14
0
def mv():
    res = move(*parse_args('move'))
    return pack_result(res)
示例#15
0
def readfile():
    '''读取文件内容'''
    data, response_type = get_file(*parse_args('read_file'))
    # if type_ == 'file':
    #     response = pack_result({})
    return pack_result(data, response_type)
示例#16
0
def mkdir():
    res = newdir(*parse_args('new_dir'))
    return pack_result(res)
示例#17
0
def tree():
    '''按标签路径访问'''
    path = request.args.get(req_conf['copy_args'][0])
    res = newdir(path, opts)
    return pack_result(res)
示例#18
0
def settag():
    result = set_tag(*parse_args('set_tag'))
    return pack_result(result)
示例#19
0
def modtag():
    res = mod_tag(*parse_args('mod_tag'))
    return pack_result(res)