Skip to content
Merged
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
13 changes: 13 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,21 @@ jobs:
- name: QC
run: pixi run qc

test-unit:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- uses: prefix-dev/setup-pixi@v0.9.0
with:
cache: true

- name: Unit Tests
run: pixi run test-unit

test-fast:
runs-on: ubuntu-latest
needs: test-unit
steps:
- uses: actions/checkout@v4

Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -165,3 +165,5 @@ cython_debug/
# pixi environments
.pixi
*.egg-info

.envrc
818 changes: 289 additions & 529 deletions pixi.lock

Large diffs are not rendered by default.

2 changes: 2 additions & 0 deletions pixi.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ platforms = ["linux-64"]
version = "0.1.0"

[tasks]
test-unit = "pytest source/test_collect_plugins.py -v"
build = "sphinx-build source build"
apply-qc = [{ task = "style", environment = "style" }]
qc = [{ task = "lint", environment = "style" }]
Expand All @@ -30,6 +31,7 @@ gcc_linux-64 = ">=15.1.0,<16"
pkgconfig = ">=1.5.5,<2"
gitpython = ">=3.1.46,<4"
git = ">=2.53.0,<3"
pytest = ">=8.0.0,<9"

[pypi-dependencies]
sphinxawesome-theme = ">=5.3.2, <6"
Expand Down
2 changes: 2 additions & 0 deletions source/_static/custom.css
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
.image-reference img {
display: inline;
margin-right: 4px;
}

.image-reference {
border-bottom: none !important;
font-size: 0;
}

table code.literal {
Expand Down
2 changes: 1 addition & 1 deletion source/_templates/executor_plugin.rst.j2
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
{% block type %}executor{% endblock %}

{% block usage %}
In order to use the plugin, run Snakemake (>=8.0) in the folder where your workflow code and config resides (containing either ``workflow/Snakefile`` or ``Snakefile``) with the corresponding value for the executor flag::
In order to use the plugin, run Snakemake ({{ snakemake_version if snakemake_version else ">=8.0" }}) in the folder where your workflow code and config resides (containing either ``workflow/Snakefile`` or ``Snakefile``) with the corresponding value for the executor flag::

snakemake --executor {{ plugin_name }} --default-resources --jobs N ...

Expand Down
4 changes: 2 additions & 2 deletions source/_templates/logger_plugin.rst.j2
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
{% block type %}logger{% endblock %}

{% block usage %}
In order to use the plugin, run Snakemake (>=9.0) with the corresponding value for the logger flag::
In order to use the plugin, run Snakemake ({{ snakemake_version if snakemake_version else ">=9.0" }}) with the corresponding value for the logger flag::

snakemake --logger {{ plugin_name }} ...

with ``...`` being any additional arguments you want to use.
{% endblock %}
{% endblock %}
38 changes: 22 additions & 16 deletions source/_templates/plugin_base.rst.j2
Original file line number Diff line number Diff line change
Expand Up @@ -4,38 +4,44 @@
Snakemake {% block type %}{% endblock %} plugin: {{ plugin_name }}
###########################################

{% if repository is not none %}
{% if repository is not none -%}
.. image:: https://img.shields.io/badge/repository-{{ repository_type }}-blue?color=%23022c22
:target: {{ repository }}
{% else %}
{% else -%}
.. image:: https://img.shields.io/badge/repository-unknown-blue?color=%23022c22
:target: #
{% endif %}

{% if repository_type == "github" and repository is not none %}
{% set repo = repository.replace("https://github.com/", "").replace(".git", "").rstrip("/") %}
.. image:: https://img.shields.io/github/last-commit/{{ repo }}
{% endif -%}
{% if repository_type == "github" and repository is not none -%}
.. image:: https://img.shields.io/github/last-commit/{{ repo_shortname }}
:alt: GitHub - Last commit
:target: {{ repository }}
{% elif repository_type == "gitlab" and repository is not none %}
{% set repo = repository.replace("https://gitlab.com/", "").replace(".git", "").rstrip("/") %}
.. image:: https://img.shields.io/gitlab/last-commit/{{ repo }}
{% elif repository_type == "gitlab" and repository is not none -%}
.. image:: https://img.shields.io/gitlab/last-commit/{{ repo_shortname }}
:alt: GitLab - Last commit
:target: {{ repository }}
{% endif %}

{% for author in authors %}
{% elif commit_info is not none -%}
.. image:: https://img.shields.io/badge/last_commit-{{ commit_info["sha"] }}-green?color={{ commit_age_color }}
:alt: Last commit
:target: {{ commit_url }}
.. image:: https://img.shields.io/badge/last_updated-{{ commit_date_label }}-green?color={{ commit_age_color }}
:alt: Last updated
:target: {{ commit_url }}
Comment thread
johanneskoester marked this conversation as resolved.
{% endif -%}
{% for author in authors -%}
.. image:: https://img.shields.io/badge/author-{{author|replace("-","--")|urlencode}}-purple?color=%23064e3b
:target: https://pypi.org/project/{{ package_name }}
{% endfor %}

{% endfor -%}
.. image:: https://img.shields.io/pypi/v/{{ package_name }}?color=%23047857
:alt: PyPI - Version
:target: https://pypi.org/project/{{ package_name }}

.. image:: https://img.shields.io/pypi/l/{{ package_name }}?color=%2310b981
:alt: PyPI - License
:target: https://pypi.org/project/{{ package_name }}
{% if snakemake_version is not none %}
.. image:: https://img.shields.io/badge/snakemake-{{ snakemake_version|replace("-", "--") }}-blue?color=%230ea5e9
:alt: Snakemake
:target: https://snakemake.readthedocs.io
Comment thread
btraven00 marked this conversation as resolved.
{% endif %}

{% if repository is not none and not repository.startswith("https://github.com/snakemake/") %}
.. warning::
Expand Down
4 changes: 2 additions & 2 deletions source/_templates/report_plugin.rst.j2
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
{% block type %}report{% endblock %}

{% block usage %}
In order to use the plugin, run Snakemake (>=8.5) with the corresponding value for the reporter flag::
In order to use the plugin, run Snakemake ({{ snakemake_version if snakemake_version else ">=8.5" }}) with the corresponding value for the reporter flag::

snakemake --reporter {{ plugin_name }} ...

with ``...`` being any additional arguments you want to use.
{% endblock %}
{% endblock %}
2 changes: 1 addition & 1 deletion source/_templates/scheduler_plugin.rst.j2
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
{% block type %}scheduler{% endblock %}

{% block usage %}
In order to use the plugin, run Snakemake (>=9.0) with the corresponding value for the scheduler flag::
In order to use the plugin, run Snakemake ({{ snakemake_version if snakemake_version else ">=9.0" }}) with the corresponding value for the scheduler flag::

snakemake --scheduler {{ plugin_name }} ...

Expand Down
Loading
Loading