ScriptCollection 3.5.156__py3-none-any.whl → 3.5.158__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 +25 -1
- ScriptCollection/GeneralUtilities.py +28 -11
- ScriptCollection/ScriptCollectionCore.py +45 -7
- ScriptCollection/TasksForCommonProjectStructure.py +39 -17
- {scriptcollection-3.5.156.dist-info → scriptcollection-3.5.158.dist-info}/METADATA +5 -5
- {scriptcollection-3.5.156.dist-info → scriptcollection-3.5.158.dist-info}/RECORD +9 -9
- {scriptcollection-3.5.156.dist-info → scriptcollection-3.5.158.dist-info}/entry_points.txt +1 -0
- {scriptcollection-3.5.156.dist-info → scriptcollection-3.5.158.dist-info}/WHEEL +0 -0
- {scriptcollection-3.5.156.dist-info → scriptcollection-3.5.158.dist-info}/top_level.txt +0 -0
ScriptCollection/Executables.py
CHANGED
@@ -16,7 +16,7 @@ def FilenameObfuscator() -> int:
|
|
16
16
|
parser = argparse.ArgumentParser(description=''''Obfuscates the names of all files in the given folder.
|
17
17
|
Caution: This script can cause harm if you pass a wrong inputfolder-argument.''')
|
18
18
|
|
19
|
-
parser.add_argument('--printtableheadline', type=GeneralUtilities.string_to_boolean, const=True, default=True, nargs='?',
|
19
|
+
parser.add_argument('--printtableheadline', type=GeneralUtilities.string_to_boolean, const=True, default=True, nargs='?', help='Prints column-titles in the name-mapping-csv-file')
|
20
20
|
parser.add_argument('--namemappingfile', default="NameMapping.csv", help='Specifies the file where the name-mapping will be written to')
|
21
21
|
parser.add_argument('--extensions', default="exe,py,sh",
|
22
22
|
help='Comma-separated list of file-extensions of files where this tool should be applied. Use "*" to obfuscate all')
|
@@ -760,3 +760,27 @@ def UpdateTimestampInFile() -> int:
|
|
760
760
|
sc = ScriptCollectionCore()
|
761
761
|
sc.update_timestamp_in_file(args.file)
|
762
762
|
return 0
|
763
|
+
|
764
|
+
|
765
|
+
def LOC() -> int:
|
766
|
+
sc = ScriptCollectionCore()
|
767
|
+
default_patterns: list[str] = sc.default_excluded_patterns_for_loc
|
768
|
+
default_patterns_joined = ",".join(default_patterns)
|
769
|
+
parser = argparse.ArgumentParser(description=f"Counts the lines of code in a git-repository. Default patterns are: {default_patterns_joined}")
|
770
|
+
parser.add_argument('-r', '--repository', required=True)
|
771
|
+
parser.add_argument('-e', '--excluded_pattern', nargs='+')
|
772
|
+
parser.add_argument('-d', '--do_not_add_default_pattern', action='store_true', default=False)
|
773
|
+
parser.add_argument('-v', '--verbose', action='store_true', default=False)
|
774
|
+
args = parser.parse_args()
|
775
|
+
folder: str = None
|
776
|
+
if os.path.isabs(args.repository):
|
777
|
+
folder = args.repository
|
778
|
+
else:
|
779
|
+
folder = GeneralUtilities.resolve_relative_path(args.repository, os.getcwd())
|
780
|
+
excluded_patterns: list[str] = []
|
781
|
+
if not args.do_not_add_default_pattern:
|
782
|
+
excluded_patterns = excluded_patterns + sc.default_excluded_patterns_for_loc
|
783
|
+
if args.excluded_pattern is not None:
|
784
|
+
excluded_patterns = excluded_patterns + args.excluded_pattern
|
785
|
+
GeneralUtilities.write_message_to_stdout(str(sc.get_lines_of_code(folder, excluded_patterns, args.verbose)))
|
786
|
+
return 0
|
@@ -16,7 +16,7 @@ from enum import Enum
|
|
16
16
|
import traceback
|
17
17
|
import warnings
|
18
18
|
import functools
|
19
|
-
from datetime import datetime, timedelta, date
|
19
|
+
from datetime import datetime, timedelta, date, timezone
|
20
20
|
from os import listdir
|
21
21
|
from os.path import isfile, join, isdir
|
22
22
|
from pathlib import Path
|
@@ -368,6 +368,8 @@ class GeneralUtilities:
|
|
368
368
|
@staticmethod
|
369
369
|
@check_arguments
|
370
370
|
def datetime_to_string_for_logfile_entry(datetime_object: datetime, add_milliseconds: bool = False) -> str:
|
371
|
+
if datetime_object.tzinfo is None:
|
372
|
+
datetime_object=datetime_object.replace(tzinfo=timezone.utc)#assume utc when no timezone is given
|
371
373
|
pattern: str = None
|
372
374
|
if add_milliseconds:
|
373
375
|
pattern = "%Y-%m-%dT%H:%M:%S.%f%z"
|
@@ -607,7 +609,7 @@ class GeneralUtilities:
|
|
607
609
|
@check_arguments
|
608
610
|
def write_lines_to_file(file: str, lines: list, encoding="utf-8") -> None:
|
609
611
|
lines = [GeneralUtilities.strip_new_line_character(line) for line in lines]
|
610
|
-
content =
|
612
|
+
content = "\n".join(lines)
|
611
613
|
GeneralUtilities.write_text_to_file(file, content, encoding)
|
612
614
|
|
613
615
|
@staticmethod
|
@@ -621,10 +623,23 @@ class GeneralUtilities:
|
|
621
623
|
with open(file, "wb") as file_object:
|
622
624
|
file_object.write(content)
|
623
625
|
|
626
|
+
@staticmethod
|
627
|
+
def is_binary_file(path: str):
|
628
|
+
content = GeneralUtilities.read_binary_from_file(path)
|
629
|
+
binary_content_indicators = [b'\x00', b'\x01', b'\x02', b'\x03', b'\x04', b'\x05', b'\x06', b'\x07', b'\x08', b'\x0E', b'\x1F']
|
630
|
+
for binary_content_indicator in binary_content_indicators:
|
631
|
+
if binary_content_indicator in content:
|
632
|
+
return True
|
633
|
+
return False
|
634
|
+
|
624
635
|
@staticmethod
|
625
636
|
@check_arguments
|
626
637
|
def read_lines_from_file(file: str, encoding="utf-8") -> list[str]:
|
627
|
-
|
638
|
+
content=GeneralUtilities.read_text_from_file(file, encoding)
|
639
|
+
if len(content)==0:
|
640
|
+
return []
|
641
|
+
else:
|
642
|
+
return [GeneralUtilities.strip_new_line_character(line) for line in content.split('\n')]
|
628
643
|
|
629
644
|
@staticmethod
|
630
645
|
@check_arguments
|
@@ -843,16 +858,18 @@ class GeneralUtilities:
|
|
843
858
|
|
844
859
|
@staticmethod
|
845
860
|
@check_arguments
|
846
|
-
def get_time_based_logfile_by_folder(folder: str, name: str = "Log"
|
847
|
-
return os.path.join(GeneralUtilities.resolve_relative_path_from_current_working_directory(folder), f"{GeneralUtilities.get_time_based_logfilename(name
|
861
|
+
def get_time_based_logfile_by_folder(folder: str, name: str = "Log") -> str:
|
862
|
+
return os.path.join(GeneralUtilities.resolve_relative_path_from_current_working_directory(folder), f"{GeneralUtilities.get_time_based_logfilename(name)}.log")
|
848
863
|
|
849
864
|
@staticmethod
|
850
865
|
@check_arguments
|
851
|
-
def
|
852
|
-
|
853
|
-
|
854
|
-
|
855
|
-
|
866
|
+
def get_now() -> datetime:
|
867
|
+
return datetime.now().astimezone()
|
868
|
+
|
869
|
+
@staticmethod
|
870
|
+
@check_arguments
|
871
|
+
def get_time_based_logfilename(name: str = "Log") -> str:
|
872
|
+
d=GeneralUtilities.get_now()
|
856
873
|
return f"{name}_{GeneralUtilities.datetime_to_string_for_logfile_name(d)}"
|
857
874
|
|
858
875
|
@staticmethod
|
@@ -1023,7 +1040,7 @@ class GeneralUtilities:
|
|
1023
1040
|
@staticmethod
|
1024
1041
|
@check_arguments
|
1025
1042
|
def certificate_is_expired(certificate_file: str) -> bool:
|
1026
|
-
return GeneralUtilities.get_certificate_expiry_date(certificate_file) <
|
1043
|
+
return GeneralUtilities.get_certificate_expiry_date(certificate_file) <GeneralUtilities.get_now()
|
1027
1044
|
|
1028
1045
|
@staticmethod
|
1029
1046
|
@check_arguments
|
@@ -19,6 +19,7 @@ from subprocess import Popen
|
|
19
19
|
import re
|
20
20
|
import shutil
|
21
21
|
from typing import IO
|
22
|
+
import fnmatch
|
22
23
|
import uuid
|
23
24
|
import tempfile
|
24
25
|
import io
|
@@ -35,7 +36,7 @@ from .ProgramRunnerPopen import ProgramRunnerPopen
|
|
35
36
|
from .ProgramRunnerEpew import ProgramRunnerEpew, CustomEpewArgument
|
36
37
|
from .SCLog import SCLog, LogLevel
|
37
38
|
|
38
|
-
version = "3.5.
|
39
|
+
version = "3.5.158"
|
39
40
|
__version__ = version
|
40
41
|
|
41
42
|
|
@@ -1861,7 +1862,7 @@ class ScriptCollectionCore:
|
|
1861
1862
|
|
1862
1863
|
@GeneralUtilities.check_arguments
|
1863
1864
|
def system_time_equals_internet_time(self, maximal_tolerance_difference: timedelta) -> bool:
|
1864
|
-
return abs(
|
1865
|
+
return abs(GeneralUtilities.get_now() - self.get_internet_time()) < maximal_tolerance_difference
|
1865
1866
|
|
1866
1867
|
@GeneralUtilities.check_arguments
|
1867
1868
|
def system_time_equals_internet_time_with_default_tolerance(self) -> bool:
|
@@ -2122,7 +2123,7 @@ chmod {permission} {link_file}
|
|
2122
2123
|
|
2123
2124
|
@GeneralUtilities.check_arguments
|
2124
2125
|
def update_year_in_copyright_tags(self, file: str) -> None:
|
2125
|
-
current_year = str(
|
2126
|
+
current_year = str(GeneralUtilities.get_now().year)
|
2126
2127
|
lines = GeneralUtilities.read_lines_from_file(file)
|
2127
2128
|
lines_result = []
|
2128
2129
|
for line in lines:
|
@@ -2137,7 +2138,7 @@ chmod {permission} {link_file}
|
|
2137
2138
|
|
2138
2139
|
@GeneralUtilities.check_arguments
|
2139
2140
|
def update_year_in_first_line_of_file(self, file: str) -> None:
|
2140
|
-
current_year = str(
|
2141
|
+
current_year = str(GeneralUtilities.get_now().year)
|
2141
2142
|
lines = GeneralUtilities.read_lines_from_file(file)
|
2142
2143
|
lines[0] = re.sub("\\d\\d\\d\\d", current_year, lines[0])
|
2143
2144
|
GeneralUtilities.write_lines_to_file(file, lines)
|
@@ -2357,8 +2358,8 @@ TXDX
|
|
2357
2358
|
|
2358
2359
|
@GeneralUtilities.check_arguments
|
2359
2360
|
def install_requirementstxt_file(self, requirements_txt_file: str, verbosity: int):
|
2360
|
-
folder:str=os.path.dirname(requirements_txt_file)
|
2361
|
-
filename:str=os.path.basename(requirements_txt_file)
|
2361
|
+
folder: str = os.path.dirname(requirements_txt_file)
|
2362
|
+
filename: str = os.path.basename(requirements_txt_file)
|
2362
2363
|
self.run_program_argsasarray("pip", ["install", "-r", filename], folder, verbosity=verbosity)
|
2363
2364
|
|
2364
2365
|
@GeneralUtilities.check_arguments
|
@@ -2447,7 +2448,7 @@ OCR-content:
|
|
2447
2448
|
prefix: str = "# last update: "
|
2448
2449
|
for line in lines:
|
2449
2450
|
if line.startswith(prefix):
|
2450
|
-
new_lines.append(prefix+GeneralUtilities.datetime_to_string_with_timezone(
|
2451
|
+
new_lines.append(prefix+GeneralUtilities.datetime_to_string_with_timezone(GeneralUtilities.get_now()))
|
2451
2452
|
else:
|
2452
2453
|
new_lines.append(line)
|
2453
2454
|
GeneralUtilities.write_lines_to_file(target_file, new_lines)
|
@@ -2464,3 +2465,40 @@ OCR-content:
|
|
2464
2465
|
return 1
|
2465
2466
|
finally:
|
2466
2467
|
self.log.log(f"Finished action \"{name_of_task}\".", LogLevel.Information)
|
2468
|
+
|
2469
|
+
def get_lines_of_code_with_default_excluded_patterns(self, repository: str) -> int:
|
2470
|
+
return self.get_lines_of_code(repository, self.default_excluded_patterns_for_loc, False)
|
2471
|
+
|
2472
|
+
default_excluded_patterns_for_loc: list[str] = [".txt", ".md",".vscode", "Resources", "Reference", ".gitignore", ".gitattributes", "Other/Metrics"]
|
2473
|
+
|
2474
|
+
def get_lines_of_code(self, repository: str, excluded_pattern: list[str], verbose: bool) -> int:
|
2475
|
+
self.assert_is_git_repository(repository)
|
2476
|
+
result: int = 0
|
2477
|
+
if verbose:
|
2478
|
+
GeneralUtilities.write_message_to_stdout(f"Calculate lines of code in repository '{repository}' with excluded patterns: {', '.join(excluded_pattern)}")
|
2479
|
+
git_response = self.run_program("git", "ls-files", repository)
|
2480
|
+
files: list[str] = GeneralUtilities.string_to_lines(git_response[1])
|
2481
|
+
very_verbose: bool = False
|
2482
|
+
if very_verbose:
|
2483
|
+
verbose = True
|
2484
|
+
for file in files:
|
2485
|
+
if self.__is_excluded_by_glob_pattern(file, excluded_pattern):
|
2486
|
+
if very_verbose:
|
2487
|
+
GeneralUtilities.write_message_to_stdout(f"File '{file}' is ignored because it matches an excluded pattern.")
|
2488
|
+
else:
|
2489
|
+
full_file: str = os.path.join(repository, file)
|
2490
|
+
if GeneralUtilities.is_binary_file(full_file):
|
2491
|
+
if very_verbose:
|
2492
|
+
GeneralUtilities.write_message_to_stdout(f"File '{file}' is ignored because it is a binary-file.")
|
2493
|
+
else:
|
2494
|
+
if verbose:
|
2495
|
+
GeneralUtilities.write_message_to_stdout(f"Count lines of file '{file}'.")
|
2496
|
+
length = len(GeneralUtilities.read_nonempty_lines_from_file(full_file))
|
2497
|
+
result = result+length
|
2498
|
+
return result
|
2499
|
+
|
2500
|
+
def __is_excluded_by_glob_pattern(self, file: str, excluded_patterns: list[str]) -> bool:
|
2501
|
+
for pattern in excluded_patterns:
|
2502
|
+
if fnmatch.fnmatch(file, f"*{pattern}*"):
|
2503
|
+
return True
|
2504
|
+
return False
|
@@ -1,4 +1,4 @@
|
|
1
|
-
from datetime import datetime, timedelta
|
1
|
+
from datetime import datetime, timedelta, timezone
|
2
2
|
from graphlib import TopologicalSorter
|
3
3
|
import os
|
4
4
|
from pathlib import Path
|
@@ -1175,7 +1175,7 @@ class TasksForCommonProjectStructure:
|
|
1175
1175
|
@GeneralUtilities.check_arguments
|
1176
1176
|
def ensure_certificate_authority_for_development_purposes_is_generated(self, product_folder: str):
|
1177
1177
|
product_name: str = os.path.basename(product_folder)
|
1178
|
-
now =
|
1178
|
+
now = GeneralUtilities.get_now()
|
1179
1179
|
ca_name = f"{product_name}CA_{now.year:04}{now.month:02}{now.day:02}{now.hour:02}{now.min:02}{now.second:02}"
|
1180
1180
|
ca_folder = os.path.join(product_folder, "Other", "Resources", "CA")
|
1181
1181
|
generate_certificate = True
|
@@ -1675,31 +1675,37 @@ class TasksForCommonProjectStructure:
|
|
1675
1675
|
return False
|
1676
1676
|
|
1677
1677
|
@GeneralUtilities.check_arguments
|
1678
|
-
def get_versions(self, repository_folder: str) -> list[
|
1678
|
+
def get_versions(self, repository_folder: str) -> list[tuple[str, datetime, datetime]]:
|
1679
1679
|
self.__sc.assert_is_git_repository(repository_folder)
|
1680
1680
|
folder = os.path.join(repository_folder, "Other", "Resources", "Support")
|
1681
1681
|
file = os.path.join(folder, "InformationAboutSupportedVersions.csv")
|
1682
|
-
result: list[str] = list[(str, datetime, datetime)]()
|
1682
|
+
result: list[(str, datetime, datetime)] = list[(str, datetime, datetime)]()
|
1683
1683
|
if not os.path.isfile(file):
|
1684
1684
|
return result
|
1685
1685
|
entries = GeneralUtilities.read_csv_file(file, True)
|
1686
1686
|
for entry in entries:
|
1687
|
-
|
1687
|
+
d1 = GeneralUtilities.string_to_datetime(entry[1])
|
1688
|
+
if d1.tzinfo is None:
|
1689
|
+
d1 = d1.replace(tzinfo=timezone.utc)
|
1690
|
+
d2 = GeneralUtilities.string_to_datetime(entry[2])
|
1691
|
+
if d2.tzinfo is None:
|
1692
|
+
d2 = d2.replace(tzinfo=timezone.utc)
|
1693
|
+
result.append((entry[0], d1, d2))
|
1688
1694
|
return result
|
1689
1695
|
|
1690
1696
|
@GeneralUtilities.check_arguments
|
1691
|
-
def get_supported_versions(self, repository_folder: str, moment: datetime) -> list[
|
1697
|
+
def get_supported_versions(self, repository_folder: str, moment: datetime) -> list[tuple[str, datetime, datetime]]:
|
1692
1698
|
self.__sc.assert_is_git_repository(repository_folder)
|
1693
|
-
result: list[str] = list[
|
1699
|
+
result: list[tuple[str, datetime, datetime]] = list[tuple[str, datetime, datetime]]()
|
1694
1700
|
for entry in self.get_versions(repository_folder):
|
1695
1701
|
if entry[1] <= moment and moment <= entry[2]:
|
1696
1702
|
result.append(entry)
|
1697
1703
|
return result
|
1698
1704
|
|
1699
1705
|
@GeneralUtilities.check_arguments
|
1700
|
-
def get_unsupported_versions(self, repository_folder: str, moment: datetime) -> list[
|
1706
|
+
def get_unsupported_versions(self, repository_folder: str, moment: datetime) -> list[tuple[str, datetime, datetime]]:
|
1701
1707
|
self.__sc.assert_is_git_repository(repository_folder)
|
1702
|
-
result: list[str] = list[
|
1708
|
+
result: list[tuple[str, datetime, datetime]] = list[tuple[str, datetime, datetime]]()
|
1703
1709
|
for entry in self.get_versions(repository_folder):
|
1704
1710
|
if not (entry[1] <= moment and moment <= entry[2]):
|
1705
1711
|
result.append(entry)
|
@@ -2628,7 +2634,7 @@ class TasksForCommonProjectStructure:
|
|
2628
2634
|
codeunits = self.get_codeunits(repository_folder, False)
|
2629
2635
|
project_version = self.get_version_of_project(repository_folder)
|
2630
2636
|
|
2631
|
-
now =
|
2637
|
+
now = GeneralUtilities.get_now()
|
2632
2638
|
|
2633
2639
|
project_resources_folder = os.path.join(repository_folder, "Other", "Scripts")
|
2634
2640
|
PrepareBuildCodeunits_script_name = "PrepareBuildCodeunits.py"
|
@@ -2650,13 +2656,29 @@ class TasksForCommonProjectStructure:
|
|
2650
2656
|
from_day = datetime(now.year, now.month, now.day, 0, 0, 0)
|
2651
2657
|
self.mark_current_version_as_supported(repository_folder, project_version, from_day, until_day)
|
2652
2658
|
self.build_specific_codeunits(repository_folder, codeunits, verbosity, target_environmenttype, additional_arguments_file, is_pre_merge, export_target_directory, False, commandline_arguments, do_git_clean_when_no_changes, note)
|
2659
|
+
self.__save_lines_of_code(repository_folder, project_version)
|
2660
|
+
|
2661
|
+
@GeneralUtilities.check_arguments
|
2662
|
+
def __save_lines_of_code(self, repository_folder: str, project_version: str) -> None:
|
2663
|
+
loc = self.__sc.get_lines_of_code_with_default_excluded_patterns(repository_folder)
|
2664
|
+
loc_metric_folder = os.path.join(repository_folder, "Other", "Metrics")
|
2665
|
+
GeneralUtilities.ensure_directory_exists(loc_metric_folder)
|
2666
|
+
loc_metric_file = os.path.join(loc_metric_folder, "LinesOfCode.csv")
|
2667
|
+
GeneralUtilities.ensure_file_exists(loc_metric_file)
|
2668
|
+
old_lines = GeneralUtilities.read_lines_from_file(loc_metric_file)
|
2669
|
+
new_lines = []
|
2670
|
+
for line in old_lines:
|
2671
|
+
if not line.startswith(f"v{project_version};"):
|
2672
|
+
new_lines.append(line)
|
2673
|
+
new_lines.append(f"v{project_version};{loc}")
|
2674
|
+
GeneralUtilities.write_lines_to_file(loc_metric_file, new_lines)
|
2653
2675
|
|
2654
2676
|
@GeneralUtilities.check_arguments
|
2655
2677
|
def build_specific_codeunits(self, repository_folder: str, codeunits: list[str], verbosity: int = 1, target_environmenttype: str = "QualityCheck", additional_arguments_file: str = None, is_pre_merge: bool = False, export_target_directory: str = None, assume_dependent_codeunits_are_already_built: bool = True, commandline_arguments: list[str] = [], do_git_clean_when_no_changes: bool = False, note: str = None, check_for_new_files: bool = True) -> None:
|
2656
|
-
now_begin: datetime =
|
2657
|
-
codeunits_list = "{"+", ".join(
|
2678
|
+
now_begin: datetime = GeneralUtilities.get_now()
|
2679
|
+
codeunits_list = "{"+", ".join(codeunits)+"}"
|
2658
2680
|
if verbosity > 2:
|
2659
|
-
GeneralUtilities.write_message_to_stdout(f"Start building codeunits
|
2681
|
+
GeneralUtilities.write_message_to_stdout(f"Start building codeunits {codeunits_list} in repository '{repository_folder}'...")
|
2660
2682
|
self.__sc.assert_is_git_repository(repository_folder)
|
2661
2683
|
self.__check_target_environmenttype(target_environmenttype)
|
2662
2684
|
repository_folder = GeneralUtilities.resolve_relative_path_from_current_working_directory(repository_folder)
|
@@ -2719,7 +2741,7 @@ class TasksForCommonProjectStructure:
|
|
2719
2741
|
archive_file = os.path.join(os.getcwd(), f"{filename_without_extension}.zip")
|
2720
2742
|
shutil.move(archive_file, target_folder)
|
2721
2743
|
|
2722
|
-
now_end: datetime =
|
2744
|
+
now_end: datetime = GeneralUtilities.get_now()
|
2723
2745
|
message2 = f"Finished build codeunits in product {repository_name}. (Finished: {GeneralUtilities.datetime_to_string_for_logfile_entry(now_end)})"
|
2724
2746
|
if note is not None:
|
2725
2747
|
message2 = f"{message2} ({note})"
|
@@ -3097,7 +3119,7 @@ class TasksForCommonProjectStructure:
|
|
3097
3119
|
@GeneralUtilities.check_arguments
|
3098
3120
|
def __build_codeunit(self, codeunit_folder: str, verbosity: int = 1, target_environmenttype: str = "QualityCheck", additional_arguments_file: str = None, is_pre_merge: bool = False, assume_dependent_codeunits_are_already_built: bool = False, commandline_arguments: list[str] = []) -> None:
|
3099
3121
|
self.assert_is_codeunit_folder(codeunit_folder)
|
3100
|
-
now =
|
3122
|
+
now = GeneralUtilities.get_now()
|
3101
3123
|
codeunit_folder = GeneralUtilities.resolve_relative_path_from_current_working_directory(codeunit_folder)
|
3102
3124
|
repository_folder = GeneralUtilities.resolve_relative_path("..", codeunit_folder)
|
3103
3125
|
codeunit_name: str = os.path.basename(codeunit_folder)
|
@@ -3314,9 +3336,9 @@ class TasksForCommonProjectStructure:
|
|
3314
3336
|
GeneralUtilities.write_message_to_stdout("Debug: Dependency-update skipped.")
|
3315
3337
|
|
3316
3338
|
GeneralUtilities.write_message_to_stdout(f"Check reference-repository...")
|
3317
|
-
now =
|
3339
|
+
now = GeneralUtilities.get_now()
|
3318
3340
|
for unsupported_version in self.get_unsupported_versions(repository_folder, now):
|
3319
|
-
reference_folder = f"{reference_folder}/ReferenceContent/v{unsupported_version}"
|
3341
|
+
reference_folder = f"{reference_folder}/ReferenceContent/v{unsupported_version[0]}"
|
3320
3342
|
GeneralUtilities.ensure_directory_does_not_exist(reference_folder)
|
3321
3343
|
self.__sc.git_commit(reference_folder, "Removed reference of outdated versions.")
|
3322
3344
|
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.4
|
2
2
|
Name: ScriptCollection
|
3
|
-
Version: 3.5.
|
3
|
+
Version: 3.5.158
|
4
4
|
Summary: The ScriptCollection is the place for reusable scripts.
|
5
5
|
Home-page: https://github.com/anionDev/ScriptCollection
|
6
6
|
Author: Marius Göcke
|
@@ -23,8 +23,8 @@ Classifier: Topic :: Utilities
|
|
23
23
|
Requires-Python: >=3.10
|
24
24
|
Description-Content-Type: text/markdown
|
25
25
|
Requires-Dist: build>=1.3.0
|
26
|
-
Requires-Dist: coverage>=7.10.
|
27
|
-
Requires-Dist: cyclonedx-bom>=7.
|
26
|
+
Requires-Dist: coverage>=7.10.6
|
27
|
+
Requires-Dist: cyclonedx-bom>=7.1.0
|
28
28
|
Requires-Dist: defusedxml>=0.7.1
|
29
29
|
Requires-Dist: keyboard>=0.13.5
|
30
30
|
Requires-Dist: lcov-cobertura>=2.1.1
|
@@ -37,11 +37,11 @@ Requires-Dist: Pygments>=2.19.2
|
|
37
37
|
Requires-Dist: pylint>=3.3.8
|
38
38
|
Requires-Dist: pyOpenSSL>=25.1.0
|
39
39
|
Requires-Dist: PyPDF>=6.0.0
|
40
|
-
Requires-Dist: pytest>=8.4.
|
40
|
+
Requires-Dist: pytest>=8.4.2
|
41
41
|
Requires-Dist: PyYAML>=6.0.2
|
42
42
|
Requires-Dist: qrcode>=8.2
|
43
43
|
Requires-Dist: send2trash>=1.8.3
|
44
|
-
Requires-Dist: twine>=6.
|
44
|
+
Requires-Dist: twine>=6.2.0
|
45
45
|
Requires-Dist: xmlschema>=4.1.0
|
46
46
|
|
47
47
|
# ScriptCollection
|
@@ -1,17 +1,17 @@
|
|
1
1
|
ScriptCollection/CertificateUpdater.py,sha256=OAxrG21k_o3W3niOOGNSZzUPJlvolOWc1lRB2dMhc3g,9212
|
2
|
-
ScriptCollection/Executables.py,sha256=
|
3
|
-
ScriptCollection/GeneralUtilities.py,sha256=
|
2
|
+
ScriptCollection/Executables.py,sha256=xWXG2lKx82y697vFDC3EsG1K3FqyX1Fo0bnfLSXIY1A,38282
|
3
|
+
ScriptCollection/GeneralUtilities.py,sha256=3pjPt7jPK73MgdQ9CAANDrEWn2WI6vpjLkkvZI8JKww,48752
|
4
4
|
ScriptCollection/ImageUpdater.py,sha256=qTe3yoqzQJY7LZdXBbjbWvrsSQaeHy1VwmOxaRzU2ig,29305
|
5
5
|
ScriptCollection/ProcessesRunner.py,sha256=3mu4ZxzZleQo0Op6o9EYTCFiJfb6kx5ov2YfZfT89mU,1395
|
6
6
|
ScriptCollection/ProgramRunnerBase.py,sha256=2kMIAqdc65UjBAddOZkzy_aFx9h5roZ5a4bQNM6RV6Y,2480
|
7
7
|
ScriptCollection/ProgramRunnerEpew.py,sha256=4pjEd0r9Fcz3TTDv0MdTSd5KkigYXcWUVI1X43regfU,6477
|
8
8
|
ScriptCollection/ProgramRunnerPopen.py,sha256=BPY7-ZMIlqT7JOKz8qlB5c0laF2Js-ijzqk09GxZC48,3821
|
9
9
|
ScriptCollection/SCLog.py,sha256=rMdrEzBKQZBdObPJ9nZ5XCEXRoIFqPh8fAoiX6ZOVuw,4493
|
10
|
-
ScriptCollection/ScriptCollectionCore.py,sha256=
|
11
|
-
ScriptCollection/TasksForCommonProjectStructure.py,sha256=
|
10
|
+
ScriptCollection/ScriptCollectionCore.py,sha256=zm3KiuLoFiz99JZkqUkPhnKVhKD24bDqxpUiAplON24,141383
|
11
|
+
ScriptCollection/TasksForCommonProjectStructure.py,sha256=nXhwH6rfA-XXdQVXYQoxXUQ5sA82d1bDF2EVKdZIfo8,248595
|
12
12
|
ScriptCollection/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
13
|
-
scriptcollection-3.5.
|
14
|
-
scriptcollection-3.5.
|
15
|
-
scriptcollection-3.5.
|
16
|
-
scriptcollection-3.5.
|
17
|
-
scriptcollection-3.5.
|
13
|
+
scriptcollection-3.5.158.dist-info/METADATA,sha256=RLxzi_qgfzjf-_uC_-neTKRG22TJhJK5VKyDRg2SplU,7689
|
14
|
+
scriptcollection-3.5.158.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
15
|
+
scriptcollection-3.5.158.dist-info/entry_points.txt,sha256=EBRDrnGDURysHNyK0Z0fPCnL7uCCO_Mxc6WYJ47KxAI,4234
|
16
|
+
scriptcollection-3.5.158.dist-info/top_level.txt,sha256=hY2hOVH0V0Ce51WB76zKkIWTUNwMUdHo4XDkR2vYVwg,17
|
17
|
+
scriptcollection-3.5.158.dist-info/RECORD,,
|
@@ -32,6 +32,7 @@ scgeneratethumbnail = ScriptCollection.Executables:GenerateThumbnail
|
|
32
32
|
schealthcheck = ScriptCollection.Executables:Healthcheck
|
33
33
|
sckeyboarddiagnosis = ScriptCollection.Executables:KeyboardDiagnosis
|
34
34
|
sclistfoldercontent = ScriptCollection.Executables:ListFolderContent
|
35
|
+
scloc = ScriptCollection.Executables:LOC
|
35
36
|
scmergepdfs = ScriptCollection.Executables:MergePDFs
|
36
37
|
scnpmi = ScriptCollection.Executables:NpmI
|
37
38
|
scobfuscatefilesfolder = ScriptCollection.Executables:ObfuscateFilesFolder
|
File without changes
|
File without changes
|