feat: allow access to relocated repos
This commit is contained in:
parent
381cf6b44b
commit
064444db38
2 changed files with 2 additions and 0 deletions
1
info.go
1
info.go
|
@ -34,6 +34,7 @@ func (info *Info) LastmodUnix() float64 {
|
|||
func GetInfo(path string) (*Info, error) {
|
||||
cmd := exec.Command("borg", "info", "--json", path)
|
||||
cmd.Env = append(cmd.Env, "BORG_UNKNOWN_UNENCRYPTED_REPO_ACCESS_IS_OK=yes")
|
||||
cmd.Env = append(cmd.Env, "BORG_RELOCATED_REPO_ACCESS_IS_OK=yes")
|
||||
|
||||
stdout, err := cmd.Output()
|
||||
if err != nil {
|
||||
|
|
1
list.go
1
list.go
|
@ -28,6 +28,7 @@ func (list *List) LastArchiveUnix() float64 {
|
|||
func GetList(path string) (*List, error) {
|
||||
cmd := exec.Command("borg", "list", "--json", path)
|
||||
cmd.Env = append(cmd.Env, "BORG_UNKNOWN_UNENCRYPTED_REPO_ACCESS_IS_OK=yes")
|
||||
cmd.Env = append(cmd.Env, "BORG_RELOCATED_REPO_ACCESS_IS_OK=yes")
|
||||
|
||||
stdout, err := cmd.Output()
|
||||
if err != nil {
|
||||
|
|
Loading…
Reference in a new issue