def gen_img_code(github_url, alt, width=None, height=None):
    """
    Generate image markdown code with absolute URL link <deprecated>
    <img src="https://raw.githubusercontent.com/LinxiFan/temp/master/d500.png" 
    height="20" />
    github_path: <username>/<repo>/<branch>/<folders>/<filename>
    """
    alt = alt.replace('\n', ' ')
    if height or width:
        width = 'width="{}"'.format(width) if width else ''
        height = 'height="{}"'.format(height) if height else ''
        return '<img src="{}" alt="{}" {} {} />'.format(github_url, alt,
            width, height)
    else:
        return '![{}]({})'.format(alt, github_url)
