Skip to content

Commit

Permalink
Merge pull request #121 from RA-Consulting-GmbH/misc
Browse files Browse the repository at this point in the history
Misc changes to versioning
  • Loading branch information
ahege authored Oct 20, 2021
2 parents 50657bc + 385e303 commit ba266f5
Show file tree
Hide file tree
Showing 9 changed files with 83 additions and 14 deletions.
4 changes: 2 additions & 2 deletions cpp/applications/expressionsTester/rc/expressionsTester.rc
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ END
//

VS_VERSION_INFO VERSIONINFO
FILEVERSION 1,1,0,0 // e.g. 19,11,39,707
FILEVERSION 1,2,0,0 // e.g. 19,11,39,707
PRODUCTVERSION 1,0,0,0 // e.g. 19,11,39,707
FILEFLAGSMASK 0x3fL
#ifdef _DEBUG
Expand All @@ -77,7 +77,7 @@ BEGIN
BEGIN
VALUE "CompanyName", "RA Consulting GmbH\nZeiloch 6a\n76646 Bruchsal\nGermany" // e.g. RA Consulting GmbH -> companyInfo.txt
VALUE "FileDescription", "" // e.g. Web Service -> productInfo.txt
VALUE "FileVersion", "1.1.0.0" // e.g. 19.11.39.707 -> automatically generated by according CMakeList.txt
VALUE "FileVersion", "1.2.0.0" // e.g. 19.11.39.707 -> automatically generated by according CMakeList.txt
VALUE "InternalName", "ExpressionsTester.exe"
VALUE "LegalCopyright", "Copyright (C) 2021 by RA Consulting GmbH" // e.g. Copyright (C) 2019 -> companyInfo.txt + autogen by CMakeList.txt
VALUE "OriginalFilename", "ExpressionsTester.exe"
Expand Down
4 changes: 2 additions & 2 deletions cpp/applications/indexerTester/rc/IndexerTester.rc
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ END
//

VS_VERSION_INFO VERSIONINFO
FILEVERSION 1,1,0,0 // e.g. 19,11,39,707
FILEVERSION 1,2,0,0 // e.g. 19,11,39,707
PRODUCTVERSION 1,0,0,0 // e.g. 19,11,39,707
FILEFLAGSMASK 0x3fL
#ifdef _DEBUG
Expand All @@ -77,7 +77,7 @@ BEGIN
BEGIN
VALUE "CompanyName", "RA Consulting GmbH\nZeiloch 6a\n76646 Bruchsal\nGermany" // e.g. RA Consulting GmbH -> companyInfo.txt
VALUE "FileDescription", "" // e.g. Web Service -> productInfo.txt
VALUE "FileVersion", "1.1.0.0" // e.g. 19.11.39.707 -> automatically generated by according CMakeList.txt
VALUE "FileVersion", "1.2.0.0" // e.g. 19.11.39.707 -> automatically generated by according CMakeList.txt
VALUE "InternalName", "IndexerTester.exe"
VALUE "LegalCopyright", "Copyright (C) 2021 by RA Consulting GmbH" // e.g. Copyright (C) 2019 -> companyInfo.txt + autogen by CMakeList.txt
VALUE "OriginalFilename", "IndexerTester.exe"
Expand Down
4 changes: 2 additions & 2 deletions cpp/applications/openScenarioReader/rc/OpenScenarioReader.rc
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ END
//

VS_VERSION_INFO VERSIONINFO
FILEVERSION 1,1,0,0 // e.g. 19,11,39,707
FILEVERSION 1,2,0,0 // e.g. 19,11,39,707
PRODUCTVERSION 1,0,0,0 // e.g. 19,11,39,707
FILEFLAGSMASK 0x3fL
#ifdef _DEBUG
Expand All @@ -77,7 +77,7 @@ BEGIN
BEGIN
VALUE "CompanyName", "RA Consulting GmbH\nZeiloch 6a\n76646 Bruchsal\nGermany" // e.g. RA Consulting GmbH -> companyInfo.txt
VALUE "FileDescription", "" // e.g. Web Service -> productInfo.txt
VALUE "FileVersion", "1.1.0.0" // e.g. 19.11.39.707 -> automatically generated by according CMakeList.txt
VALUE "FileVersion", "1.2.0.0" // e.g. 19.11.39.707 -> automatically generated by according CMakeList.txt
VALUE "InternalName", "OpenScenarioReader.exe"
VALUE "LegalCopyright", "Copyright (C) 2021 by RA Consulting GmbH" // e.g. Copyright (C) 2019 -> companyInfo.txt + autogen by CMakeList.txt
VALUE "OriginalFilename", "OpenScenarioReader.exe"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,9 @@ int main(int argc, char** argv)
std::stringstream versionStream;
versionStream << MAJORVERSION << "." << MINORVERSION << "." << PATCHNUMBER;
const std::string kVersion = versionStream.str();
const std::string kHeader = "* ASAM OpenSCENARIO 1.0 Checker (2020) *";
std::stringstream hHeaderStream;
hHeaderStream << "*ASAM OpenSCENARIO " << kVersion << " Checker(2021) *";
const std::string kHeader = hHeaderStream.str();
const std::string kHeaderFillString = GetFilledString(kHeader.length(), '*');

std::cout << kHeaderFillString << std::endl;
Expand Down
4 changes: 2 additions & 2 deletions cpp/applications/openScenarioTester/rc/OpenScenarioTester.rc
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ END
//

VS_VERSION_INFO VERSIONINFO
FILEVERSION 1,1,0,0 // e.g. 19,11,39,707
FILEVERSION 1,2,0,0 // e.g. 19,11,39,707
PRODUCTVERSION 1,0,0,0 // e.g. 19,11,39,707
FILEFLAGSMASK 0x3fL
#ifdef _DEBUG
Expand All @@ -77,7 +77,7 @@ BEGIN
BEGIN
VALUE "CompanyName", "RA Consulting GmbH\nZeiloch 6a\n76646 Bruchsal\nGermany" // e.g. RA Consulting GmbH -> companyInfo.txt
VALUE "FileDescription", "" // e.g. Web Service -> productInfo.txt
VALUE "FileVersion", "1.1.0.0" // e.g. 19.11.39.707 -> automatically generated by according CMakeList.txt
VALUE "FileVersion", "1.2.0.0" // e.g. 19.11.39.707 -> automatically generated by according CMakeList.txt
VALUE "InternalName", "OpenScenarioTester.exe"
VALUE "LegalCopyright", "Copyright (C) 2021 by RA Consulting GmbH" // e.g. Copyright (C) 2019 -> companyInfo.txt + autogen by CMakeList.txt
VALUE "OriginalFilename", "OpenScenarioTester.exe"
Expand Down
4 changes: 2 additions & 2 deletions cpp/expressionsLib/rc/ExpressionsLib.rc
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ END
//

VS_VERSION_INFO VERSIONINFO
FILEVERSION 1,1,0,0 // e.g. 19,11,39,707
FILEVERSION 1,2,0,0 // e.g. 19,11,39,707
PRODUCTVERSION 1,0,0,0 // e.g. 19,11,39,707
FILEFLAGSMASK 0x3fL
#ifdef _DEBUG
Expand All @@ -77,7 +77,7 @@ BEGIN
BEGIN
VALUE "CompanyName", "RA Consulting GmbH\nZeiloch 6a\n76646 Bruchsal\nGermany" // e.g. RA Consulting GmbH -> companyInfo.txt
VALUE "FileDescription", "Library for checking openSCENARIO protocol version 1.0 files." // e.g. Web Service -> productInfo.txt
VALUE "FileVersion", "1.1.0.0" // e.g. 19.11.39.707 -> automatically generated by according CMakeList.txt
VALUE "FileVersion", "1.2.0.0" // e.g. 19.11.39.707 -> automatically generated by according CMakeList.txt
VALUE "InternalName", "ExpressionsLib.dll"
VALUE "LegalCopyright", "Copyright (C) 2021 by RA Consulting GmbH" // e.g. Copyright (C) 2019 -> companyInfo.txt + autogen by CMakeList.txt
VALUE "OriginalFilename", "ExpressionsLib.dll"
Expand Down
4 changes: 2 additions & 2 deletions cpp/openScenarioLib/rc/OpenScenarioLib.rc
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ END
//

VS_VERSION_INFO VERSIONINFO
FILEVERSION 1,1,0,0 // e.g. 19,11,39,707
FILEVERSION 1,2,0,0 // e.g. 19,11,39,707
PRODUCTVERSION 1,0,0,0 // e.g. 19,11,39,707
FILEFLAGSMASK 0x3fL
#ifdef _DEBUG
Expand All @@ -77,7 +77,7 @@ BEGIN
BEGIN
VALUE "CompanyName", "RA Consulting GmbH\nZeiloch 6a\n76646 Bruchsal\nGermany" // e.g. RA Consulting GmbH -> companyInfo.txt
VALUE "FileDescription", "Library for checking openSCENARIO protocol version 1.0 files." // e.g. Web Service -> productInfo.txt
VALUE "FileVersion", "1.1.0.0" // e.g. 19.11.39.707 -> automatically generated by according CMakeList.txt
VALUE "FileVersion", "1.2.0.0" // e.g. 19.11.39.707 -> automatically generated by according CMakeList.txt
VALUE "InternalName", "OpenScenarioLib.dll"
VALUE "LegalCopyright", "Copyright (C) 2021 by RA Consulting GmbH" // e.g. Copyright (C) 2019 -> companyInfo.txt + autogen by CMakeList.txt
VALUE "OriginalFilename", "OpenScenarioLib.dll"
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
package de.rac.generator.main.util

import java.nio.file.FileVisitResult;
import java.nio.file.Files;
import java.nio.file.Path;
import java.nio.file.SimpleFileVisitor;

import java.nio.file.StandardCopyOption
import java.nio.file.attribute.BasicFileAttributes




class CountCodeLines {

static int linesOfCode = 0;
static int linesOfGeneratedCode = 0;
static void main(String[] args)
{
if (args.length != 2) {
println("Usage: CountCodeLines rootCodePath rootGeneratedCodePath");
System.exit(1);
}

List<File> codePaths = [new File(args[0]),new File(args[1])];

codePaths.each { directory ->
try {

println(countLinesFromFileTree(directory));

} catch (IOException e) {
println("Cannot find directory ${directory}");
e.printStackTrace();
System.exit(1);
}
}

}

public static int countLinesFromFileTree(File src) throws IOException {

int lines = 0;
if (src.exists()) {
Files.walkFileTree(src.toPath(), new SimpleFileVisitor<Path>() {
@Override
public FileVisitResult visitFile(Path file,
BasicFileAttributes attrs) throws IOException {

BufferedReader reader = new BufferedReader(new FileReader(file.toString()));

while (reader.readLine() != null) lines++;
reader.close();
return FileVisitResult.CONTINUE;
}

});
}
return lines;
}


}
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,8 @@ class EaUmlLoader {
}

Node mainPackage = getModelNode(root);

println(root)

fillElements(root, idToElement);
// Get The classes Package
Node packageNode = getPackage(root, CLASSES);
Expand All @@ -110,6 +111,9 @@ class EaUmlLoader {

UmlModel umlModel = new UmlModel();




umlModel.primitiveTypes = getPrimitiveTypes(root);
umlModel.interfaces = getInterfaces(root);
umlModel.enumerations = getEnumerations(root);
Expand Down

0 comments on commit ba266f5

Please sign in to comment.