def stat_mode_to_index_mode(mode):
    if S_ISLNK(mode):   # symlinks
        return S_IFLNK
    if S_ISDIR(mode) or S_IFMT(mode) == S_IFGITLINK:    # submodules
        return S_IFGITLINK
    return S_IFREG | 0o644 | (mode & 0o100)       # blobs with or without executable bit
For generating a single piece of content from content tagged testimonial
dataset/ETHPy150Open gitpython-developers/GitPython/git/index/fun.py/stat_mode_to_index_mode--crossover with--dataset/ETHPy150Open davemerwin/blue-channel/bluechannel/page/templatetags/page_tags.py/show_random_testimonial