comparison export_to_cluster.py @ 3:9838eed606ad draft default tip

planemo upload for repository https://github.com/TGAC/earlham-galaxytools/tree/master/tools/export_to_cluster/ commit 68b62fd9a9d5586ccd539779873af17124b7dbb5
author earlhaminst
date Wed, 09 May 2018 05:52:40 -0400
parents b97775e9fe06
children
comparison
equal deleted inserted replaced
2:b97775e9fe06 3:9838eed606ad
22 parser.error('Require an even number of arguments') 22 parser.error('Require an even number of arguments')
23 23
24 real_export_dir = os.path.realpath(options.export_dir) 24 real_export_dir = os.path.realpath(options.export_dir)
25 dir_prefix = options.dir_prefix.rstrip(os.sep) 25 dir_prefix = options.dir_prefix.rstrip(os.sep)
26 if not real_export_dir.startswith(dir_prefix): 26 if not real_export_dir.startswith(dir_prefix):
27 raise Exception("%s must be a subdirectory of %s" % (options.export_dir, dir_prefix)) 27 raise Exception("'%s' must be a subdirectory of '%s'" % (options.export_dir, dir_prefix))
28 if not os.path.exists(real_export_dir): 28 if not os.path.exists(real_export_dir):
29 raise Exception("%s does not exist or it is not accessible by the Galaxy user" % options.export_dir) 29 raise Exception("'%s' directory does not exist or it is not accessible by the Galaxy user" % options.export_dir)
30 if not os.path.isdir(real_export_dir): 30 if not os.path.isdir(real_export_dir):
31 raise Exception("%s is not a directory" % options.export_dir) 31 raise Exception("'%s' is not a directory" % options.export_dir)
32 32
33 dataset_paths = args[::3] 33 dataset_paths = args[::3]
34 dataset_names = args[1::3] 34 dataset_names = args[1::3]
35 dataset_exts = args[2::3] 35 dataset_exts = args[2::3]
36 exit_code = 0 36 exit_code = 0