Gentee Programming Language > Documentation > Launch Download documentation

Using '#!' command

Under Linux, '#!' in the first line is used to start the compiler. Under Windows, you can also use the first line in a file to start any programs, including those used for compiling with the necessary parameters. If you click such a .g file or press Enter, the specified command line will be executed. It allows you to avoid using additional batch files ( .bat ).
For example,

#!gentee.exe -s -l -i hello.g
#!gentee.exe -r -v "%1"

You can specify both absolute and relative paths to the program and the file you want to start. You can specify %1 as the full name of the current file. If the path contains spaces, you should enclose it in double quotation marks.
For example,

#!"C:\My Application\my.bat" "%1"
#!ge2exe.exe -e "%1"

The last example will immediately create and start an EXE file.


 Copyright © 2004-2006 Gentee Inc. All rights reserved.