Exemple #1
0
def read_license():
    license_paths = [data_path("COPYING"), "/usr/share/common-licenses/GPL-2"]
    for license_file in license_paths:
        if license_file is not None and os.path.exists(license_file):
            return file(license_file).read()
    # Fall back to just license name if we can't find the file
    return "GPLv2 or later"
Exemple #2
0
def load_credits():
    import pickle
    try:
        credits = pickle.load(file(data_path("credits.pickle")))
    except IOError:
        credits = None
    return credits