microsoft / vscode-cmake-tools-api

Other
5 stars 3 forks source link

Project -> Target -> Artifact path wrong! #7

Open klausholstjacobsen opened 8 months ago

klausholstjacobsen commented 8 months ago

The artifacts path stored for executable targets seem to have it's "sub path" repeated twice!

let activeProject = await api1?.getProject(workspaceFolder);
let conf activeProject?.codeModel?.configurations[0];
  conf.projects.forEach(project => {
    project.targets.forEach(t => {
        console.log(t.artifacts[0];);
      }
    });
  });

The artifacts printed in the above "pseudo" code is [binary_dir]/[target_subdir]/[target_subdir]/[artifact_name] instead of the expected [binary_dir]/[target_subdir]/[artifact_name]

Regards Klaus

iamsergio commented 6 months ago

For me it's not repeated, but definitely bogus. I get:

"artifacts": [
    "/myproj/build/tests/bin/my_test"
  ]

While the actual executable is in /myproj/build/bin

Maybe related yours after all, it's one [target_subdir] too many.