Prior to installing the Gilda compiler, you will need to install Visual Studio. The Community edition of Visual Studio can be downloaded for free.
Gilda programs are built from a command line using the C/C++ compiler tools.
To ensure that C/C++ is properly installed first compile and run a trivial
program from a command line. This page has instruction on how to do this.
It also provides useful information on working within a command shell.
     
Walkthrough: Compiling a Native C++ Program on the Command Line
You can use either the legacy Command Prompt or Power Shell. The Command Prompt evolved from the DOS command shell that predates Windows. Power Shell is more advanced and is primarily used by system administrators. On the Windows Start menu you should see a "Visual Studio 2022" folder. It has a variety of pre-configured shells for developers.
The pre-configured shells set environment variables needed to run the C/C++ compiler (cl.exe) and Linker (link.exe). In order to use a command shell other than the pre-configured shells you will need to set the variables before you can run the C/C++ compiler. If you list the environment variables from a pre-configured shell you can replicate the settings in another command shell.
The components copied into the installation directory are:
basis\ Source code for the Basis library reference\ Web pages for the referance manual guide\ Gilda installation and programming guides gilda.exe Gilda development compiler uninstall.exe Uninstall all compiler components new.gilda.exe Generate a template for a new program pretty.gilda.exe Format Gilda source code gilda_run.lib Run time library for Gilda programs gilda_run.pdb Run time symbols for MS Visual Studio Gilda_Reference.lnk Shortcut to the reference manual
For now the bottom line of each source code file in the library has a copyright notice. Eventually the intent is to create a not for profit organiztion and make Gilda an open source project.
The reference manual is online at:    Gilda Language Reference Manual
You can reset these variables any time. They are case insensitive so you do not need to declare them as shown in upper case.
After running the setup program, the directory you specified to install the compiler needs to be added to the PATH environment variable. This lets you run the compiler from the command shell of your choice.
The setup program lets you designate a directory to install the compiler components. The default location is:
C:\Program Files (x86)\Techneon\
From the (DOS) Command Shell this command adds the Techneon path.
set PATH=%PATH%;C:\Program Files (x86)\Techneon
From the Power Shell this command adds the Techneon path.
$Env:Path += ';C:\Program Files (x86)\Techneon'
You can set the HOME variable to the directory where you want to keep your programming projects. Path names for the compiler use a universal syntax that works with both Windows and Unix file systems. A leading dash in a path is substituted with the HOME path.
For example, if your projects are in a directory, C:\home\source,
you would set HOME to that path.
Then the path, -my_project\project.clg would
refer to the file C:\home\source\my_project\project.clg.
Procedures for processing
Dual Platform path names
are in the Basis Library reference.
You can optionally set this as a default value for the Project argument when you run the Gilda compiler. If your work is focused on a single program then the Project parameter will mostly be the same. Setting this variable lets you avoid having to specify this argument each time you run the compiler.
It also lets you rebuild your program from any directory. To do this set GILDA_PROJECT to the full path of the primary file.
GILDA_PROJECT = -my_project\my_program.clg GILDA_PROJECT = c:\home\me\source\my_project\my_program.clg GILDA_PROJECT = c:\users\me\software\my_project\my_program.clg
You do not need to set this variable unless you are working with multiple copies of the Basis library. If it is not set then the library in the installation directory will be used.
If instead you want to use another copy of the Basis library, set GILDA_LIBRARY to it's location. For example, if you copy the library to C:\home\source\basis\ then GILDA_LIBRARY would get set to that path. When you compile a program with the alternative library the build will compile source files in the library.
Now that you are set up verify the installation by compiling and running the Hello World program. Examples showing how to Build a Program and Build a Library are in the reference manual.
The Gilda Pretty Printer program reformats source code. Since Gilda source code is not case sensitive it can be written in lower case and without indentation. Then you can use the Pretty Printer to adjust the casing and indent code blocks and comments. It's very useful to integrate the Pretty Printer into your development environment so it is convenient to run.
With no command arguments it acts as a filter program that can be embedded in an editor. Then you can run it as you edit source files. If you want to edit code with Vim, here are instructions on how to install Vim and embed the Pretty Printer.
The Pretty Printer program can also be run from the command line or a script. The arguments are an input and a output file. If the input file is an empty string then the standard input is used. If the output file is empty then standard ouput is used.
> pretty.gilda -from my.method.g -to formatted.g > pretty.gilda -from my.method.g > pretty.gilda my.method.g
Here are the arguments for the the pretty.gilda.exe command.
pretty.gilda: Format a Gilda method, class, or map file. -Source <path> Path name of the source file to format. -Target <path> Path name of the target file; default is stdout. -In Read from stdin even if a Source path is given. -Windows Write files in Windows form: Return / New Line -Unix Write files in Posix form: New Line -Mac Write files in Mac form: Return -Vms Write files in Vms form: New Line / Return
Here are details about reporting a bug or providing editorial comments on documentation.