Skip to content

Commit

Permalink
deploy method
Browse files Browse the repository at this point in the history
  • Loading branch information
johanneskoester committed Jan 29, 2025
1 parent bcf4106 commit 1c0312b
Showing 1 changed file with 3 additions and 12 deletions.
15 changes: 3 additions & 12 deletions snakemake_interface_software_deployment_plugins/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
import hashlib
from pathlib import Path
import sys
from typing import List, Optional, Self
from typing import Optional
import subprocess as sp

from snakemake_interface_software_deployment_plugins.settings import SoftwareDeploymentProviderSettingsBase
Expand All @@ -34,19 +34,9 @@ def decorate_shellcmd(self, cmd: str) -> str:
"""Decorate given shell command such that it runs within the environment."""
...

@abstractmethod
def deploy(self) -> None:
"""Deploy the environment to self.provider.deployment_path.
When issuing shell commands, the environment should use
self.provider.run(cmd: str) in order to ensure that it runs within eventual
parent environments (e.g. a container or an env module).
"""
...

@abstractmethod
def hash(self, hash_object) -> None:
"""Update given hash such that it changes whenever the environment
"""Update given hash object such that it changes whenever the environment
could potentially contain a different set of software (in terms of versions or
packages).
"""
Expand Down Expand Up @@ -96,6 +86,7 @@ def deployment_hash(self, hash_object) -> None:
def managed_deployment_hash(self) -> str:
return self._managed_generic_hash("deployment_hash")


class ArchiveableEnvBase(ABC):
@abstractmethod
def archive(self) -> None:
Expand Down

0 comments on commit 1c0312b

Please sign in to comment.