Commit b39ae0ee authored by Chris Cheshire's avatar Chris Cheshire
Browse files

Updated bedtools sort

parent b95493f8
Loading
Loading
Loading
Loading
+6 −5
Original line number Diff line number Diff line
@@ -19,10 +19,11 @@ process BEDTOOLS_SORT {
    }

    input:
    tuple val(meta), path(bed)
    tuple val(meta), path(intervals)
    val   extension

    output:
    tuple val(meta), path('*.bed'), emit: bed
    tuple val(meta), path("*.${extension}"), emit: sorted
    path  "versions.yml"                   , emit: versions

    script:
@@ -30,9 +31,9 @@ process BEDTOOLS_SORT {
    """
    bedtools \\
        sort \\
        -i $bed \\
        -i $intervals \\
        $options.args \\
        > ${prefix}.bed
        > ${prefix}.${extension}

    cat <<-END_VERSIONS > versions.yml
    ${getProcessName(task.process)}:
+13 −6
Original line number Diff line number Diff line
@@ -15,20 +15,26 @@ input:
        description: |
            Groovy Map containing sample information
            e.g. [ id:'test', single_end:false ]
    - bed:
    - intervals:
        type: file
        description: Input BED file
        pattern: "*.{bed}"
        description: BED/BEDGRAPH
        pattern: "*.{bed|bedGraph}"

    - extension:
        type: string
        description: Extension of the output file (e. g., ".bg", ".bedgraph", ".txt", ".tab", etc.) It is set arbitrarily by the user and corresponds to the file format which depends on arguments.
output:
    - meta:
        type: map
        description: |
            Groovy Map containing sample information
            e.g. [ id:'test', single_end:false ]
    - bed:

    - sorted:
        type: file
        description: Sorted BED file
        pattern: "*.{bed}"
        description: Sorted output file
        pattern: "*.${extension}"

    - versions:
        type: file
        description: File containing software versions
@@ -37,3 +43,4 @@ authors:
    - "@Emiller88"
    - "@sruthipsuresh"
    - "@drpatelh"
    - "@chris-cheshire"