diff options
author | Kalin Staykov <k.t.staykov@gmail.com> | 2022-11-26 15:49:59 +0200 |
---|---|---|
committer | Michael Muré <batolettre@gmail.com> | 2023-01-11 14:58:58 +0100 |
commit | fc266b733cf0ea794209031e3500ab3f86db6cee (patch) | |
tree | bae1996ec19fb74446429200e52cdb942f60ac54 /repository/repo.go | |
parent | 9c50a359704f4edd2f33df6d256e032feae3a576 (diff) | |
download | git-bug-fc266b733cf0ea794209031e3500ab3f86db6cee.tar.gz |
add wipe sub-command that remove local bugs and identities
Diffstat (limited to 'repository/repo.go')
-rw-r--r-- | repository/repo.go | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/repository/repo.go b/repository/repo.go index 66baec65..c39051d5 100644 --- a/repository/repo.go +++ b/repository/repo.go @@ -76,10 +76,15 @@ type RepoCommon interface { GetRemotes() (map[string]string, error) } +type LocalStorage interface { + billy.Filesystem + RemoveAll(path string) error +} + // RepoStorage give access to the filesystem type RepoStorage interface { // LocalStorage return a billy.Filesystem giving access to $RepoPath/.git/git-bug - LocalStorage() billy.Filesystem + LocalStorage() LocalStorage } // RepoIndex gives access to full-text search indexes @@ -103,6 +108,9 @@ type Index interface { // DocCount returns the number of document in the index. DocCount() (uint64, error) + // Remove delete one document in the index. + Remove(id string) error + // Clear empty the index. Clear() error |