mirror of
https://github.com/GoogleContainerTools/kaniko
synced 2026-10-02 14:13:36 +02:00
* Moving over kbuild executable code and adding unit tests * Moved most file over into this repo * delete non go files from vendor WIP WIP * Removed unnecessary vendor files * Added makefile, travis yaml, boilerplate stuff Added .gitignore Update vendor Fixed linting errors Reorganized pkg Fixed travis * Moved image source into separate package * Removed vendor and logic * Initial skeleton
21 lines
305 B
Go
21 lines
305 B
Go
// +build windows
|
|
|
|
package cobra
|
|
|
|
import (
|
|
"os"
|
|
"time"
|
|
|
|
"github.com/inconshreveable/mousetrap"
|
|
)
|
|
|
|
var preExecHookFn = preExecHook
|
|
|
|
func preExecHook(c *Command) {
|
|
if MousetrapHelpText != "" && mousetrap.StartedByExplorer() {
|
|
c.Print(MousetrapHelpText)
|
|
time.Sleep(5 * time.Second)
|
|
os.Exit(1)
|
|
}
|
|
}
|