add flip to manager
This commit is contained in:
@@ -430,6 +430,8 @@ def print_rest_api(shares, config, opts):
|
||||
print_rest_api_direct(config, share, token, opts.filename)
|
||||
elif opts.type == "zip":
|
||||
print_rest_api_zip(config, share, token)
|
||||
elif opts.type == "flip":
|
||||
print_rest_api_flip(config, share, token)
|
||||
elif opts.type == "client":
|
||||
print_rest_api_client(config, share, token)
|
||||
|
||||
@@ -545,6 +547,15 @@ def print_rest_api_upload(config, share, token):
|
||||
))
|
||||
|
||||
|
||||
def print_rest_api_flip(config, share, token):
|
||||
print("flip: fleese clipboard client download:")
|
||||
print("%s/flip/%s/%s"%(
|
||||
config['public_url'],
|
||||
share['name'],
|
||||
token
|
||||
))
|
||||
|
||||
|
||||
def print_rest_api_zip(config, share, token):
|
||||
print("ZIP download:")
|
||||
print("%s/zip/%s/%s"%(
|
||||
@@ -687,7 +698,7 @@ def parse_options():
|
||||
parser_rest = subparsers.add_parser('rest', help = "Display REST API links")
|
||||
parser_rest.add_argument(dest="name", help = "Name of the share")
|
||||
parser_rest.add_argument(dest="type", help = "Type of command",
|
||||
choices = ['client','direct','download','list','login','upload','zip']
|
||||
choices = ['client','direct','download','flip','list','login','upload','zip']
|
||||
)
|
||||
parser_rest.add_argument(dest="filename", help = "File name for download/direct queries",
|
||||
nargs = '?',
|
||||
|
||||
Reference in New Issue
Block a user