forked from TrueCloudLab/restic
Move restic package to internal/restic
This commit is contained in:
parent
94030a12cf
commit
23c903074c
179 changed files with 100 additions and 136 deletions
22
internal/restic/progress_unix.go
Normal file
22
internal/restic/progress_unix.go
Normal file
|
@ -0,0 +1,22 @@
|
|||
// +build !windows,!darwin
|
||||
|
||||
package restic
|
||||
|
||||
import (
|
||||
"os"
|
||||
"os/signal"
|
||||
"syscall"
|
||||
|
||||
"github.com/restic/restic/internal/debug"
|
||||
)
|
||||
|
||||
func init() {
|
||||
c := make(chan os.Signal)
|
||||
signal.Notify(c, syscall.SIGUSR1)
|
||||
go func() {
|
||||
for s := range c {
|
||||
debug.Log("Signal received: %v\n", s)
|
||||
forceUpdateProgress <- true
|
||||
}
|
||||
}()
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue