These are chat archives for nextflow-io/nextflow

16th
Mar 2019
Yasset Perez-Riverol
@ypriverol
Mar 16 09:35
Is this pattern supported inside processes in nextflow to define name of an output ${file%.ext}.ext. This is to get a new output file with the same name but different extension ??
Kevin Sayers
@KevinSayers
Mar 16 10:04
@ypriverol you can use baseName to get just the filename without extension e.g. ${file.baseName}.ext
Yasset Perez-Riverol
@ypriverol
Mar 16 10:06
file.baseName can be used within the script line ?
Kevin Sayers
@KevinSayers
Mar 16 10:08
process foo{
    echo true

    input:
    file x from file('test.txt')

    """
    echo ${x.baseName}
    """
}
Yasset Perez-Riverol
@ypriverol
Mar 16 10:09
thanks a lot