jigneshvasoya / ruffus

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

output_dir parameter for @transform to specify default output directory #73

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
As discussed on the forum: 
https://groups.google.com/forum/#!topic/ruffus_discuss/ErfMSsKNFB4, this 
parameter would specify a folder to put all intermediate/final files. Currently 
it can be done like this:

starting_files = [‘a.fasta’,’b.fasta’]
@mkdir('../output/')
@transform(starting_files,
           formatter(),
           '../output/{basename[0]}.sam')
def map_dna_sequence(input_file, output_file):
    ...

With this parameter formatter isn't required:

starting_files = [‘../input/a.fasta’,’../input/b.fasta’]
@transform(starting_files,
           suffix('.fasta'),
           output_dir('../output'),
           '.sam')
def map_dna_sequence(input_file, output_file):
    ...

Original issue reported on code.google.com by milan.mo...@gmail.com on 29 Oct 2014 at 8:57

GoogleCodeExporter commented 9 years ago

Original comment by bunbu...@gmail.com on 30 Oct 2014 at 11:01