Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"Build workspace" provides no feedback #196

Open
Zylann opened this issue Apr 8, 2024 · 0 comments
Open

"Build workspace" provides no feedback #196

Zylann opened this issue Apr 8, 2024 · 0 comments

Comments

@Zylann
Copy link

Zylann commented Apr 8, 2024

As a new Zig user, I figured I could use the "Build workspace" command to build my project, which seems to work.

The issue is that there is no feedback of what the command is doing. It eventually succeeds and my executable updates, but there is no way to tell what it does, when it finishes, or even if it runs at all (though it does so far). If there are errors, they do show up in the Problems panel and there are squiggles in the code, which is nice. But otherwise, nothing.

I can't see logs in the output panel. I tried switching it to Zig, or Zig Language Server, still nothing. I didn't notice anything in the status bar either, and couldn't see a particular setting. So I kept doing Ctrl+Shift+Build workspace, having to wait a bit, and then run hoping it finished by then. I'm wondering if I'm missing something?


Alternatively, I created a tasks.json, which I think is better since I can decide to create my own build configurations and choose on the fly:

{
    "version": "2.0.0",
    "tasks": [
        {
            "label": "Zig build",
            "type": "shell",
            "command": "D:/Apps/Zig/zig-windows-x86_64-0.11.0/zig.exe",
            "args": [
                "build",
                "-Doptimize=Debug",
                // "-Doptimize=ReleaseFast",
                "--summary",
                "all"
            ],
            "options": {"cwd": "${workspaceRoot}"},
            "presentation": {
                "echo": true,
                "reveal": "always",
                "focus": false,
                "panel": "shared",
                "showReuseMessage": true,
                "clear": false
            },
            "problemMatcher": [],
            "group": {
                "kind": "build",
                "isDefault": true
            }
        }
    ]
}

Using tasks does open the Terminal and prints what's happening, which is great. One problem however, is that if compiling encounters errors, they do not show up in the Problems panel and don't produce squiggles in code. This is quite inconvenient and I wonder how I can make this work? Surely there should be a way, since "Build workspace" somehow had that?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants