from snakemake.utils import min_version
min_version("7.0")

include: "rules/config.smk"
include: "rules/common.smk"

rule all:
  input:
    final_targets(),

include: "rules/ambient.smk"
include: "rules/barcoderank.smk"
include: "rules/nuclear_fraction.smk"
include: "rules/filterbycount.smk"

# Doublet callers are selected by config, not by conditional rule inclusion.
# Both rule files are always defined; `doublet.run` decides which outputs are
# ever requested, and `doublet.decider` decides which one removes cells. That
# keeps the DAG shape fixed no matter how the callers are configured, and it is
# why there is no skip flag left to thread through the includes.
include: "rules/doubletfinder.smk"
include: "rules/scdblfinder.smk"

include: "rules/filterdoublet.smk"
include: "rules/postproc.smk"
include: "rules/qcreport.smk"
include: "rules/slidereport.smk"
