def get_output(target_file, pconfig):
    """Retrieve an output file from pack configuration.
    """
    if pconfig["type"] == "S3":
        keyname = "%s/%s" % (tz.get_in(["folders", "output"], pconfig), os.path.basename(target_file))
        _transfer_s3(target_file, keyname, tz.get_in(["buckets", "run"], pconfig))
        return target_file
    else:
        raise NotImplementedError("Unexpected pack information for fetchign output: %s" % pconfig)

# ## S3
dataset/ETHPy150Open chapmanb/bcbio-nextgen-vm/bcbiovm/ship/reconstitute.py/get_output/original