Commit d5c6b9fa authored by Mitchell Hashimoto's avatar Mitchell Hashimoto

packer/plugin: Interrupted() to check for i nterrupts

parent 55b0b586
......@@ -177,3 +177,8 @@ func ServeProvisioner(p packer.Provisioner) {
os.Exit(1)
}
}
// Tests whether or not the plugin was interrupted or not.
func Interrupted() bool {
return atomic.LoadInt32(&Interrupts) > 0
}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment