You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have zap defined in build.zig & build.zig.zon, zig build succeeds.
But when I try to zig-runfrom Emacs it fails with:
main.zig:2:21: error: no package named 'zap' available within package 'root'
I probably know why it happens (sorry I am relatively new to Zig), because zig run does not play well with build.zig. But doesn't this make zig run and zig-run Emacs function useless for larger (and practical) projects?
How do you run your code from within Emacs while making projects with Zig?
The text was updated successfully, but these errors were encountered:
zig-run will not use a build.zig even if one is present. For larger projects, you're right, it's very unlikely to be used, but for small single-file "scratchpads" it can be useful.
#99 is a proposal to add zig build run as a new function. I'll close this issue in favor of that one. If you think this topic deserves a separate issue, we can reopen this again.
Let's say I have
src/main.zig
with following:I have
zap
defined inbuild.zig
&build.zig.zon
,zig build
succeeds.But when I try to
zig-run
from Emacs it fails with:I probably know why it happens (sorry I am relatively new to Zig), because
zig run
does not play well withbuild.zig
. But doesn't this makezig run
andzig-run
Emacs function useless for larger (and practical) projects?How do you run your code from within Emacs while making projects with Zig?
The text was updated successfully, but these errors were encountered: