apcamargo / genomad

geNomad: Identification of mobile genetic elements
https://portal.nersc.gov/genomad/
Other
169 stars 17 forks source link

CLI option to set output prefix #76

Open zclaas opened 4 months ago

zclaas commented 4 months ago

Hi, Thanks for genomad, it is much more convenient and user-friendly than the alternatives I've seen. I was wondering if you would consider making it possible to change the prefix used by output files and directories. When running on a spades assembly, the input is /contigs.fasta, which results in the prefix for everything being "contigs". It might be more convenient to have an option to specify a custom prefix rather than renaming the input files. But this is of course a fairly minor issue, so it may not justify the effort required.

apcamargo commented 4 months ago

That's a good suggestion. Thank you for your input!

I'll definitely look into integrating this in the near future. The way the code is structured right now is very reliant on the automatically determined prefix, but I thought of a couple of approaches to make custom prefixes possible.

For your particular case, you could create a symbolic link for the contig file using whichever name you want. This way you don't need to copy data and your geNomad outputs can have more meaningful names, while keeping the original spades output.

ln -s <spades_dir>/contigs.fasta meaningful_name.fna
genomad end-to-end meaningful_name.fna genomad_output genomad_db