Skip to content

Commit aa6341d

Browse files
committed
Astyle: add option to convert to linux EOLs.
1 parent 7502cea commit aa6341d

File tree

3 files changed

+37
-37
lines changed

3 files changed

+37
-37
lines changed

gui/test/main.cpp

+35-35
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,35 @@
1-
/*
2-
* Cppcheck - A tool for static C/C++ code analysis
3-
* Copyright (C) 2007-2011 Daniel Marjamäki and Cppcheck team.
4-
*
5-
* This program is free software: you can redistribute it and/or modify
6-
* it under the terms of the GNU General Public License as published by
7-
* the Free Software Foundation, either version 3 of the License, or
8-
* (at your option) any later version.
9-
*
10-
* This program is distributed in the hope that it will be useful,
11-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
12-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13-
* GNU General Public License for more details.
14-
*
15-
* You should have received a copy of the GNU General Public License
16-
* along with this program. If not, see <http://www.gnu.org/licenses/>.
17-
*/
18-
19-
#include <QCoreApplication>
20-
#include <QtTest>
21-
#include "testtranslationhandler.h"
22-
#include "testxmlreport.h"
23-
24-
int main(int argc, char *argv[])
25-
{
26-
QCoreApplication a(argc, argv);
27-
28-
TestTranslationHandler testTtranslationHandler;
29-
QTest::qExec(&testTtranslationHandler);
30-
31-
TestXmlReport testXmlReport;
32-
QTest::qExec(&testXmlReport);
33-
34-
return a.exec();
35-
}
1+
/*
2+
* Cppcheck - A tool for static C/C++ code analysis
3+
* Copyright (C) 2007-2011 Daniel Marjamäki and Cppcheck team.
4+
*
5+
* This program is free software: you can redistribute it and/or modify
6+
* it under the terms of the GNU General Public License as published by
7+
* the Free Software Foundation, either version 3 of the License, or
8+
* (at your option) any later version.
9+
*
10+
* This program is distributed in the hope that it will be useful,
11+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
12+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13+
* GNU General Public License for more details.
14+
*
15+
* You should have received a copy of the GNU General Public License
16+
* along with this program. If not, see <http://www.gnu.org/licenses/>.
17+
*/
18+
19+
#include <QCoreApplication>
20+
#include <QtTest>
21+
#include "testtranslationhandler.h"
22+
#include "testxmlreport.h"
23+
24+
int main(int argc, char *argv[])
25+
{
26+
QCoreApplication a(argc, argv);
27+
28+
TestTranslationHandler testTtranslationHandler;
29+
QTest::qExec(&testTtranslationHandler);
30+
31+
TestXmlReport testXmlReport;
32+
QTest::qExec(&testXmlReport);
33+
34+
return a.exec();
35+
}

runastyle

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/bin/bash
22

3-
style="--style=ansi --min-conditional-indent=0"
3+
style="--style=ansi --lineend=linux --min-conditional-indent=0"
44
options="--pad-header --unpad-paren --suffix=none"
55

66
astyle $style $options cli/*.cpp

runastyle.bat

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
REM A script to run Astyle for the sources
22

3-
SET STYLE=--style=ansi --min-conditional-indent=0
3+
SET STYLE=--style=ansi --lineend=linux --min-conditional-indent=0
44
SET OPTIONS=--pad-header --unpad-paren --suffix=none
55

66
astyle %STYLE% %OPTIONS% cli/*.cpp

0 commit comments

Comments
 (0)