Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  1. Make sure you have the latest version of clang-format and clang-tidy. These can be installed from the install script.
  2. Run make check to see if your code passes the linting/formatting checks. It will tell you what step it fails on.
  3. If it fails the formatting step (which is clang-format), run make format to apply formatting changes. This will move things around to make your code prettier. Go back to step 1 and run make check again.
  4. If it fails the linting step (which is clang-tidy), read the error(s) it's spitting out and try to fix them. These may be more varied since linting is static analysis for bugs, naming checks, and more. Go back to step 1 and run make check again.
  5. Once make check passes, run make leader (or equivalent to build code for the desired target) and ensure that there are no compilation errors. Since make format and make tidy change your code pretty heavily, there is a good chance that they make your code fail compilation. Fix the errors and do steps 1-5 again.