def main():
    """
        main method
    """
    return_values = {
                        -1: "Something went wrong.",
                        -2: "Wrong username/password.",
                        -3: "Service unavailable."
                    }

    # initialize parser
    usage = "usage: %prog [-u USER] [-p PASSWORD] [-t TITLE] url"
    parser = OptionParser(usage, version="%prog "+VERSION)
    parser.add_option("-u", "--user", action="store", dest="user",
                      metavar="USER", help="instapaper username")
    parser.add_option("-p", "--password", action="store", dest="password",
                      metavar="USER", help="instapaper password")
    parser.add_option("-t", "--title", action="store", dest="title",
                      metavar="TITLE", help="title of the link to add")

    (options, args) = parser.parse_args()

    if not options.title:
        title = ""
    else:
        title = options.title
    if not 0 > len(args):
        parser.error("What do you want to read later?")

    if not options.user:
        # auth regex
        login = re.compile("(.+?):(.+)")
        try:
            config = open(os.path.expanduser("~") + "/.instapaperrc")
            for line in config:
                matches = login.match(line)
                if matches:
                    user = matches.group(1).strip()
                    password = matches.group(2).strip()
        except IOError:
            parser.error("No login information present.")
            sys.exit(-1)
    else:
        user = options.user
        # make sure all parameters are present
        if not options.password:
            password = getpass()
        else:
            password = options.password

    inst = Instapaper(user, password)
    result = inst.add_item(args[0], title)
    print return_values.get(result)
dataset/ETHPy150Open mrtazz/instapaper.py/instapaper.py/main/swapped operands of `>`