comparison planemo/lib/python3.7/site-packages/virtualenv/seed/seeder.py @ 1:56ad4e20f292 draft

"planemo upload commit 6eee67778febed82ddd413c3ca40b3183a3898f1"
author guerler
date Fri, 31 Jul 2020 00:32:28 -0400
parents
children
comparison
equal deleted inserted replaced
0:d30785e31577 1:56ad4e20f292
1 from __future__ import absolute_import, unicode_literals
2
3 from abc import ABCMeta, abstractmethod
4
5 from six import add_metaclass
6
7
8 @add_metaclass(ABCMeta)
9 class Seeder(object):
10 """A seeder will install some seed packages into a virtual environment."""
11
12 # noinspection PyUnusedLocal
13 def __init__(self, options, enabled):
14 """
15
16 :param options: the parsed options as defined within :meth:`add_parser_arguments`
17 :param enabled: a flag weather the seeder is enabled or not
18 """
19 self.enabled = enabled
20
21 @classmethod
22 def add_parser_arguments(cls, parser, interpreter, app_data):
23 """
24 Add CLI arguments for this seed mechanisms.
25
26 :param parser: the CLI parser
27 :param app_data: the CLI parser
28 :param interpreter: the interpreter this virtual environment is based of
29 """
30 raise NotImplementedError
31
32 @abstractmethod
33 def run(self, creator):
34 """Perform the seed operation.
35
36 :param creator: the creator (based of :class:`virtualenv.create.creator.Creator`) we used to create this \
37 virtual environment
38 """
39 raise NotImplementedError