Skip to content

Commit 1938997

Browse files
committed
docs: fix doc building
This isn't perfect, and it seems that there are still some issues with the new autodoc system. But this does allow the docs to build and render properly again.
1 parent df0c1aa commit 1938997

File tree

2 files changed

+10
-6
lines changed

2 files changed

+10
-6
lines changed

build.zig

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -108,10 +108,14 @@ pub fn build(b: *Build) void {
108108
run_step.dependOn(&run_cmd.step);
109109
}
110110

111-
const docs = b.addTest(.{
111+
const docs = b.addStaticLibrary(.{
112+
.name = "ziglua",
112113
.root_source_file = .{ .path = "src/lib.zig" },
114+
.target = target,
115+
.optimize = optimize,
113116
});
114117
docs.root_module.addOptions("config", config);
118+
docs.root_module.addImport("ziglua", ziglua);
115119

116120
const install_docs = b.addInstallDirectory(.{
117121
.source_dir = docs.getEmittedDocs(),

readme.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,11 @@ Like the Lua C API, the Ziglua API "emphasizes flexibility and simplicity... com
1414

1515
## Documentation
1616
Docs are a work in progress and are automatically generated for each push to main. Most functions and public declarations are documented.
17-
* [Ziglua for Lua 5.1 Docs](https://natecraddock.github.io/ziglua/lua51/)
18-
* [Ziglua for Lua 5.2 Docs](https://natecraddock.github.io/ziglua/lua52/)
19-
* [Ziglua for Lua 5.3 Docs](https://natecraddock.github.io/ziglua/lua53/)
20-
* [Ziglua for Lua 5.4 Docs](https://natecraddock.github.io/ziglua/lua54/)
21-
* [Ziglua for Luau Docs](https://natecraddock.github.io/ziglua/luau/)
17+
* [Ziglua for Lua 5.1 Docs](https://natecraddock.github.io/ziglua/lua51/#ziglua.lib.Lua)
18+
* [Ziglua for Lua 5.2 Docs](https://natecraddock.github.io/ziglua/lua52/#ziglua.lib.Lua)
19+
* [Ziglua for Lua 5.3 Docs](https://natecraddock.github.io/ziglua/lua53/#ziglua.lib.Lua)
20+
* [Ziglua for Lua 5.4 Docs](https://natecraddock.github.io/ziglua/lua54/#ziglua.lib.Lua)
21+
* [Ziglua for Luau Docs](https://natecraddock.github.io/ziglua/luau/#ziglua.lib.Lua)
2222

2323
See [docs.md](https://github.com/natecraddock/ziglua/blob/main/docs.md) for more general information on Ziglua and how it differs from the C API.
2424

0 commit comments

Comments
 (0)