#!/usr/bin/env python

import argparse
from galaxy_ie_helpers import put

if __name__ == '__main__':
    parser = argparse.ArgumentParser(description='Put datasets back into Galaxy.')
    parser.add_argument('-p', '--filepath', 
        required = True,
        nargs='+',
        help='Specify the path to the files that should be uploaded to Galaxy.')
    parser.add_argument('-t', '--filetype', help='Galaxy file format. If not specified Galaxy will try to guess the filetype automatically.', default='auto')
    parser.add_argument('--history-id', dest="history_id", default=None, 
        help='History ID. The history ID and the dataset ID uniquly identify a dataset. Per default this is set to the current Galaxy history.')
    args = parser.parse_args()

    put( args.filepath, file_type=args.filetype, history_id=args.history_id )
