1
0
mirror of https://github.com/restic/restic.git synced 2024-06-26 07:49:01 +02:00
restic/internal/restic/progress_unix.go

23 lines
369 B
Go
Raw Normal View History

// +build !windows,!darwin,!freebsd,!netbsd,!openbsd,!dragonfly,!solaris
package restic
import (
"os"
"os/signal"
"syscall"
2017-07-23 14:21:03 +02:00
"github.com/restic/restic/internal/debug"
)
func init() {
c := make(chan os.Signal)
signal.Notify(c, syscall.SIGUSR1)
go func() {
for s := range c {
2016-09-27 22:35:08 +02:00
debug.Log("Signal received: %v\n", s)
forceUpdateProgress <- true
}
}()
}