def METHOD_NAME():
    """
    Get ghostscript version.
    """
    os_name = sys.platform
    if os_name.startswith(("linux", "freebsd", "darwin")):
        cmds = ["gs"]
    elif os_name == "win32":
        cmds = ["gswin64c.exe", "gswin32c.exe"]
    else:
        return None
    for gs_cmd in cmds:
        try:
            return subprocess.check_output(
                [gs_cmd, "--version"], universal_newlines=True
            ).strip()
        except FileNotFoundError:
            continue
    return None