/*
This file includes default values for shared parameters.
*/

params {
    wf = "bactopia"
    list_wfs = false
    outdir = "bactopia"
    run_name = "${params.wf}"
    skip_compression = false
    keep_all_files = false
    merge_folder = "merged-results"

    //nf-core
    schema_ignore_params = 'prokka_debug,is_ci,sourmash_url,mash_url,mlst_url,amrfinder_url,merge_folder,wf_has_subdir,build_all,use_mamba,empty_proteins,empty_tf,empty_adapters,empty_phix,help_all,include_tools,min_time,publish_dir,silent,test_data,test_data_dir,verbose,schema_inputs,empty_extra,empty_r2,empty_r1,workflows,available_workflows,is_subworkflow,enable_conda,force_rebuild,config_profile_url,config_profile_contact,config_profile_description,config_profile_name'
    schema_inputs = ['fastqs', 'R1,R2,SE,sample,hybrid', 'R1,R2,sample', 'SE,sample', 'assembly,sample', 'accessions', 'accession']

    // Max Job Request Parameters
    max_retry = 3
    min_time = 60
    max_time = 120
    max_memory = 32
    max_cpus = 4
    max_downloads = 3

    // Nextflow Configuration Parameters
    /* Nextflow config files
    nfconfig - allows you to provide your own config file to Nextflow

    What this means is you can adjust process rules such as max runtimes, cpu and 
        memory usage, etc...

    Most importantly, this means you can create a profile that allows you to better
        use Bactopia in your environment. This will allow you to create a profile 
        for things such as Sun Grid Engine, SLURM, AWS, etc...

    If you provide a config, its loaded after the default configs. So any changes 
        to the defaults in your config will be reflected.

    Links to Nextflow Docs:
        Nextflow Docs: https://www.nextflow.io/docs/latest/config.html#scope-process
        Nextflow Docs: https://www.nextflow.io/docs/latest/config.html#config-profiles
        Nextflow Executors: https://www.nextflow.io/docs/latest/executor.html
    */
    nfconfig = null
    publish_dir_mode = 'copy'
    force = false
    cleanup_workdir = false

    // Nextflow Profile Parameters
    condadir = "${bactopia_cache}/conda"
    use_mamba = false
    singularity_cache = "${bactopia_cache}/singularity"
    singularity_pull_docker_container = false
    force_rebuild = false

    // Generic Parameters
    help = null
    help_all = false
    sleep_time = 5
    validate_params = true

    //nf-core
    monochrome_logs = false
    enable_conda = false
    show_hidden_params = false

    // Parameters to ignore
    build_all = false
    include_tools = null
    verbose = null
    silent = null

    // Datasets Parameters
    datasets_cache = "${bactopia_cache}/datasets"
    amrfinder_url = "https://datasets.bactopia.com/datasets/v${manifest.version}/amrfinderplus.tar.gz"
    mlst_url = "https://datasets.bactopia.com/datasets/v${manifest.version}/mlst.tar.gz"
    mash_url = "https://datasets.bactopia.com/datasets/mash-refseq88.k21.msh.xz"
    sourmash_url = "https://datasets.bactopia.com/datasets/gtdb-rs207.genomic-reps.dna.k31.lca.json.gz"
    
    // Testing
    test_data_dir = 'https://raw.githubusercontent.com/bactopia/bactopia-tests/main/data'
    is_ci = false
}
