In this example the 0.9.1 version zip file was downloaded from that page.
Code: Select all
zig-windows-x86_64-0.9.1.zip
Code: Select all
c:\zig-0.9.1\
Code: Select all
Directory of C:\zig-0.9.1
06/04/2022 01:23 PM <DIR> .
06/04/2022 01:23 PM <DIR> ..
06/04/2022 01:23 PM <DIR> doc
06/04/2022 01:23 PM <DIR> lib
15/02/2022 12:47 PM 1,091 LICENSE
15/02/2022 12:47 PM 121,928,192 zig.exe
3. Add the following folder location to the PATH environment variable:
Code: Select all
c:\zig-0.9.1\
4. Start the Zeus IDE and check the PATH has been correctly configure by using the Tools, DOS Command Line menu to run the following command:
Code: Select all
zig version
If instead the following output is produced re-check the PATH settings as this output indicates the PATH setting is wrong:0.9.1
5. Using the Options, Document Types menu edit the Zig Document Type and make sure in the Compiler section the following compiler command has been defined:'zig' is not recognized as an internal or external command, operable program or batch file.
Code: Select all
zig build-exe "$fn"
Create a new test.zig file in the c:\temp folder using the following code:
Code: Select all
const std = @import("std");
pub fn main() !void {
const stdout = std.io.getStdOut().writer();
try stdout.print("Zig - Hello, {s}!\n", .{"world"});
}
8. With the test.zig file as the active window, use the Macros, Execute 'test.exe' menu to run the executable file which should result in the following output:
Cheers JussiZig - Hello, world!