diff --git a/lib/tfw/components/snapshot_provider.py b/lib/tfw/components/snapshot_provider.py index 052966b..e051238 100644 --- a/lib/tfw/components/snapshot_provider.py +++ b/lib/tfw/components/snapshot_provider.py @@ -41,18 +41,28 @@ class SnapshotProvider: def take_snapshot(self): if self._head_detached: self._checkout_new_branch_from_head() - self._run(('git', 'add', '-A')) - self._run(('git', 'commit', '-m', 'Snapshot')) + self._run(( + 'git', 'add', + '-A' + )) + self._run(( + 'git', 'commit', + '-m', 'Snapshot' + )) def _checkout_new_branch_from_head(self): head_hash = self._get_head_hash() self._run(( 'git', 'checkout', - '-b', head_hash, head_hash + '-b', head_hash, + head_hash )) def _get_head_hash(self): - return self._get_stdout(('git', 'rev-parse', 'HEAD')) + return self._get_stdout(( + 'git', 'rev-parse', + 'HEAD' + )) def restore_snapshot(self, date): commit = self._get_commit_from_timestamp(date)