<s> import os <EOL> import sys <EOL> def write_and_flush ( pipe , message ) : <EOL> pipe . write ( message ) <EOL> pipe . flush ( ) <EOL> try : <EOL> import keyring <EOL> except ImportError : <EOL> write_and_flush ( sys . stderr , '<STR_LIT>' ) <EOL> sys . exit ( <NUM_LIT:1> ) <EOL> if __name__ == '<STR_LIT:__main__>' : <EOL> if len ( sys . argv ) <= <NUM_LIT:1> : <EOL> write_and_flush ( sys . stderr , '<STR_LIT>' ) <EOL> sys . exit ( <NUM_LIT:1> ) <EOL> variable = sys . argv [ <NUM_LIT:1> ] <EOL> value = keyring . get_password ( <EOL> os . environ . get ( '<STR_LIT>' , '<STR_LIT>' ) , <EOL> variable <EOL> ) <EOL> if value is None : <EOL> write_and_flush ( sys . stderr , '<STR_LIT>' . format ( variable ) ) <EOL> sys . exit ( <NUM_LIT:1> ) <EOL> write_and_flush ( sys . stdout , value ) </s>
