clang-tidy support followup (actually error travis job with warnings/errors)
Dieses Issue hat noch niemand übernommen.
- Vorherrschende Sprache
- C++
- Sterne
- 74
- Forks
- 9
- PR-Merge-Kennzahlen
- Keine gemergten PRs in 30 T.
Beschreibung
As mentioned at https://github.com/mapbox/node-cpp-skel/pull/64#discussion_r133848127 and https://github.com/mapbox/node-cpp-skel/pull/64#discussion_r133848275 when I set up the make tidy target I was unable to find a way to have clang-tidy return non-zero on warnings/errors.
What this means is that the clang-tidy job on travis will only fail when clang tidy notices problems AND fixes them. Then it will leave behind a git diff and the presence of that diff will trigger the job to fail.
But because clang-tidy cannot auto-fix all problems their is a large class of warnings/errors that do not fail the script and therefore may be present but not failing the travis job.
The todo here is to figure out if the usage of clang-tidy can be fixed (are we doing something wrong, forgetting some flag?) to make clang-tidy return a non-zero error code when it encounters warnings/errors.
/cc @GretaCB who saw this recently with shaver - locally @GretaCB saw a number of pretty important clang-tidy warnings that were silently passing on travis since they were not causing the job to fail.
Beitragsleitfaden
Erste Schritte
- Lies das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreib ins Issue, dass du es übernimmst — das erspart doppelte Arbeit.
- Forke das Repository und arbeite in einem Branch.
- Öffne einen Pull Request, der die Issue-Nummer nennt.
Rechercherichtung
Beginne mit dem make tidy target und dem Travis clang-tidy job und lies anschließend die beiden verlinkten Kommentare in der Pull-Request-Diskussion zum ursprünglichen Setup. Erzeuge eine Warnung, die nicht automatisch behoben wird, und überprüfe den Exit-Status des Befehls sowie den resultierenden git diff. Erledigt bedeutet, dass clang-tidy-Warnungen oder -Fehler den Travis job zuverlässig fehlschlagen lassen, einschließlich Problemen, die nicht automatisch behoben werden können.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Bewertung
- Tech-Stack
- cpp
- Bereich
- build-system, ci-cd, tooling
- Issue-Typ
- Bug
- Schwierigkeit
- 4/5
- Geschätzter Aufwand
- 3-5 Tage
- Aktivitätsstatus
- Veraltet
- Klarheit
- Größtenteils klar
- Anfängerfreundlichkeit
- 35/100