Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion modules/local/nextflow/run/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ process NEXTFLOW_RUN {
val samplesheet // pipeline samplesheet
val additional_config // custom configs
val cache_dir // cache directory
val run_name // run name for Tower

output:
path "results", emit: output
Expand All @@ -22,11 +23,16 @@ process NEXTFLOW_RUN {
// Set cache directory so workflow can `-resume`
def cache_path = file(cache_dir)
assert cache_path.mkdirs()
// Create timestamp for an unique run name
def timestamp = new Date().format("yyyy-MM-dd_HH-mm-ss")
// Construct nextflow command
def nxf_cmd = [
'nextflow run',
'nextflow',
'-log .nextflow.log',
'run',
pipeline_name,
nextflow_opts,
"-name ${run_name}_${timestamp}",
params_file ? "-params-file $params_file" : '',
additional_config ? "-c $additional_config" : '',
samplesheet ? "--input $samplesheet" : '',
Expand Down
1 change: 1 addition & 0 deletions modules/local/nextflow/run/tests/main.nf.test
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ nextflow_process {
input[3] = ''
input[4] = ''
input[5] = workflow.workDir.resolve('nf-core/demo').toUriString()
input[6] = 'test_case_id'
"""
}
}
Expand Down
2 changes: 2 additions & 0 deletions workflows/oncoflow.nf
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ workflow ONCOFLOW {
val_oncoanalyser_samplesheet,
val_oncoanalyser_config ? val_oncoanalyser_config : val_config,
workflow.workDir.resolve('nf-core/oncoanalyser').toUriString(),
val_case_id,
)

def oncorefiner_params_list = getOncorefinerParamsList(
Expand All @@ -79,6 +80,7 @@ workflow ONCOFLOW {
'',
val_oncorefiner_config ? val_oncorefiner_config : val_config,
workflow.workDir.resolve('Clinical-Genomics/oncorefiner').toUriString(),
val_case_id,
)

//
Expand Down
Loading