Skip to content

Commit

Permalink
Merge pull request #5570 from Gu1nness/5491-stats-repo-location
Browse files Browse the repository at this point in the history
create: add repository location to --stats output, fixes #5491
  • Loading branch information
ThomasWaldmann authored Dec 16, 2020
2 parents 5017bc4 + 9052c1c commit 908ea73
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/borg/archive.py
Original file line number Diff line number Diff line change
Expand Up @@ -497,6 +497,7 @@ def info(self):

def __str__(self):
return '''\
Repository: {location}
Archive name: {0.name}
Archive fingerprint: {0.fpr}
Time (start): {start}
Expand All @@ -508,7 +509,9 @@ def __str__(self):
self,
start=OutputTimestamp(self.start.replace(tzinfo=timezone.utc)),
end=OutputTimestamp(self.end.replace(tzinfo=timezone.utc)),
csize_max=self.cache.chunks[self.id].csize / MAX_DATA_SIZE)
csize_max=self.cache.chunks[self.id].csize / MAX_DATA_SIZE,
location=self.repository._location.canonical_path()
)

def __repr__(self):
return 'Archive(%r)' % self.name
Expand Down

0 comments on commit 908ea73

Please sign in to comment.