ScriptCollection 3.3.60__py3-none-any.whl → 3.3.62__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- ScriptCollection/Executables.py +11 -0
- ScriptCollection/GeneralUtilities.py +12 -0
- ScriptCollection/ScriptCollectionCore.py +20 -1
- ScriptCollection/TasksForCommonProjectStructure.py +103 -32
- {ScriptCollection-3.3.60.dist-info → ScriptCollection-3.3.62.dist-info}/METADATA +1 -1
- ScriptCollection-3.3.62.dist-info/RECORD +14 -0
- {ScriptCollection-3.3.60.dist-info → ScriptCollection-3.3.62.dist-info}/entry_points.txt +1 -0
- ScriptCollection-3.3.60.dist-info/RECORD +0 -14
- {ScriptCollection-3.3.60.dist-info → ScriptCollection-3.3.62.dist-info}/WHEEL +0 -0
- {ScriptCollection-3.3.60.dist-info → ScriptCollection-3.3.62.dist-info}/top_level.txt +0 -0
ScriptCollection/Executables.py
CHANGED
|
@@ -260,6 +260,17 @@ def HealthCheck() -> int:
|
|
|
260
260
|
return ScriptCollectionCore().SCHealthcheck(args.file)
|
|
261
261
|
|
|
262
262
|
|
|
263
|
+
def BuildCodeUnit() -> int:
|
|
264
|
+
parser = argparse.ArgumentParser()
|
|
265
|
+
parser.add_argument('--codeunitfolder', required=False, default=".")
|
|
266
|
+
parser.add_argument('--verbosity', required=False, default=1)
|
|
267
|
+
parser.add_argument('--buildenvironment', required=False, default="QualityCheck")
|
|
268
|
+
parser.add_argument('--additionalargumentsfile', required=False, default=None)
|
|
269
|
+
args = parser.parse_args()
|
|
270
|
+
TasksForCommonProjectStructure().build_codeunit(args.codeunitfolder, int(args.verbosity), args.buildenvironment, args.additionalargumentsfile)
|
|
271
|
+
return 0
|
|
272
|
+
|
|
273
|
+
|
|
263
274
|
def BuildCodeUnits() -> int:
|
|
264
275
|
parser = argparse.ArgumentParser()
|
|
265
276
|
parser.add_argument('--repositoryfolder', required=False, default=".")
|
|
@@ -5,6 +5,7 @@ import hashlib
|
|
|
5
5
|
import re
|
|
6
6
|
import os
|
|
7
7
|
import shutil
|
|
8
|
+
import urllib
|
|
8
9
|
import stat
|
|
9
10
|
import secrets
|
|
10
11
|
import string as strin
|
|
@@ -807,3 +808,14 @@ class GeneralUtilities:
|
|
|
807
808
|
@check_arguments
|
|
808
809
|
def certificate_is_expired(certificate_file: str) -> bool:
|
|
809
810
|
return GeneralUtilities.get_certificate_expiry_date(certificate_file) < datetime.now()
|
|
811
|
+
|
|
812
|
+
@staticmethod
|
|
813
|
+
@check_arguments
|
|
814
|
+
def internet_connection_is_available() -> bool:
|
|
815
|
+
# TODO add more hosts to check to return true if at least one is available
|
|
816
|
+
try:
|
|
817
|
+
with urllib.request.urlopen("https://google.com") as url_result:
|
|
818
|
+
return (url_result.code // 100) == 2
|
|
819
|
+
except:
|
|
820
|
+
pass
|
|
821
|
+
return False
|
|
@@ -27,7 +27,7 @@ from .ProgramRunnerPopen import ProgramRunnerPopen
|
|
|
27
27
|
from .ProgramRunnerEpew import ProgramRunnerEpew, CustomEpewArgument
|
|
28
28
|
|
|
29
29
|
|
|
30
|
-
version = "3.3.
|
|
30
|
+
version = "3.3.62"
|
|
31
31
|
__version__ = version
|
|
32
32
|
|
|
33
33
|
|
|
@@ -197,6 +197,25 @@ class ScriptCollectionCore:
|
|
|
197
197
|
return self.run_program("git", f'log --pretty=%P -n 1 "{commit_id}"',
|
|
198
198
|
repository_folder, throw_exception_if_exitcode_is_not_zero=True)[1].replace("\r", "").replace("\n", "").split(" ")
|
|
199
199
|
|
|
200
|
+
@GeneralUtilities.check_arguments
|
|
201
|
+
def get_all_authors_and_committers_of_repository(self, repository_folder: str, subfolder: str = None, verbosity: int = 1) -> list[tuple[str, str]]:
|
|
202
|
+
space_character = "_"
|
|
203
|
+
if subfolder is None:
|
|
204
|
+
subfolder_argument = ""
|
|
205
|
+
else:
|
|
206
|
+
subfolder_argument = f" -- {subfolder}"
|
|
207
|
+
log_result = self.run_program("git", f'log --pretty=%aN{space_character}%aE%n%cN{space_character}%cE HEAD{subfolder_argument}',
|
|
208
|
+
repository_folder, verbosity=0)
|
|
209
|
+
plain_content: list[str] = list(set([line for line in log_result[1].split("\n") if len(line) > 0]))
|
|
210
|
+
result: list[tuple[str, str]] = []
|
|
211
|
+
for item in plain_content:
|
|
212
|
+
if len(re.findall(space_character, item)) == 1:
|
|
213
|
+
splitted = item.split(space_character)
|
|
214
|
+
result.append((splitted[0], splitted[1]))
|
|
215
|
+
else:
|
|
216
|
+
raise ValueError(f'Unexpected author: "{item}"')
|
|
217
|
+
return result
|
|
218
|
+
|
|
200
219
|
@GeneralUtilities.check_arguments
|
|
201
220
|
def get_commit_ids_between_dates(self, repository_folder: str, since: datetime, until: datetime, ignore_commits_which_are_not_in_history_of_head: bool = True) -> None:
|
|
202
221
|
since_as_string = self.__datetime_to_string_for_git(since)
|
|
@@ -4,6 +4,8 @@ import os
|
|
|
4
4
|
from pathlib import Path
|
|
5
5
|
import shutil
|
|
6
6
|
import re
|
|
7
|
+
import urllib.request
|
|
8
|
+
import zipfile
|
|
7
9
|
import json
|
|
8
10
|
import configparser
|
|
9
11
|
import xmlschema
|
|
@@ -98,6 +100,7 @@ class MergeToStableBranchInformationForProjectInCommonProjectFormat:
|
|
|
98
100
|
class TasksForCommonProjectStructure:
|
|
99
101
|
__sc: ScriptCollectionCore = None
|
|
100
102
|
reference_latest_version_of_xsd_when_generating_xml: bool = True
|
|
103
|
+
validate_developers_of_repository: bool = True
|
|
101
104
|
|
|
102
105
|
@staticmethod
|
|
103
106
|
@GeneralUtilities.check_arguments
|
|
@@ -252,12 +255,16 @@ class TasksForCommonProjectStructure:
|
|
|
252
255
|
self.standardized_tasks_push_wheel_file_to_registry(wheel_file, apikey, repository, gpg_identity, verbosity)
|
|
253
256
|
|
|
254
257
|
@GeneralUtilities.check_arguments
|
|
255
|
-
def
|
|
256
|
-
root: etree._ElementTree = etree.
|
|
258
|
+
def get_version_of_codeunit_file_content(self, codeunit_file_content: str) -> str:
|
|
259
|
+
root: etree._ElementTree = etree.fromstring(codeunit_file_content.encode("utf-8"))
|
|
257
260
|
result = str(root.xpath('//cps:version/text()',
|
|
258
261
|
namespaces={'cps': 'https://projects.aniondev.de/PublicProjects/Common/ProjectTemplates/-/tree/main/Conventions/RepositoryStructure/CommonProjectStructure'})[0])
|
|
259
262
|
return result
|
|
260
263
|
|
|
264
|
+
@GeneralUtilities.check_arguments
|
|
265
|
+
def get_version_of_codeunit(self, codeunit_file: str) -> None:
|
|
266
|
+
return self.get_version_of_codeunit_file_content(GeneralUtilities.read_text_from_file(codeunit_file))
|
|
267
|
+
|
|
261
268
|
@GeneralUtilities.check_arguments
|
|
262
269
|
def get_version_of_codeunit_folder(self, codeunit_folder: str) -> None:
|
|
263
270
|
codeunit_file = os.path.join(codeunit_folder, f"{os.path.basename(codeunit_folder)}.codeunit.xml")
|
|
@@ -353,11 +360,11 @@ class TasksForCommonProjectStructure:
|
|
|
353
360
|
sc = ScriptCollectionCore()
|
|
354
361
|
codeunit_folder: str = str(Path(os.path.dirname(commontasks_script_file_of_current_file)).parent.absolute())
|
|
355
362
|
codeunitname: str = os.path.basename(str(Path(os.path.dirname(commontasks_script_file_of_current_file)).parent.absolute()))
|
|
356
|
-
|
|
357
|
-
for search_result in Path(csproj_folder).glob('**/*.tt'):
|
|
363
|
+
for search_result in Path(codeunitname).glob('**/*.tt'):
|
|
358
364
|
tt_file = str(search_result)
|
|
359
|
-
relative_path_to_tt_file = str(Path(tt_file).relative_to(Path(
|
|
360
|
-
|
|
365
|
+
relative_path_to_tt_file = str(Path(tt_file).relative_to(Path(codeunitname)))
|
|
366
|
+
argument = f"--parameter=codeUnitName={codeunitname} --parameter=codeUnitFolder={codeunit_folder} {relative_path_to_tt_file}"
|
|
367
|
+
sc.run_program("t4", argument, codeunitname, verbosity=verbosity)
|
|
361
368
|
|
|
362
369
|
@GeneralUtilities.check_arguments
|
|
363
370
|
def standardized_tasks_generate_reference_by_docfx(self, generate_reference_script_file: str, verbosity: int, targetenvironmenttype: str, commandline_arguments: list[str]) -> None:
|
|
@@ -557,7 +564,7 @@ class TasksForCommonProjectStructure:
|
|
|
557
564
|
repository_folder: str = str(Path(os.path.dirname(runtestcases_file)).parent.parent.parent.absolute())
|
|
558
565
|
coverage_file_folder = os.path.join(repository_folder, codeunit_name, "Other/Artifacts/TestCoverage")
|
|
559
566
|
working_directory = os.path.join(repository_folder, codeunit_name)
|
|
560
|
-
runsettings_argument=""
|
|
567
|
+
runsettings_argument = ""
|
|
561
568
|
runsettings_file = ".runsettings"
|
|
562
569
|
if os.path.isfile(os.path.join(working_directory, runsettings_file)):
|
|
563
570
|
runsettings_argument = f"--settings {runsettings_file} "
|
|
@@ -968,11 +975,6 @@ class TasksForCommonProjectStructure:
|
|
|
968
975
|
project_version = self.get_version_of_project(repository_folder)
|
|
969
976
|
codeunit_folder = os.path.join(repository_folder, codeunitname)
|
|
970
977
|
|
|
971
|
-
# Clear previously builded artifacts if desired:
|
|
972
|
-
if clear_artifacts_folder:
|
|
973
|
-
artifacts_folder = os.path.join(codeunit_folder, "Other", "Artifacts")
|
|
974
|
-
GeneralUtilities.ensure_directory_does_not_exist(artifacts_folder)
|
|
975
|
-
|
|
976
978
|
# Check codeunit-conformity
|
|
977
979
|
# TODO check if foldername=="<codeunitname>[.codeunit.xml]"==codeunitname in file
|
|
978
980
|
codeunitfile = os.path.join(codeunit_folder, f"{codeunitname}.codeunit.xml")
|
|
@@ -982,15 +984,36 @@ class TasksForCommonProjectStructure:
|
|
|
982
984
|
namespaces = {'cps': 'https://projects.aniondev.de/PublicProjects/Common/ProjectTemplates/-/tree/main/Conventions/RepositoryStructure/CommonProjectStructure',
|
|
983
985
|
'xsi': 'http://www.w3.org/2001/XMLSchema-instance'}
|
|
984
986
|
root: etree._ElementTree = etree.parse(codeunitfile)
|
|
985
|
-
|
|
986
|
-
|
|
987
|
+
|
|
988
|
+
# Check codeunit-spcecification-version
|
|
989
|
+
codeunit_file_version = root.xpath('//cps:codeunit/@codeunitspecificationversion', namespaces=namespaces)[0]
|
|
990
|
+
supported_codeunitspecificationversion = "1.3.0"
|
|
987
991
|
if codeunit_file_version != supported_codeunitspecificationversion:
|
|
988
992
|
raise ValueError(f"ScriptCollection only supports processing codeunits with codeunit-specification-version={supported_codeunitspecificationversion}.")
|
|
989
|
-
schemaLocation = root.xpath('//cps:codeunit/@xsi:schemaLocation',
|
|
993
|
+
schemaLocation = root.xpath('//cps:codeunit/@xsi:schemaLocation', namespaces=namespaces)[0]
|
|
990
994
|
xmlschema.validate(codeunitfile, schemaLocation)
|
|
991
995
|
|
|
996
|
+
# Check developer
|
|
997
|
+
if self.validate_developers_of_repository:
|
|
998
|
+
expected_authors: list[tuple[str, str]] = []
|
|
999
|
+
expected_authors_in_xml = root.xpath('//cps:codeunit/cps:developerteam/cps:developer', namespaces=namespaces)
|
|
1000
|
+
for expected_author in expected_authors_in_xml:
|
|
1001
|
+
author_name = expected_author.xpath('./cps:developername/text()', namespaces=namespaces)[0]
|
|
1002
|
+
author_emailaddress = expected_author.xpath('./cps:developeremailaddress/text()', namespaces=namespaces)[0]
|
|
1003
|
+
expected_authors.append((author_name, author_emailaddress))
|
|
1004
|
+
actual_authors: list[tuple[str, str]] = self.__sc.get_all_authors_and_committers_of_repository(repository_folder, codeunitname, verbosity)
|
|
1005
|
+
for actual_author in actual_authors:
|
|
1006
|
+
if not (actual_author) in expected_authors:
|
|
1007
|
+
actual_author_formatted = f"{actual_author[0]} <{actual_author[1]}>"
|
|
1008
|
+
raise ValueError(f'Author/Comitter "{actual_author_formatted}" is not in the codeunit-developer-team.')
|
|
1009
|
+
|
|
992
1010
|
# TODO implement cycle-check for dependent codeunits
|
|
993
1011
|
|
|
1012
|
+
# Clear previously builded artifacts if desired:
|
|
1013
|
+
if clear_artifacts_folder:
|
|
1014
|
+
artifacts_folder = os.path.join(codeunit_folder, "Other", "Artifacts")
|
|
1015
|
+
GeneralUtilities.ensure_directory_does_not_exist(artifacts_folder)
|
|
1016
|
+
|
|
994
1017
|
# Get artifacts from dependent codeunits
|
|
995
1018
|
if assume_dependent_codeunits_are_already_built:
|
|
996
1019
|
pass # TODO do basic checks to verify dependent codeunits are really there and raise exception if not
|
|
@@ -1243,18 +1266,35 @@ class TasksForCommonProjectStructure:
|
|
|
1243
1266
|
result = list(ts.static_order())
|
|
1244
1267
|
return result
|
|
1245
1268
|
|
|
1269
|
+
@GeneralUtilities.check_arguments
|
|
1270
|
+
def build_codeunit(self, codeunit_folder: str, verbosity: int = 1, target_environmenttype: str = "QualityCheck", additional_arguments_file: str = None,
|
|
1271
|
+
is_pre_merge: bool = False, export_target_directory: str = None) -> None:
|
|
1272
|
+
codeunit_folder = GeneralUtilities.resolve_relative_path_from_current_working_directory(codeunit_folder)
|
|
1273
|
+
codeunit_name = os.path.basename(codeunit_folder)
|
|
1274
|
+
repository_folder = os.path.dirname(codeunit_folder)
|
|
1275
|
+
self.build_specific_codeunits(repository_folder, [codeunit_name], verbosity, target_environmenttype, additional_arguments_file, is_pre_merge, export_target_directory)
|
|
1276
|
+
|
|
1246
1277
|
@GeneralUtilities.check_arguments
|
|
1247
1278
|
def build_codeunits(self, repository_folder: str, verbosity: int = 1, target_environmenttype: str = "QualityCheck", additional_arguments_file: str = None,
|
|
1248
1279
|
is_pre_merge: bool = False, export_target_directory: str = None) -> None:
|
|
1249
|
-
codeunits: dict[str, set[str]] = dict[str, set[str]]()
|
|
1250
1280
|
repository_folder = GeneralUtilities.resolve_relative_path_from_current_working_directory(repository_folder)
|
|
1251
|
-
|
|
1281
|
+
codeunits = self.get_codeunits(repository_folder)
|
|
1282
|
+
self.build_specific_codeunits(repository_folder, codeunits, verbosity, target_environmenttype, additional_arguments_file, is_pre_merge, export_target_directory)
|
|
1283
|
+
|
|
1284
|
+
@GeneralUtilities.check_arguments
|
|
1285
|
+
def build_specific_codeunits(self, repository_folder: str, codeunits: list[str], verbosity: int = 1, target_environmenttype: str = "QualityCheck",
|
|
1286
|
+
additional_arguments_file: str = None, is_pre_merge: bool = False, export_target_directory: str = None) -> None:
|
|
1287
|
+
codeunits_with_dependent_codeunits: dict[str, set[str]] = dict[str, set[str]]()
|
|
1288
|
+
repository_folder = GeneralUtilities.resolve_relative_path_from_current_working_directory(repository_folder)
|
|
1289
|
+
subfolders = [os.path.join(repository_folder, codeunit) for codeunit in codeunits]
|
|
1252
1290
|
for subfolder in subfolders:
|
|
1253
1291
|
codeunit_name: str = os.path.basename(subfolder)
|
|
1254
1292
|
codeunit_file = os.path.join(subfolder, f"{codeunit_name}.codeunit.xml")
|
|
1255
1293
|
if os.path.exists(codeunit_file):
|
|
1256
|
-
|
|
1257
|
-
|
|
1294
|
+
codeunits_with_dependent_codeunits[codeunit_name] = self.get_dependent_code_units(codeunit_file)
|
|
1295
|
+
else:
|
|
1296
|
+
raise ValueError(f"{repository_folder} does not have a codeunit with name {codeunit_name}.")
|
|
1297
|
+
sorted_codeunits = self._internal_sort_codenits(codeunits_with_dependent_codeunits)
|
|
1258
1298
|
project_version = self.get_version_of_project(repository_folder)
|
|
1259
1299
|
if len(sorted_codeunits) == 0:
|
|
1260
1300
|
raise ValueError(f'No codeunit found in subfolders of "{repository_folder}".')
|
|
@@ -1299,6 +1339,37 @@ class TasksForCommonProjectStructure:
|
|
|
1299
1339
|
if not os.path.isfile(changelog_file):
|
|
1300
1340
|
raise ValueError(f"Changelog-file '{changelog_file}' does not exist.")
|
|
1301
1341
|
|
|
1342
|
+
@GeneralUtilities.check_arguments
|
|
1343
|
+
def ensure_grylibrary_is_available(self, codeunit_folder: str):
|
|
1344
|
+
grylibrary_folder = os.path.join(codeunit_folder, "Other", "Resources", "GRYLibrary")
|
|
1345
|
+
grylibrary_dll_file = os.path.join(grylibrary_folder, "BuildResult_DotNet_win-x64", "GRYLibrary.dll")
|
|
1346
|
+
internet_connection_is_available = GeneralUtilities.internet_connection_is_available()
|
|
1347
|
+
grylibrary_dll_file_exists = os.path.isfile(grylibrary_dll_file)
|
|
1348
|
+
if internet_connection_is_available: # Load/Update GRYLibrary
|
|
1349
|
+
grylibrary_latest_codeunit_file = "https://raw.githubusercontent.com/anionDev/GRYLibrary/stable/GRYLibrary/GRYLibrary.codeunit.xml"
|
|
1350
|
+
with urllib.request.urlopen(grylibrary_latest_codeunit_file) as url_result:
|
|
1351
|
+
grylibrary_latest_version = self.get_version_of_codeunit_file_content(url_result.read().decode("utf-8"))
|
|
1352
|
+
if grylibrary_dll_file_exists:
|
|
1353
|
+
grylibrary_existing_codeunit_file = os.path.join(grylibrary_folder, "SourceCode", "GRYLibrary.codeunit.xml")
|
|
1354
|
+
grylibrary_existing_codeunit_version = self.get_version_of_codeunit(grylibrary_existing_codeunit_file)
|
|
1355
|
+
if grylibrary_existing_codeunit_version != grylibrary_latest_version:
|
|
1356
|
+
GeneralUtilities.ensure_directory_does_not_exist(grylibrary_folder)
|
|
1357
|
+
if not os.path.isfile(grylibrary_dll_file):
|
|
1358
|
+
GeneralUtilities.ensure_directory_does_not_exist(grylibrary_folder)
|
|
1359
|
+
GeneralUtilities.ensure_directory_exists(grylibrary_folder)
|
|
1360
|
+
archive_name = f"GRYLibrary.v{grylibrary_latest_version}.Productive.Artifacts.zip"
|
|
1361
|
+
archive_download_link = f"https://github.com/anionDev/GRYLibrary/releases/download/v{grylibrary_latest_version}/{archive_name}"
|
|
1362
|
+
archive_file = os.path.join(grylibrary_folder, archive_name)
|
|
1363
|
+
urllib.request.urlretrieve(archive_download_link, archive_file)
|
|
1364
|
+
with zipfile.ZipFile(archive_file, 'r') as zip_ref:
|
|
1365
|
+
zip_ref.extractall(grylibrary_folder)
|
|
1366
|
+
GeneralUtilities.ensure_file_does_not_exist(archive_file)
|
|
1367
|
+
else:
|
|
1368
|
+
if grylibrary_dll_file_exists:
|
|
1369
|
+
GeneralUtilities.write_message_to_stdout("Warning: Can not check for updates of GRYLibrary due to missing internet-connection.")
|
|
1370
|
+
else:
|
|
1371
|
+
raise ValueError("Can not download GRYLibrary.")
|
|
1372
|
+
|
|
1302
1373
|
@GeneralUtilities.check_arguments
|
|
1303
1374
|
def verify_artifact_exists(self, codeunit_folder: str, artifact_name_regexes: dict[str, bool]) -> None:
|
|
1304
1375
|
codeunit_name: str = os.path.basename(codeunit_folder)
|
|
@@ -1340,7 +1411,7 @@ class TasksForCommonProjectStructure:
|
|
|
1340
1411
|
additional_arguments_r: str = ""
|
|
1341
1412
|
additional_arguments_l: str = ""
|
|
1342
1413
|
additional_arguments_g: str = ""
|
|
1343
|
-
general_argument = f'--overwrite_verbosity={str(verbosity)} --overwrite_targetenvironmenttype={target_environmenttype}'
|
|
1414
|
+
general_argument = f' --overwrite_verbosity={str(verbosity)} --overwrite_targetenvironmenttype={target_environmenttype}'
|
|
1344
1415
|
|
|
1345
1416
|
c_additionalargumentsfile_argument = ""
|
|
1346
1417
|
|
|
@@ -1357,35 +1428,35 @@ class TasksForCommonProjectStructure:
|
|
|
1357
1428
|
config.read(additional_arguments_file)
|
|
1358
1429
|
section_name = f"{codeunit_name}_Configuration"
|
|
1359
1430
|
if config.has_option(section_name, "ArgumentsForCommonTasks"):
|
|
1360
|
-
additional_arguments_c = config.get(section_name, "ArgumentsForCommonTasks")
|
|
1431
|
+
additional_arguments_c = " "+config.get(section_name, "ArgumentsForCommonTasks")
|
|
1361
1432
|
if config.has_option(section_name, "ArgumentsForBuild"):
|
|
1362
|
-
additional_arguments_b = config.get(section_name, "ArgumentsForBuild")
|
|
1433
|
+
additional_arguments_b = " "+config.get(section_name, "ArgumentsForBuild")
|
|
1363
1434
|
if config.has_option(section_name, "ArgumentsForRunTestcases"):
|
|
1364
|
-
additional_arguments_r = config.get(section_name, "ArgumentsForRunTestcases")
|
|
1435
|
+
additional_arguments_r = " "+config.get(section_name, "ArgumentsForRunTestcases")
|
|
1365
1436
|
if config.has_option(section_name, "ArgumentsForLinting"):
|
|
1366
|
-
additional_arguments_l = config.get(section_name, "ArgumentsForLinting")
|
|
1437
|
+
additional_arguments_l = " "+config.get(section_name, "ArgumentsForLinting")
|
|
1367
1438
|
if config.has_option(section_name, "ArgumentsForGenerateReference"):
|
|
1368
|
-
additional_arguments_g = config.get(section_name, "ArgumentsForGenerateReference")
|
|
1369
|
-
c_additionalargumentsfile_argument = f'--overwrite_additionalargumentsfile="{additional_arguments_file}"'
|
|
1439
|
+
additional_arguments_g = " "+config.get(section_name, "ArgumentsForGenerateReference")
|
|
1440
|
+
c_additionalargumentsfile_argument = f' --overwrite_additionalargumentsfile="{additional_arguments_file}"'
|
|
1370
1441
|
|
|
1371
1442
|
GeneralUtilities.write_message_to_stdout('Run "CommonTasks.py"...')
|
|
1372
|
-
self.__sc.run_program("python", f"CommonTasks.py
|
|
1443
|
+
self.__sc.run_program("python", f"CommonTasks.py{additional_arguments_c}{general_argument}{c_additionalargumentsfile_argument}", other_folder, verbosity=verbosity)
|
|
1373
1444
|
self.verify_artifact_exists(codeunit_folder, dict[str, bool]({"Changelog": False, "License": True}))
|
|
1374
1445
|
|
|
1375
1446
|
GeneralUtilities.write_message_to_stdout('Run "Build.py"...')
|
|
1376
|
-
self.__sc.run_program("python", f"Build.py
|
|
1447
|
+
self.__sc.run_program("python", f"Build.py{additional_arguments_b}{general_argument}", build_folder, verbosity=verbosity)
|
|
1377
1448
|
self.verify_artifact_exists(codeunit_folder, dict[str, bool]({"BuildResult_.+": True, "BOM": False, "SourceCode": True}))
|
|
1378
1449
|
|
|
1379
1450
|
GeneralUtilities.write_message_to_stdout('Run "RunTestcases.py"...')
|
|
1380
|
-
self.__sc.run_program("python", f"RunTestcases.py
|
|
1451
|
+
self.__sc.run_program("python", f"RunTestcases.py{additional_arguments_r}{general_argument}", quality_folder, verbosity=verbosity)
|
|
1381
1452
|
self.verify_artifact_exists(codeunit_folder, dict[str, bool]({"TestCoverage": True, "TestCoverageReport": False}))
|
|
1382
1453
|
|
|
1383
1454
|
GeneralUtilities.write_message_to_stdout('Run "Linting.py"...')
|
|
1384
|
-
self.__sc.run_program("python", f"Linting.py
|
|
1455
|
+
self.__sc.run_program("python", f"Linting.py{additional_arguments_l}{general_argument}", quality_folder, verbosity=verbosity)
|
|
1385
1456
|
self.verify_artifact_exists(codeunit_folder, dict[str, bool]())
|
|
1386
1457
|
|
|
1387
1458
|
GeneralUtilities.write_message_to_stdout('Run "GenerateReference.py"...')
|
|
1388
|
-
self.__sc.run_program("python", f"GenerateReference.py
|
|
1459
|
+
self.__sc.run_program("python", f"GenerateReference.py{additional_arguments_g}{general_argument}", reference_folder, verbosity=verbosity)
|
|
1389
1460
|
self.verify_artifact_exists(codeunit_folder, dict[str, bool]({"Reference": True}))
|
|
1390
1461
|
|
|
1391
1462
|
artifactsinformation_file = os.path.join(artifacts_folder, f"{codeunit_name}.artifactsinformation.xml")
|
|
@@ -1411,4 +1482,4 @@ class TasksForCommonProjectStructure:
|
|
|
1411
1482
|
</cps:artifactsinformation>""")
|
|
1412
1483
|
# TODO validate artifactsinformation_file against xsd
|
|
1413
1484
|
self.__check_whether_atifacts_exists(codeunit_folder)
|
|
1414
|
-
GeneralUtilities.write_message_to_stdout(f"Finished building codeunit {codeunit_name}.")
|
|
1485
|
+
GeneralUtilities.write_message_to_stdout(f"Finished building codeunit {codeunit_name} without errors.")
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
ScriptCollection/Executables.py,sha256=kXTIX92KLeFuxnYOlsyFs5lkznsxkuoBMVrV3OU7FZU,18064
|
|
2
|
+
ScriptCollection/GeneralUtilities.py,sha256=Blo0Iq-G4zuUL5oUxBTeGFtQ23ndK7dpZPOjCwVDMnE,33985
|
|
3
|
+
ScriptCollection/ProgramRunnerBase.py,sha256=2kyOuoM3oFjBfLc9Q5t5RTz7Ya2CjUxFtB1rBBDmnjU,1937
|
|
4
|
+
ScriptCollection/ProgramRunnerEpew.py,sha256=ZiBZVMcsphmo49z2BwUwQYXo2uTKXPu33QW3IxCT46E,6273
|
|
5
|
+
ScriptCollection/ProgramRunnerPopen.py,sha256=HOs1QVnXiQtwXy1_xvH79bWBdd0i-2tUyyLloQBvMto,3023
|
|
6
|
+
ScriptCollection/ScriptCollectionCore.py,sha256=xstEiL5332cW8bQPqwj3JdUqTuTrxDGi14JZNnkksdg,81235
|
|
7
|
+
ScriptCollection/TasksForCommonProjectStructure.py,sha256=WQKLcuRaCnbo7qFwog-WUBdmEMEsr30T0jZwgsj3i9Y,105834
|
|
8
|
+
ScriptCollection/UpdateCertificates.py,sha256=Go-JJK-YTi7aBB1phlLxypa8GHkmFHBEPB0_TT9G-bw,7918
|
|
9
|
+
ScriptCollection/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
10
|
+
ScriptCollection-3.3.62.dist-info/METADATA,sha256=YIXMhLIOhE0NrzNiH8pbGnQG16-DE9IHKRXhj9XYTqI,7878
|
|
11
|
+
ScriptCollection-3.3.62.dist-info/WHEEL,sha256=2wepM1nk4DS4eFpYrW1TTqPcoGNfHhhO_i5m4cOimbo,92
|
|
12
|
+
ScriptCollection-3.3.62.dist-info/entry_points.txt,sha256=VIuxVCOpX38lSJUwRRENBNgcGKTIBxQyrCfbJVRHP8g,1968
|
|
13
|
+
ScriptCollection-3.3.62.dist-info/top_level.txt,sha256=hY2hOVH0V0Ce51WB76zKkIWTUNwMUdHo4XDkR2vYVwg,17
|
|
14
|
+
ScriptCollection-3.3.62.dist-info/RECORD,,
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
[console_scripts]
|
|
2
|
+
SCBuildCodeUnit = ScriptCollection.Executables:BuildCodeUnit
|
|
2
3
|
SCBuildCodeUnits = ScriptCollection.Executables:BuildCodeUnits
|
|
3
4
|
SCCalculateBitcoinBlockHash = ScriptCollection.Executables:CalculateBitcoinBlockHash
|
|
4
5
|
SCChangeHashOfProgram = ScriptCollection.Executables:ChangeHashOfProgram
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
ScriptCollection/Executables.py,sha256=o0AGijmphLRv4j7myhG5lhld8yJmxEWeVm3iFNEH8Wk,17485
|
|
2
|
-
ScriptCollection/GeneralUtilities.py,sha256=5mIdXh-4BizfYc-Cwko2A3qHJJughGdez96kutzEJN0,33587
|
|
3
|
-
ScriptCollection/ProgramRunnerBase.py,sha256=2kyOuoM3oFjBfLc9Q5t5RTz7Ya2CjUxFtB1rBBDmnjU,1937
|
|
4
|
-
ScriptCollection/ProgramRunnerEpew.py,sha256=ZiBZVMcsphmo49z2BwUwQYXo2uTKXPu33QW3IxCT46E,6273
|
|
5
|
-
ScriptCollection/ProgramRunnerPopen.py,sha256=HOs1QVnXiQtwXy1_xvH79bWBdd0i-2tUyyLloQBvMto,3023
|
|
6
|
-
ScriptCollection/ScriptCollectionCore.py,sha256=sx0NCqm2KWCdBfQKhZvQ7nc8G-Xylt30vOgPIddGqFk,80193
|
|
7
|
-
ScriptCollection/TasksForCommonProjectStructure.py,sha256=VtLaIobkn5Wi07kaEJ3ftS8FFsu8wZpfkxh-ZsXtGAg,100135
|
|
8
|
-
ScriptCollection/UpdateCertificates.py,sha256=Go-JJK-YTi7aBB1phlLxypa8GHkmFHBEPB0_TT9G-bw,7918
|
|
9
|
-
ScriptCollection/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
10
|
-
ScriptCollection-3.3.60.dist-info/METADATA,sha256=m5k82SI3c7P79mzc0PW4GbsJvGVBA_fdctxWHDbt1TQ,7878
|
|
11
|
-
ScriptCollection-3.3.60.dist-info/WHEEL,sha256=2wepM1nk4DS4eFpYrW1TTqPcoGNfHhhO_i5m4cOimbo,92
|
|
12
|
-
ScriptCollection-3.3.60.dist-info/entry_points.txt,sha256=5nB3ZpbgEe0YNz5GFoXfV9wm4G9wLwOfMERprh5uWhA,1907
|
|
13
|
-
ScriptCollection-3.3.60.dist-info/top_level.txt,sha256=hY2hOVH0V0Ce51WB76zKkIWTUNwMUdHo4XDkR2vYVwg,17
|
|
14
|
-
ScriptCollection-3.3.60.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|