Skip to content

Simplify params.current_basedir #99

@victorlin

Description

@victorlin

current_basedir = str(workflow.current_basedir),
benchmark:
"benchmarks/upload_to_s3/{remote_file}.txt"
log:
"logs/upload_to_s3/{remote_file}.txt"
shell:
r"""
exec &> >(tee {log:q})
{params.current_basedir}/../../../shared/vendored/scripts/upload-to-s3 \

Usage of workflow.current_basedir in upload.smk (first and last lines above) could be simplified. Two options:

  1. Use {workflow.basedir}

    • This is used elsewhere.

      {workflow.basedir}/../shared/vendored/scripts/fetch-from-ncbi-entrez \

    • Con: this makes the snakefile it appears in less portable in some ways, as the path is now based on the top-level Snakefile instead of the current file.

  2. Use {workflow.current_basedir!s}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions