Skip to content

Commit

Permalink
Added pushed flag
Browse files Browse the repository at this point in the history
  • Loading branch information
ntlhui committed Apr 28, 2023
1 parent 6b863ac commit b290bfa
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions e4e_data_management/data.py
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,7 @@ class Dataset:

__MANIFEST_NAME = 'manifest.json'
__CONFIG_NAME = '.e4edm.pkl'
VERSION = 1
VERSION = 2

def __init__(self, root: Path, day_0: dt.date):
self.root = root.resolve()
Expand All @@ -309,13 +309,15 @@ def __init__(self, root: Path, day_0: dt.date):
self.manifest = Manifest(self.root.joinpath(self.__MANIFEST_NAME))
self.committed_files: List[Path] = []
self.staged_files: List[Path] = []
self.pushed: bool = False
self.version = self.VERSION

def upgrade(self):
"""Upgrades self to latest version
"""
if self.version < 1:
pass
if self.version < 2:
self.pushed = False
self.version = 2

@classmethod
def load(cls, path: Path) -> Dataset:
Expand Down

0 comments on commit b290bfa

Please sign in to comment.