README.md (848B)
1 # mousetrap 2 3 mousetrap is a tiny library that answers a single question. 4 5 On a Windows machine, was the process invoked by someone double clicking on 6 the executable file while browsing in explorer? 7 8 ### Motivation 9 10 Windows developers unfamiliar with command line tools will often "double-click" 11 the executable for a tool. Because most CLI tools print the help and then exit 12 when invoked without arguments, this is often very frustrating for those users. 13 14 mousetrap provides a way to detect these invocations so that you can provide 15 more helpful behavior and instructions on how to run the CLI tool. To see what 16 this looks like, both from an organizational and a technical perspective, see 17 https://inconshreveable.com/09-09-2014/sweat-the-small-stuff/ 18 19 ### The interface 20 21 The library exposes a single interface: 22 23 func StartedByExplorer() (bool)