Search code examples
cygwin

Can't use "." to execute files with cygwin


I recently installed Cygwin on Windows 8.1, it works great but I can't execute file using the dot, for example "./hello.ml". I'm using the Windows's command prompt. When I try using it, it show me that "." is not reconized. How can I make it works ? Thanks.


Solution

  • You need to use the cygwin terminal or powershell instead.

    The command interpreter doesn't think that your files are executable because they aren't one of the types that are recognized as binary executables. In general, Windows would use file associations from the registry to make things happen when you try to run a file. The cygwin terminal follows the unix-like convention and knows that your scripts are ml files and they are executable by using the ml interpreter, most likely from a #! at the top of your file.