Add locking functions

This commit is contained in:
Alexander Neumann committed 2015-06-28 13:52:22 +02:00
1 parent 26e4d2e019
commit d51fd436b5
4 files changed
+424 -1

No files matched your search

+13 -1
View File
@@ -126,7 +126,19 @@ func (cmd CmdCat) Execute(args []string) error {
fmt.Println(string(buf))
return nil
case "lock":
return errors.New("not yet implemented")
lock, err := restic.LoadLock(s, id)
if err != nil {
return err
}
buf, err := json.MarshalIndent(&lock, "", " ")
if err != nil {
return err
}
fmt.Println(string(buf))
return nil
}
// load index, handle all the other types