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
Now it is just a matter of presenting a patch file that users can consume.
My instinct says: Save the patch file in .cpp-linter-cache/auto-fix.patch. Then set a new output variable fix-patch-path pointing to the saved patch file.
From there users can save it as an artifact or do whatever with it. Using the patch file as an artifact in a different job allows for isolated contents: write permissions (needed by git push after doing git apply $PATCH_FILE).
The idea for this is related to
Here's a flowchart of the changes in #358
flowchart TD; isTidy{Is clang-tidy desired?} runTidy[Run clang-tidy] cacheTidy[Save clang-tidy fixes to cache] isFmt{Is clang-format desired?} runFmtOg[Run clang-format on event src file] hasTidyFixCache{Has clang-tidy cached any fixes?} do3wayDiff[Normalize event changed lines with clang-tidy fixed lines] runFmtTidy[Run clang-format on clang-tidy fixes] cacheFmt[Save clang-format fixes to cache] isTidy --yes--> runTidy --> cacheTidy --> isFmt; isTidy --no --> isFmt --yes--> runFmtOg --> hasTidyFixCache --no --> cacheFmt; hasTidyFixCache --yes--> do3wayDiff --> runFmtTidy;What's next?
Now it is just a matter of presenting a patch file that users can consume.
My instinct says: Save the patch file in
.cpp-linter-cache/auto-fix.patch. Then set a new output variablefix-patch-pathpointing to the saved patch file.From there users can save it as an artifact or do whatever with it. Using the patch file as an artifact in a different job allows for isolated
contents: writepermissions (needed bygit pushafter doinggit apply $PATCH_FILE).