Currently, UncrustifyCheck._get_git_ignored_paths() is documented to
return a list of absolute file paths but it currently returns a list
of relative file paths.
This change updates the function to return a list of absolute file
paths. The result is later compared to the list of absolute file
paths for files to run against Uncrustify.
Cc: Michael D Kinney <michael.d.kinney@intel.com>
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Cc: Sean Brogan <sean.brogan@microsoft.com>
Cc: Bret Barkelew <Bret.Barkelew@microsoft.com>
Signed-off-by: Michael Kubacki <michael.kubacki@microsoft.com>
Reviewed-by: Michael D Kinney <michael.d.kinney@intel.com>
Reviewed-by: Jiewen Yao <jiewen.yao@intel.com>
f"An error occurred reading git ignore settings. This will prevent Uncrustify from running against the expected set of files.")\r
\r
# Note: This will potentially be a large list, but at least sorted\r
- return outstream_buffer.getvalue().strip().splitlines()\r
+ rel_paths = outstream_buffer.getvalue().strip().splitlines()\r
+ abs_paths = []\r
+ for path in rel_paths:\r
+ abs_paths.append(\r
+ os.path.normpath(os.path.join(self._abs_workspace_path, path)))\r
+ return abs_paths\r
\r
def _get_git_submodule_paths(self) -> List[str]:\r
"""\r