Changeset - 0a023c381350
[Not reviewed]
beta
0 1 0
Marcin Kuzminski - 13 years ago 2013-05-12 00:26:47
marcin@python-works.com
gist cli should convert given paths to basenames
1 file changed with 1 insertions and 1 deletions:
0 comments (0 inline, 0 general)
rhodecode/bin/rhodecode_gist.py
Show inline comments
 
@@ -110,25 +110,25 @@ def _run(argv):
 
            gist_content = sys.stdin.read()
 
        elif stat.S_ISREG(mode):
 
            # "stdin is redirected"
 
            gist_content = sys.stdin.read()
 
        else:
 
            # "stdin is terminal"
 
            pass
 

	
 
    # make sure we don't upload binary stuff
 
    if gist_content and '\0' in gist_content:
 
        raise Exception('Error: binary files upload is not possible')
 

	
 
    filename = args.filename or filename
 
    filename = os.path.basename(args.filename or filename)
 
    if gist_content:
 
        files = {
 
            filename: {
 
                'content': gist_content,
 
                'lexer': None
 
            }
 
        }
 

	
 
        margs = dict(
 
            gist_lifetime=args.lifetime,
 
            gist_description=args.description,
 
            gist_type='private' if args.private else 'public',
0 comments (0 inline, 0 general)