Atelier Style Compliance
ClosedPublic

Authored by rizzitello on May 19 2018, 9:38 PM.

Details

Summary

Enforce Style with script/style.sh
added pre-commit.style for use a git hook
General

  • Spaces After Commas

Includes are alphabetical order global followed by local includes, locals always use "", We don't use <Qt/...> unless needed.

#include <alib>
#include <Zlib>
#include "a.../...h"
#include "mainwindow.h"
#include "z.../...h"

For / If / else and Similar

for (...) {
   ...
}

if (...) {
 ...
} else {
 ...
}

Lambdas use this style

... [this](...) { 
   ...
}
... [this] {
   ...
}

Initializers for methods and longer functions calls such as those to QMessageBox should use this style

QMessageBox::Type (
    this
    , ...
    , ...
    , ...
);

void MainWindow::MainWindow() : 
    QWidget(parent)
    , counter(5)
    , i(65)

Also use Lays' and Patrick's Kde email addresses

Diff Detail

Repository
R231 Atelier
Branch
styleEnforce
Lint
No Linters Available
Unit
No Unit Test Coverage
rizzitello requested review of this revision.May 19 2018, 9:38 PM
rizzitello created this revision.
rizzitello edited the summary of this revision. (Show Details)May 19 2018, 9:48 PM
rizzitello edited the summary of this revision. (Show Details)
  • Use Patricks kde email
rizzitello edited the summary of this revision. (Show Details)May 19 2018, 10:01 PM
laysrodrigues accepted this revision.May 19 2018, 10:35 PM
This revision is now accepted and ready to land.May 19 2018, 10:35 PM
rizzitello edited the summary of this revision. (Show Details)May 19 2018, 11:19 PM
  • Add style script
rizzitello edited the summary of this revision. (Show Details)May 19 2018, 11:56 PM
rizzitello closed this revision.May 19 2018, 11:58 PM