jigneshvasoya / ruffus

Automatically exported from code.google.com/p/ruffus
MIT License
0 stars 0 forks source link

feature request: a command line tool to call ruffus pipelines #31

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
It would be nice to have a command line tool to call a ruffus pipeline.

For example, something in the style of make, or nosetests for python. By 
calling the command from a command line, it should execute pipeline_run with 
default parameters from a specified file. It should accept flags like --verbose 
to change the level of verbosity of the messages, --print_only to make it print 
the commands that would be executed without actually executing them, and 
--parallel # to execute it on multiple cpus. Another nice option could be 
--qsub, to transform all the commands to qsub commands.
By typing ruffus on the command line and by pressing the <tab> key for 
autocompletition, you should have a list of all the tasks included in the 
ruffus file, and be able to execute only one of them.

Original issue reported on code.google.com by dalloli...@gmail.com on 23 Jul 2010 at 9:18

GoogleCodeExporter commented 9 years ago
$: ruffus -f pipeline.py 
# execute the main pipeline defined in the file pipeline.py

$: ruffus -f pipeline.py --verbose 5
# execute the main pipeline defined in the file pipeline.py, with verbosity=5

$: ruffus -f pipeline.py --print_only
# print all the commands that would be executed in pipeline.py, without 
actually executing them

$: ruffus -f pipeline.py --force
# execute the main pipeline defined in the file pipeline.py, and force the 
execution of all the task, even the ones that are already up to date.

$: ruffus -f pipeline.py --qsub --qsub_options 'q=medium'
# execute the main pipeline defined in the file pipeline.py, all the commands 
are submitted with the qsub system

$: ruffus -f pipeline.py --task hello_world
# execute the task 'hello_world' from the file pipeline.py

Original comment by dalloli...@gmail.com on 23 Jul 2010 at 9:31

GoogleCodeExporter commented 9 years ago
Very seductive idea.

It might be possible to have a qt gui version of the same as well, with on the 
fly feedback of the progress.

The <tab> for autocompletion might not be possible under linux, or even Windows.

Have to get my head around the logistics / plumbing for doing this though. 
Essentially this "ruffus" programme would be running as the main python script, 
and your python script actually turns into a module. Needs a fair bit of 
experimentation I think, and I wonder if it might make a difference to have 
scripts not running as "main".

In the meantime, the documentation includes a standard template for running 
Ruffus, with all the above options. See 
http://www.ruffus.org.uk/examples/code_template/code_template.html

It might be worthwhile rolling this functionality into ruffus properly as a 
commandline parsing module.

Original comment by bunbu...@gmail.com on 25 Aug 2010 at 5:26

GoogleCodeExporter commented 9 years ago

Original comment by bunbu...@gmail.com on 14 May 2014 at 10:34