()
return base_url % target
Choose the manual to open based on LANGUAGE
Choose the manual to open based on LANGUAGE
Choose the manual to open based on LANGUAGE
def manual_lookup():
    '''Choose the manual to open based on LANGUAGE'''
    available_languages = ['en']
    base_url = 'http://gnome-terminator.readthedocs.io/%s/latest/'
    target = 'en'   # default to English
    if 'LANGUAGE' in os.environ:
        languages = os.environ['LANGUAGE'].split(':')
        for language in languages:
            if language in available_languages:
                target = language
                break
    elif 'LANG' in os.environ:
        language = os.environ['LANG'].split('.')[0]
        for i in range(len(available_languages)):
            if language == available_languages[i]:
                target = language
                break
    return base_url % target
def manual_lookup ( ) : available_languages = [ 'en' ] base_url = 'http://gnome-terminator.readthedocs.io/%s/latest/' target = 'en' # default to English if 'LANGUAGE' in os . environ : languages = os . environ [ 'LANGUAGE' ] . split ( ':' ) for language in languages : if language in available_languages : target = language break elif 'LANG' in os . environ : language = os . environ [ 'LANG' ] . split ( '.' ) [ 0 ] for i in range ( len ( available_languages ) ) : if language == available_languages [ i ] : target = language break return base_url % target