git/orchard/main
tui/internal/plan/signal_unix.go
19 lines601 B last change raw · history
//go:build !windows

package plan

import (
	"os"
	"syscall"
)

// interruptSignal is SIGINT: pacman and makepkg install handlers that unwind a
// half-finished transaction on it. SIGKILL would leave the package database in
// exactly the state the tool exists to avoid.
func interruptSignal() os.Signal { return syscall.SIGINT }

// skipSignal asks the backend to abandon the package in progress and go on to
// the next. SIGUSR1, not SIGINT: SIGINT means stop the run, and the two must
// not be the same thing when one of them is recoverable.
func skipSignal() os.Signal { return syscall.SIGUSR1 }