aboutsummaryrefslogtreecommitdiff
path: root/src/ee/project
diff options
context:
space:
mode:
Diffstat (limited to 'src/ee/project')
-rw-r--r--src/ee/project/__init__.py9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/ee/project/__init__.py b/src/ee/project/__init__.py
index 6c04c07..395d204 100644
--- a/src/ee/project/__init__.py
+++ b/src/ee/project/__init__.py
@@ -1,6 +1,7 @@
import configparser
import uuid
from pathlib import Path
+from typing import List
from ee import EeException
from ee.digikey import DigikeyStore
@@ -29,9 +30,9 @@ class SupplierDescriptor(object):
class Project(object):
def __init__(self, project_dir: Path, cfg: configparser.ConfigParser):
- self.report_dir = project_dir / "ee" / "reports"
self.public_dir = project_dir / "ee"
- self.cache_dir = project_dir / "ee" / "cache"
+ self.report_dir = self.public_dir / "reports"
+ self.cache_dir = self.public_dir / "cache"
self.project_dir = project_dir
self._cfg = cfg
@@ -47,6 +48,10 @@ class Project(object):
digikey_store = DigikeyStore.from_store_code("us")
self._suppliers.append(SupplierDescriptor("digikey", digikey_store.url, "Digikey"))
+ @property
+ def suppliers(self) -> List[SupplierDescriptor]:
+ return self._suppliers
+
def get_supplier_by_key(self, key) -> SupplierDescriptor:
sd = next((s for s in self._suppliers if s.key == key), None)
if sd: