#NEWLINE# def write_to_console_repo( data ) : #NEWLINE# #INDENT# ' prints 25 tredning repositories on Github\n        NO NAME LANG STARS DESC\n    ' #NEWLINE# ( R , C ) = get_console_size ( ) #NEWLINE# printSize = get_col_size ( data ) #NEWLINE# COLOR = get_color_code_repo ( ) #NEWLINE# idx = 3 #NEWLINE# name = printSize [ 'NAME' ] #NEWLINE# lang = printSize [ 'LANG' ] #NEWLINE# star = printSize [ 'STAR' ] #NEWLINE# excludingDescSum = ( ( ( idx + name ) + lang ) + star ) #NEWLINE# desc = ( C - excludingDescSum ) #NEWLINE# printSize [ 'NAME' ] = ( - name ) #NEWLINE# printSize [ 'LANG' ] = ( - lang ) #NEWLINE# printSize [ 'IDX' ] = ( - idx ) #NEWLINE# printSize [ 'STAR' ] = ( - star ) #NEWLINE# printSize [ 'DESC' ] = desc #NEWLINE# click . echo ( ) #NEWLINE# click . secho ( ( '%*s' % ( printSize [ 'IDX' ] , '#' ) ) , nl = False , bold = True ) #NEWLINE# click . secho ( ( '%*s' % ( printSize [ 'NAME' ] , 'USER/REPO' ) ) , nl = False , bold = True ) #NEWLINE# click . secho ( ( '%*s' % ( R [ 'LANG' ] , 'LANG' ) ) , nl = False , bold = True ) #NEWLINE# click . secho ( ( '%*s' % ( printSize [ 'STAR' ] , 'STAR' ) ) , nl = False , bold = True ) #NEWLINE# click . secho ( ( '%*s' % ( ( - printSize [ 'DESC' ] ) , 'DESCRIPTION' ) ) , nl = False , bold = True ) #NEWLINE# for ( idx , eachRepo ) in enumerate ( data ) : #NEWLINE# #INDENT# click . echo ( ) #NEWLINE# click . secho ( ( '%*s' % ( printSize [ 'IDX' ] , str ( ( idx + 1 ) ) ) ) , nl = False , bold = True , fg = COLOR . IDX ) #NEWLINE# click . secho ( ( '%*s' % ( printSize [ 'NAME' ] , eachRepo [ 'NAME' ] ) ) , nl = False , bold = True , fg = COLOR . NAME ) #NEWLINE# click . secho ( ( '%*s' % ( printSize [ 'LANG' ] , eachRepo [ 'LANG' ] ) ) , nl = False , bold = True , fg = COLOR . LANG ) #NEWLINE# click . secho ( ( '%*s' % ( printSize [ 'STAR' ] , eachRepo [ 'STAR' ] ) ) , nl = False , bold = True , fg = COLOR . STARS ) #NEWLINE# print_each_description ( eachRepo [ 'DESC' ] , printSize [ 'DESC' ] , COLOR . DESC , excludingDescSum , C )