ScriptCollection 4.4.34__py3-none-any.whl → 4.4.36__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/GeneralUtilities.py +1 -1
- ScriptCollection/ProgramRunnerPopen.py +25 -4
- ScriptCollection/ScriptCollectionCore.py +4 -3
- ScriptCollection/TFCPS/Flutter/TFCPS_CodeUnitSpecific_Flutter.py +78 -13
- ScriptCollection/TFCPS/NodeJS/TFCPS_CodeUnitSpecific_NodeJS.py +34 -7
- ScriptCollection/TFCPS/NpmDependencies.py +109 -0
- ScriptCollection/TFCPS/PubDependencies.py +164 -0
- ScriptCollection/TFCPS/TFCPS_CodeUnit_BuildCodeUnits.py +9 -0
- ScriptCollection/TFCPS/TypeScript/TFCPS_CodeUnitSpecific_TypeScript.py +5 -48
- {scriptcollection-4.4.34.dist-info → scriptcollection-4.4.36.dist-info}/METADATA +3 -3
- {scriptcollection-4.4.34.dist-info → scriptcollection-4.4.36.dist-info}/RECORD +14 -12
- {scriptcollection-4.4.34.dist-info → scriptcollection-4.4.36.dist-info}/WHEEL +0 -0
- {scriptcollection-4.4.34.dist-info → scriptcollection-4.4.36.dist-info}/entry_points.txt +0 -0
- {scriptcollection-4.4.34.dist-info → scriptcollection-4.4.36.dist-info}/top_level.txt +0 -0
|
@@ -1275,7 +1275,7 @@ class GeneralUtilities:
|
|
|
1275
1275
|
cert = crypto.load_certificate(crypto.FILETYPE_PEM, certificate_file_content.read())
|
|
1276
1276
|
date_as_bytes = cert.get_notAfter()
|
|
1277
1277
|
date_as_string = date_as_bytes.decode("utf-8")
|
|
1278
|
-
result = datetime.strptime(date_as_string, '%Y%m%d%H%M%SZ')
|
|
1278
|
+
result = datetime.strptime(date_as_string, '%Y%m%d%H%M%SZ').replace(tzinfo=timezone.utc)
|
|
1279
1279
|
return result
|
|
1280
1280
|
|
|
1281
1281
|
@staticmethod
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import os
|
|
2
2
|
import sys
|
|
3
|
-
from subprocess import PIPE, Popen
|
|
3
|
+
from subprocess import DEVNULL, PIPE, Popen
|
|
4
4
|
from .GeneralUtilities import GeneralUtilities
|
|
5
5
|
from .ProgramRunnerBase import ProgramRunnerBase
|
|
6
6
|
|
|
7
7
|
|
|
8
8
|
class ProgramRunnerPopen(ProgramRunnerBase):
|
|
9
9
|
|
|
10
|
-
|
|
11
|
-
|
|
10
|
+
def __get_process_start_information(self, program: str, arguments_as_array: list[str], env_vars: dict) -> tuple[list[str], dict]:
|
|
11
|
+
"""Returns the argument-list and the environment with which the given program is started."""
|
|
12
12
|
arguments_for_process = [program]
|
|
13
13
|
arguments_for_process.extend(arguments_as_array)
|
|
14
14
|
# "shell=True" is not allowed because it is not recommended and also something like
|
|
@@ -20,6 +20,11 @@ class ProgramRunnerPopen(ProgramRunnerBase):
|
|
|
20
20
|
# relative to their working-directory (e.g. a leftover 'tmp/<guid>'-folder inside a codeunit-folder).
|
|
21
21
|
base_environment = GeneralUtilities._internal_with_absolute_temp_folder_environment_variables(os.environ)
|
|
22
22
|
env = {**base_environment, **env_vars} if env_vars is not None else base_environment
|
|
23
|
+
return arguments_for_process, env
|
|
24
|
+
|
|
25
|
+
@GeneralUtilities.check_arguments
|
|
26
|
+
def run_program_argsasarray_async_helper(self, program: str, arguments_as_array: list[str] = [], working_directory: str = None, custom_argument: object = None, interactive: bool = False, env_vars: dict = None) -> Popen:
|
|
27
|
+
arguments_for_process, env = self.__get_process_start_information(program, arguments_as_array, env_vars)
|
|
23
28
|
try:
|
|
24
29
|
if interactive:
|
|
25
30
|
result = Popen(arguments_for_process, cwd=working_directory, stdout=PIPE, stderr=PIPE, shell=False, text=True, stdin=sys.stdin, env=env) # pylint: disable=consider-using-with
|
|
@@ -53,7 +58,23 @@ class ProgramRunnerPopen(ProgramRunnerBase):
|
|
|
53
58
|
|
|
54
59
|
@GeneralUtilities.check_arguments
|
|
55
60
|
def run_program_argsasarray_async(self, program: str, arguments_as_array: list[str] = [], working_directory: str = None, custom_argument: object = None, interactive: bool = False, env_vars: dict = None) -> int:
|
|
56
|
-
|
|
61
|
+
"""Starts a program which keeps running after this function returned and returns its process-id.
|
|
62
|
+
|
|
63
|
+
The standard-output and the standard-error of the started program are discarded instead of being connected to a pipe.
|
|
64
|
+
A program which is started asynchronously is started to keep running, but nobody reads the pipes of such a program:
|
|
65
|
+
it would be stopped by the operating-system as soon as the pipe is full, and it would be terminated as soon as this
|
|
66
|
+
process ends and closes its end of the pipe. Both would end the program although it is supposed to outlive the caller."""
|
|
67
|
+
arguments_for_process, env = self.__get_process_start_information(program, arguments_as_array, env_vars)
|
|
68
|
+
try:
|
|
69
|
+
if interactive:
|
|
70
|
+
process = Popen(arguments_for_process, cwd=working_directory, stdout=DEVNULL, stderr=DEVNULL, shell=False, text=True, stdin=sys.stdin, env=env) # pylint: disable=consider-using-with
|
|
71
|
+
else:
|
|
72
|
+
process = Popen(arguments_for_process, cwd=working_directory, stdout=DEVNULL, stderr=DEVNULL, shell=False, text=True, env=env) # pylint: disable=consider-using-with
|
|
73
|
+
except FileNotFoundError as fileNotFoundError:
|
|
74
|
+
raise FileNotFoundError(f"Starting '{program}' in '{working_directory}' resulted in a FileNotFoundError: '{str(fileNotFoundError)}'")
|
|
75
|
+
except NotADirectoryError as notADirectoryError:
|
|
76
|
+
raise NotADirectoryError(f"Starting '{program}' in '{working_directory}' resulted in a NotADirectoryError: '{str(notADirectoryError)}'")
|
|
77
|
+
return process.pid
|
|
57
78
|
|
|
58
79
|
@GeneralUtilities.check_arguments
|
|
59
80
|
def run_program_async(self, program: str, arguments: str = "", working_directory: str = None, custom_argument: object = None, interactive: bool = False, env_vars: dict = None) -> int:
|
|
@@ -40,7 +40,7 @@ from .ProgramRunnerBase import ProgramRunnerBase
|
|
|
40
40
|
from .ProgramRunnerPopen import ProgramRunnerPopen
|
|
41
41
|
from .SCLog import SCLog, LogLevel
|
|
42
42
|
|
|
43
|
-
version = "4.4.
|
|
43
|
+
version = "4.4.36"
|
|
44
44
|
__version__ = version
|
|
45
45
|
|
|
46
46
|
class VSCodeWorkspaceShellTask:
|
|
@@ -2730,8 +2730,9 @@ resolving a name requires fontconfig, which does not exist on every system ffmpe
|
|
|
2730
2730
|
mock_loader_result = self.__try_load_mock(program, ' '.join(arguments_as_array), working_directory)
|
|
2731
2731
|
if mock_loader_result[0]:
|
|
2732
2732
|
return mock_loader_result[1]
|
|
2733
|
-
|
|
2734
|
-
|
|
2733
|
+
# The program-runner is used directly here (and not the helper which the synchronous functions use), because a program which
|
|
2734
|
+
# is started asynchronously must not be connected to the pipes of this process: it is started to outlive this call.
|
|
2735
|
+
return self.program_runner.run_program_argsasarray_async(program, arguments_as_array, working_directory, custom_argument, interactive, env_vars)
|
|
2735
2736
|
|
|
2736
2737
|
# Return-values program_runner: Pid
|
|
2737
2738
|
@GeneralUtilities.check_arguments
|
|
@@ -11,9 +11,10 @@ import zipfile
|
|
|
11
11
|
import yaml
|
|
12
12
|
|
|
13
13
|
from ...ArbTranslationsOrganizer import ArbTranslationsOrganizer
|
|
14
|
-
from ...GeneralUtilities import GeneralUtilities
|
|
14
|
+
from ...GeneralUtilities import GeneralUtilities, VersionEcholon
|
|
15
15
|
from ...SCLog import LogLevel
|
|
16
16
|
from ...ScriptCollectionCore import ScriptCollectionCore
|
|
17
|
+
from ..PubDependencies import PubDependencies
|
|
17
18
|
from ..TFCPS_CodeUnitSpecific_Base import TFCPS_CodeUnitSpecific_Base,TFCPS_CodeUnitSpecific_Base_CLI
|
|
18
19
|
from ..TFCPS_RemoteBuild import TFCPS_RemoteBuild, RunnerOperatingSystem
|
|
19
20
|
|
|
@@ -97,10 +98,15 @@ class TFCPS_CodeUnitSpecific_Flutter_Functions(TFCPS_CodeUnitSpecific_Base):
|
|
|
97
98
|
elif target == "windows":
|
|
98
99
|
# Windows-builds prefer a Windows-task-runner - even when building on a Windows-client - so that all builds
|
|
99
100
|
# are produced uniformly in the same defined environment. See the remote-build-article in the reference. If
|
|
100
|
-
# no runner is configured, fall back to building locally
|
|
101
|
-
#
|
|
101
|
+
# no runner is configured, fall back to building locally instead of failing, so a development machine
|
|
102
|
+
# without a configured runner is not blocked. This is the one exception to "no fallbacks": it only applies
|
|
103
|
+
# when this process itself already runs on Windows (a container never does, even on a Windows host, so a
|
|
104
|
+
# containerized build without a configured runner still fails as before) and only when the local
|
|
105
|
+
# prerequisites for it (flutter and the Visual-Studio-C++-toolchain "flutter build windows" needs) are
|
|
106
|
+
# actually available - a machine which lacks them falls through to the runner-branch below, which raises a
|
|
107
|
+
# clear "no runner configured"-error instead of a local build failing with a toolchain-error.
|
|
102
108
|
windows_release_folder = os.path.join(src_folder, "build/windows/x64/runner/Release")
|
|
103
|
-
if platform.system() == "Windows" and not TFCPS_RemoteBuild(self._protected_sc).has_any_runner_configured():
|
|
109
|
+
if platform.system() == "Windows" and not TFCPS_RemoteBuild(self._protected_sc).has_any_runner_configured() and self.__local_windows_build_prerequisites_are_available():
|
|
104
110
|
self._protected_sc.log.log("No remote-build-runner is configured; building the windows-target locally "
|
|
105
111
|
"instead. This build is not guaranteed to be produced in the same uniform "
|
|
106
112
|
"environment as a runner-built one.", LogLevel.Warning)
|
|
@@ -196,6 +202,28 @@ class TFCPS_CodeUnitSpecific_Flutter_Functions(TFCPS_CodeUnitSpecific_Base):
|
|
|
196
202
|
if add_readme_of_codeunit_to_package or add_license_of_repository_to_package or add_changelog_of_repository_to_package:
|
|
197
203
|
self.__add_package_registry_files_to_artifacts(artifacts_folder, package_name, add_readme_of_codeunit_to_package, add_license_of_repository_to_package, add_changelog_of_repository_to_package, branch_of_published_state)
|
|
198
204
|
|
|
205
|
+
@GeneralUtilities.check_arguments
|
|
206
|
+
def __local_windows_build_prerequisites_are_available(self) -> bool:
|
|
207
|
+
"""Whether this machine can build the windows-target of a flutter-app locally: "flutter build windows" needs
|
|
208
|
+
the flutter-tool itself as well as a Visual Studio installation with the "Desktop development with C++"-
|
|
209
|
+
workload, which is not a given on every Windows-machine that otherwise has "flutter" available. Only a
|
|
210
|
+
simple presence-check is done here (not a full "flutter doctor"-verification), because this only decides
|
|
211
|
+
whether the local-build-fallback in build() is attempted at all: an actually broken toolchain still fails
|
|
212
|
+
the "flutter build windows"-call below with its own, real error."""
|
|
213
|
+
if shutil.which("flutter") is None:
|
|
214
|
+
return False
|
|
215
|
+
# Same detection TFCPS_CodeUnitSpecific_CPP_Functions.__find_msbuild_path uses to locate MSBuild: vswhere.exe
|
|
216
|
+
# is installed by every Visual-Studio-installer and can report whether an installation with the C++-desktop-
|
|
217
|
+
# development-component exists, without having to guess a version-specific installation-path.
|
|
218
|
+
program_files_x86 = os.environ.get("ProgramFiles(x86)", r"C:\Program Files (x86)")
|
|
219
|
+
vswhere_path = os.path.join(program_files_x86, "Microsoft Visual Studio", "Installer", "vswhere.exe")
|
|
220
|
+
if not os.path.isfile(vswhere_path):
|
|
221
|
+
return False
|
|
222
|
+
exitcode, installation_path, _, _ = self._protected_sc.run_program_argsasarray(
|
|
223
|
+
vswhere_path, ["-latest", "-products", "*", "-requires", "Microsoft.VisualStudio.Component.VC.Tools.x86.x64", "-property", "installationPath"],
|
|
224
|
+
GeneralUtilities.get_temp_folder(), throw_exception_if_exitcode_is_not_zero=False)
|
|
225
|
+
return exitcode == 0 and GeneralUtilities.string_has_content(installation_path.strip())
|
|
226
|
+
|
|
199
227
|
@GeneralUtilities.check_arguments
|
|
200
228
|
def __generate_bom_for_flutter_package(self, package_name: str) -> None:
|
|
201
229
|
"""Generates the bill-of-materials of the codeunit from the "pubspec.lock" of its package.
|
|
@@ -666,16 +694,53 @@ class TFCPS_CodeUnitSpecific_Flutter_Functions(TFCPS_CodeUnitSpecific_Base):
|
|
|
666
694
|
return re.sub(r' name="lib(\.[^"]*)?"', lambda match: f' name="{codeunit_name}{match.group(1) or ""}"', cobertura_xml_content)
|
|
667
695
|
|
|
668
696
|
|
|
669
|
-
def get_dependencies(self)->dict[str,set[str]]:
|
|
670
|
-
return dict[str,set[str]]()#TODO
|
|
671
|
-
|
|
672
697
|
@GeneralUtilities.check_arguments
|
|
673
|
-
def
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
698
|
+
def get_pubspec_files(self) -> list[str]:
|
|
699
|
+
"""Returns the package-file of every package of this codeunit."""
|
|
700
|
+
return [os.path.join(package_folder, "pubspec.yaml") for package_folder in self.__get_package_folders()]
|
|
701
|
+
|
|
702
|
+
@GeneralUtilities.check_arguments
|
|
703
|
+
def get_dependencies(self) -> dict[str, set[str]]:
|
|
704
|
+
return GeneralUtilities.merge_dependency_lists([PubDependencies.get_dependencies(pubspec_file) for pubspec_file in self.get_pubspec_files()])
|
|
705
|
+
|
|
706
|
+
@GeneralUtilities.check_arguments
|
|
707
|
+
def get_available_versions(self, dependencyname: str) -> list[str]:
|
|
708
|
+
return PubDependencies.get_available_versions(dependencyname)
|
|
709
|
+
|
|
710
|
+
@GeneralUtilities.check_arguments
|
|
711
|
+
def set_dependency_version(self, name: str, new_version: str) -> None:
|
|
712
|
+
# A codeunit can consist of several packages, and a dependency which several of them declare has to be set
|
|
713
|
+
# in every one of them: get_dependencies reports the dependencies of all packages of the codeunit together,
|
|
714
|
+
# so a package which keeps the former version would make the codeunit use two versions of one dependency.
|
|
715
|
+
dependency_was_set: bool = False
|
|
716
|
+
for pubspec_file in self.get_pubspec_files():
|
|
717
|
+
if PubDependencies.set_dependency_version(pubspec_file, name, new_version):
|
|
718
|
+
dependency_was_set = True
|
|
719
|
+
GeneralUtilities.assert_condition(dependency_was_set, f"No package of the codeunit \"{self.get_codeunit_name()}\" contains a dependency which is named \"{name}\".")
|
|
720
|
+
|
|
721
|
+
@GeneralUtilities.check_arguments
|
|
722
|
+
def update_dependencies_with_specific_echolon(self, echolon: VersionEcholon) -> None:
|
|
723
|
+
"""Updates the dependencies of this codeunit and confirms the result in the lock-files of its packages.
|
|
724
|
+
|
|
725
|
+
The update changes the versions the package-files ask for, and the lock-files still state the versions which
|
|
726
|
+
were resolved before. Writing them again is part of the update: without it the state of the dependencies of
|
|
727
|
+
the codeunit would be spread over two files which do not agree, and pub would resolve the old versions
|
|
728
|
+
again as long as they still fit the new constraints.
|
|
729
|
+
|
|
730
|
+
The lock-files are only written when the update really changed a version, because writing them means
|
|
731
|
+
resolving the dependencies again, which is the most expensive part of an update-run."""
|
|
732
|
+
dependencies_before_the_update: dict[str, set[str]] = self.get_dependencies()
|
|
733
|
+
super().update_dependencies_with_specific_echolon(echolon)
|
|
734
|
+
if dependencies_before_the_update == self.get_dependencies():
|
|
735
|
+
return
|
|
736
|
+
for package_folder in self.__get_package_folders():
|
|
737
|
+
# Every package below a package-folder is resolved too, for the same reason for which the linting does
|
|
738
|
+
# so: a package which lies deeper (for example the "example"-application of a library) has a lock-file
|
|
739
|
+
# of its own which states the same dependencies.
|
|
740
|
+
for folder_to_resolve in TFCPS_CodeUnitSpecific_Flutter_Functions.__get_folders_with_a_package(package_folder):
|
|
741
|
+
self._protected_sc.run_with_epew("flutter", "pub get", folder_to_resolve, print_live_output=self.get_verbosity() == LogLevel.Debug)
|
|
742
|
+
|
|
743
|
+
|
|
679
744
|
class TFCPS_CodeUnitSpecific_Flutter_CLI:
|
|
680
745
|
|
|
681
746
|
@staticmethod
|
|
@@ -4,9 +4,10 @@ import json
|
|
|
4
4
|
from pathlib import Path
|
|
5
5
|
import xml.etree.ElementTree as ET
|
|
6
6
|
from lxml import etree
|
|
7
|
-
from ...GeneralUtilities import GeneralUtilities
|
|
7
|
+
from ...GeneralUtilities import GeneralUtilities, VersionEcholon
|
|
8
8
|
from ...SCLog import LogLevel
|
|
9
9
|
from ..TFCPS_CodeUnitSpecific_Base import TFCPS_CodeUnitSpecific_Base,TFCPS_CodeUnitSpecific_Base_CLI
|
|
10
|
+
from ..NpmDependencies import NpmDependencies
|
|
10
11
|
from ...HTTPMaintenanceOverheadHelper import HTTPMaintenanceOverheadHelper
|
|
11
12
|
|
|
12
13
|
class TFCPS_CodeUnitSpecific_NodeJS_Functions(TFCPS_CodeUnitSpecific_Base):
|
|
@@ -126,17 +127,43 @@ class TFCPS_CodeUnitSpecific_NodeJS_Functions(TFCPS_CodeUnitSpecific_Base):
|
|
|
126
127
|
self._protected_sc.run_with_epew("cyclonedx-npm", f"--output-format xml --output-file {relative_path_to_bom_file}", self.get_codeunit_folder(),print_live_output=self._protected_sc.log.loglevel==LogLevel.Diagnostic,encode_argument_in_base64=True)
|
|
127
128
|
self._protected_sc.format_xml_file(self.get_codeunit_folder()+"/"+relative_path_to_bom_file)
|
|
128
129
|
|
|
130
|
+
@GeneralUtilities.check_arguments
|
|
131
|
+
def get_package_json_file(self)->str:
|
|
132
|
+
"""Returns the package-file of this codeunit."""
|
|
133
|
+
return os.path.join(self.get_codeunit_folder(),"package.json")
|
|
134
|
+
|
|
135
|
+
@GeneralUtilities.check_arguments
|
|
129
136
|
def get_dependencies(self)->dict[str,set[str]]:
|
|
130
|
-
return
|
|
131
|
-
|
|
137
|
+
return GeneralUtilities.merge_dependency_lists([NpmDependencies.get_dependencies(self.get_package_json_file())])
|
|
138
|
+
|
|
132
139
|
@GeneralUtilities.check_arguments
|
|
133
140
|
def get_available_versions(self,dependencyname:str)->list[str]:
|
|
134
|
-
return
|
|
135
|
-
|
|
141
|
+
return NpmDependencies.get_available_versions(dependencyname)
|
|
142
|
+
|
|
136
143
|
@GeneralUtilities.check_arguments
|
|
137
144
|
def set_dependency_version(self,name:str,new_version:str)->None:
|
|
138
|
-
|
|
139
|
-
|
|
145
|
+
package_json_file:str=self.get_package_json_file()
|
|
146
|
+
GeneralUtilities.assert_condition(NpmDependencies.set_dependency_version(package_json_file,name,new_version),f"The package-file \"{package_json_file}\" does not contain a dependency which is named \"{name}\".")
|
|
147
|
+
self._protected_sc.format_json_file(package_json_file)
|
|
148
|
+
|
|
149
|
+
@GeneralUtilities.check_arguments
|
|
150
|
+
def update_dependencies_with_specific_echolon(self,echolon:VersionEcholon)->None:
|
|
151
|
+
"""Updates the dependencies of this codeunit and confirms the result in its lock-file.
|
|
152
|
+
|
|
153
|
+
The update changes the versions the package-file asks for, and the lock-file still states the versions which
|
|
154
|
+
were resolved before. Writing it again is part of the update: without it the state of the dependencies of
|
|
155
|
+
the codeunit would be spread over two files which do not agree, and the next build would install the old
|
|
156
|
+
versions again.
|
|
157
|
+
|
|
158
|
+
The lock-file is only written when the update really changed a version, because writing it means installing
|
|
159
|
+
the dependencies again, which is the most expensive part of an update-run."""
|
|
160
|
+
dependencies_before_the_update:dict[str,set[str]]=self.get_dependencies()
|
|
161
|
+
super().update_dependencies_with_specific_echolon(echolon)
|
|
162
|
+
if dependencies_before_the_update!=self.get_dependencies():
|
|
163
|
+
#The cache must not be used here: the whole point of this install is to resolve the dependencies again.
|
|
164
|
+
self.tfcps_Tools_General.do_npm_install(self.get_codeunit_folder(),True,False)
|
|
165
|
+
|
|
166
|
+
|
|
140
167
|
@GeneralUtilities.check_arguments
|
|
141
168
|
def add_culture_chooser(self,site_title:str,supported_cultures:list[str])->None:
|
|
142
169
|
output_folder=self.get_codeunit_folder()+"/Other/Artifacts/BuildResult_WebApplication/browser"
|
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
import json
|
|
2
|
+
import re
|
|
3
|
+
import requests
|
|
4
|
+
from ..GeneralUtilities import GeneralUtilities, Dependency
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
class NpmDependencies:
|
|
8
|
+
"""Reads and writes the dependencies which a npm-package-file ("package.json") declares and asks the
|
|
9
|
+
npm-registry which versions of such a dependency exist.
|
|
10
|
+
|
|
11
|
+
This is implemented here and not inside one of the codeunit-type-specific classes because a nodejs-codeunit and
|
|
12
|
+
a typescript-codeunit declare their dependencies in exactly the same file-format and resolve them from exactly
|
|
13
|
+
the same registry. Only the location of the package-file differs between them, which is why every operation
|
|
14
|
+
takes that file as its argument."""
|
|
15
|
+
|
|
16
|
+
__dependency_sections: tuple = ("dependencies", "devDependencies")
|
|
17
|
+
__version_regex: str = r"^\d+\.\d+\.\d+$"
|
|
18
|
+
__range_prefixes: tuple = ("^", "~")
|
|
19
|
+
|
|
20
|
+
@staticmethod
|
|
21
|
+
@GeneralUtilities.check_arguments
|
|
22
|
+
def get_dependencies(package_json_file: str) -> list[Dependency]:
|
|
23
|
+
"""Returns the updatable dependencies which the given package-file declares."""
|
|
24
|
+
content: dict = NpmDependencies.__read_package_file(package_json_file)
|
|
25
|
+
return [Dependency(name, version) for name, version in NpmDependencies.get_dependency_entries(content)]
|
|
26
|
+
|
|
27
|
+
@staticmethod
|
|
28
|
+
@GeneralUtilities.check_arguments
|
|
29
|
+
def get_dependency_entries(package_json_content: dict) -> list[tuple[str, str]]:
|
|
30
|
+
"""Returns the updatable dependencies of the given package-file-content as tuples of their name and their
|
|
31
|
+
version.
|
|
32
|
+
|
|
33
|
+
Only a dependency whose version is a plain version-number is returned, because a dependency which points to
|
|
34
|
+
a file, a repository or a tag has no version on the registry which could be updated, and a dependency which
|
|
35
|
+
declares a version-range has no single version which an update could raise."""
|
|
36
|
+
result: list[tuple[str, str]] = []
|
|
37
|
+
for section in NpmDependencies.__dependency_sections:
|
|
38
|
+
for name, declared_version in package_json_content.get(section, {}).items():
|
|
39
|
+
# A declared version usually carries a range-prefix ("^1.2.3" or "~1.2.3"), which is not part of
|
|
40
|
+
# the version itself.
|
|
41
|
+
version_without_prefix: str = NpmDependencies.__remove_range_prefix(declared_version)
|
|
42
|
+
if re.match(NpmDependencies.__version_regex, version_without_prefix) is not None:
|
|
43
|
+
result.append((name, version_without_prefix))
|
|
44
|
+
return result
|
|
45
|
+
|
|
46
|
+
@staticmethod
|
|
47
|
+
@GeneralUtilities.check_arguments
|
|
48
|
+
def get_available_versions(dependencyname: str) -> list[str]:
|
|
49
|
+
"""Returns every published version of the given package which is a plain version-number.
|
|
50
|
+
|
|
51
|
+
A pre-release carries a suffix ("1.2.3-beta.1") and is deliberately not returned: an update which runs
|
|
52
|
+
unattended must not move a codeunit onto a version which its publisher did not release as a regular one."""
|
|
53
|
+
# The registry of npm answers with all published versions of a package. The abbreviated metadata-format is
|
|
54
|
+
# requested because the full document additionally contains the readme of every single version, which is a
|
|
55
|
+
# multiple of the amount of data which is needed here.
|
|
56
|
+
response = requests.get(f"https://registry.npmjs.org/{dependencyname}", headers={"Accept": "application/vnd.npm.install-v1+json"}, timeout=60)
|
|
57
|
+
response.raise_for_status()
|
|
58
|
+
result: list[str] = []
|
|
59
|
+
for version_string in response.json().get("versions", {}).keys():
|
|
60
|
+
if re.match(NpmDependencies.__version_regex, version_string) is not None:
|
|
61
|
+
result.append(version_string)
|
|
62
|
+
return result
|
|
63
|
+
|
|
64
|
+
@staticmethod
|
|
65
|
+
@GeneralUtilities.check_arguments
|
|
66
|
+
def set_dependency_version(package_json_file: str, name: str, new_version: str) -> bool:
|
|
67
|
+
"""Sets the version of the dependency [name] in the given package-file and returns whether that package-file
|
|
68
|
+
declares a dependency with that name at all."""
|
|
69
|
+
content: dict = NpmDependencies.__read_package_file(package_json_file)
|
|
70
|
+
if not NpmDependencies.declares_dependency(content, name):
|
|
71
|
+
return False
|
|
72
|
+
new_content: dict = NpmDependencies.set_dependency_version_in_content(content, name, new_version)
|
|
73
|
+
GeneralUtilities.write_text_to_file(package_json_file, json.dumps(new_content, indent=2, ensure_ascii=False)+"\n")
|
|
74
|
+
return True
|
|
75
|
+
|
|
76
|
+
@staticmethod
|
|
77
|
+
@GeneralUtilities.check_arguments
|
|
78
|
+
def declares_dependency(package_json_content: dict, name: str) -> bool:
|
|
79
|
+
"""Returns whether the given package-file-content declares a dependency which is named [name]."""
|
|
80
|
+
for section in NpmDependencies.__dependency_sections:
|
|
81
|
+
if name in package_json_content.get(section, {}):
|
|
82
|
+
return True
|
|
83
|
+
return False
|
|
84
|
+
|
|
85
|
+
@staticmethod
|
|
86
|
+
@GeneralUtilities.check_arguments
|
|
87
|
+
def set_dependency_version_in_content(package_json_content: dict, name: str, new_version: str) -> dict:
|
|
88
|
+
"""Returns the given package-file-content with the version of the dependency [name] set to [new_version].
|
|
89
|
+
The content is returned unchanged when it does not declare a dependency with that name."""
|
|
90
|
+
for section in NpmDependencies.__dependency_sections:
|
|
91
|
+
if name in package_json_content.get(section, {}):
|
|
92
|
+
# The range-prefix of the former declaration is kept, because it states how the project wants to
|
|
93
|
+
# accept updates and that is not a decision of this function.
|
|
94
|
+
former_declaration: str = package_json_content[section][name]
|
|
95
|
+
prefix: str = former_declaration[0] if former_declaration[0] in NpmDependencies.__range_prefixes else GeneralUtilities.empty_string
|
|
96
|
+
package_json_content[section][name] = f"{prefix}{new_version}"
|
|
97
|
+
return package_json_content
|
|
98
|
+
|
|
99
|
+
@staticmethod
|
|
100
|
+
@GeneralUtilities.check_arguments
|
|
101
|
+
def __remove_range_prefix(declared_version: str) -> str:
|
|
102
|
+
if declared_version.startswith(NpmDependencies.__range_prefixes):
|
|
103
|
+
return declared_version[1:]
|
|
104
|
+
return declared_version
|
|
105
|
+
|
|
106
|
+
@staticmethod
|
|
107
|
+
@GeneralUtilities.check_arguments
|
|
108
|
+
def __read_package_file(package_json_file: str) -> dict:
|
|
109
|
+
return json.loads(GeneralUtilities.read_text_from_file(package_json_file))
|
|
@@ -0,0 +1,164 @@
|
|
|
1
|
+
import re
|
|
2
|
+
import requests
|
|
3
|
+
from ..GeneralUtilities import GeneralUtilities, Dependency
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
class PubDependencies:
|
|
7
|
+
"""Reads and writes the dependencies which a pub-package-file ("pubspec.yaml") declares and asks pub.dev which
|
|
8
|
+
versions of such a dependency exist.
|
|
9
|
+
|
|
10
|
+
This is implemented here and not inside one of the codeunit-type-specific classes because a flutter-codeunit and
|
|
11
|
+
a dart-codeunit declare their dependencies in exactly the same file-format and resolve them from exactly the
|
|
12
|
+
same package-source. Only the location of the package-file differs between them, which is why every operation
|
|
13
|
+
takes that file as its argument.
|
|
14
|
+
|
|
15
|
+
The package-file is processed line by line and not by loading and dumping it as yaml: writing it back as yaml
|
|
16
|
+
would drop its comments and normalize its whole formatting, while a pubspec.yaml is a file which is maintained
|
|
17
|
+
by hand and in which an update of one version must not rewrite anything else."""
|
|
18
|
+
|
|
19
|
+
__dependency_sections: tuple = ("dependencies", "dev_dependencies", "dependency_overrides")
|
|
20
|
+
__version_regex: str = r"^\d+\.\d+\.\d+$"
|
|
21
|
+
__version_constraint_regex: str = r"^(\^?)(\d+\.\d+\.\d+)$"
|
|
22
|
+
|
|
23
|
+
@staticmethod
|
|
24
|
+
@GeneralUtilities.check_arguments
|
|
25
|
+
def get_dependencies(pubspec_file: str) -> list[Dependency]:
|
|
26
|
+
"""Returns the updatable dependencies which the given package-file declares."""
|
|
27
|
+
content: str = GeneralUtilities.read_text_from_file(pubspec_file)
|
|
28
|
+
return [Dependency(name, version) for name, version in PubDependencies.get_dependency_entries(content)]
|
|
29
|
+
|
|
30
|
+
@staticmethod
|
|
31
|
+
@GeneralUtilities.check_arguments
|
|
32
|
+
def get_dependency_entries(pubspec_content: str) -> list[tuple[str, str]]:
|
|
33
|
+
"""Returns the updatable dependencies of the given package-file-content as tuples of their name and their
|
|
34
|
+
version.
|
|
35
|
+
|
|
36
|
+
Only a dependency which declares a plain version-constraint is returned: a dependency which is declared as a
|
|
37
|
+
block (a sdk-, a path- or a git-dependency, for example) is not resolved from pub.dev at all, and a
|
|
38
|
+
dependency which declares a version-range has no single version which an update could raise."""
|
|
39
|
+
result: list[tuple[str, str]] = []
|
|
40
|
+
for _, _, name, version_constraint in PubDependencies.__enumerate_entries(PubDependencies.__content_to_lines(pubspec_content)):
|
|
41
|
+
constraint_match = re.match(PubDependencies.__version_constraint_regex, version_constraint)
|
|
42
|
+
if constraint_match is not None:
|
|
43
|
+
# A declared constraint usually carries the caret-prefix ("^1.2.3"), which is not part of the
|
|
44
|
+
# version itself.
|
|
45
|
+
result.append((name, constraint_match.group(2)))
|
|
46
|
+
return result
|
|
47
|
+
|
|
48
|
+
@staticmethod
|
|
49
|
+
@GeneralUtilities.check_arguments
|
|
50
|
+
def get_available_versions(dependencyname: str) -> list[str]:
|
|
51
|
+
"""Returns every published version of the given package which is a plain version-number.
|
|
52
|
+
|
|
53
|
+
A retracted version is skipped, because its publisher declared it as a version which must not be used
|
|
54
|
+
anymore. A pre-release carries a suffix ("1.2.3-beta.1") and is deliberately not returned either: an update
|
|
55
|
+
which runs unattended must not move a codeunit onto a version which its publisher did not release as a
|
|
56
|
+
regular one."""
|
|
57
|
+
# The api of pub.dev answers with all published versions of a package.
|
|
58
|
+
response = requests.get(f"https://pub.dev/api/packages/{dependencyname}", headers={"Accept": "application/vnd.pub.v2+json"}, timeout=60)
|
|
59
|
+
response.raise_for_status()
|
|
60
|
+
result: list[str] = []
|
|
61
|
+
for published_version in response.json()["versions"]:
|
|
62
|
+
if published_version.get("retracted", False):
|
|
63
|
+
continue
|
|
64
|
+
version_string: str = str(published_version["version"])
|
|
65
|
+
if re.match(PubDependencies.__version_regex, version_string) is not None:
|
|
66
|
+
result.append(version_string)
|
|
67
|
+
return result
|
|
68
|
+
|
|
69
|
+
@staticmethod
|
|
70
|
+
@GeneralUtilities.check_arguments
|
|
71
|
+
def set_dependency_version(pubspec_file: str, name: str, new_version: str) -> bool:
|
|
72
|
+
"""Sets the version of the dependency [name] in the given package-file and returns whether that package-file
|
|
73
|
+
declares a dependency with that name at all."""
|
|
74
|
+
lines: list[str] = GeneralUtilities.read_lines_from_file(pubspec_file)
|
|
75
|
+
if not PubDependencies.declares_dependency(lines, name):
|
|
76
|
+
return False
|
|
77
|
+
GeneralUtilities.write_lines_to_file(pubspec_file, PubDependencies.set_dependency_version_in_lines(lines, name, new_version))
|
|
78
|
+
return True
|
|
79
|
+
|
|
80
|
+
@staticmethod
|
|
81
|
+
@GeneralUtilities.check_arguments
|
|
82
|
+
def declares_dependency(pubspec_lines: list[str], name: str) -> bool:
|
|
83
|
+
"""Returns whether the given lines of a package-file declare a dependency which is named [name]."""
|
|
84
|
+
for _, _, entry_name, _ in PubDependencies.__enumerate_entries(pubspec_lines):
|
|
85
|
+
if entry_name == name:
|
|
86
|
+
return True
|
|
87
|
+
return False
|
|
88
|
+
|
|
89
|
+
@staticmethod
|
|
90
|
+
@GeneralUtilities.check_arguments
|
|
91
|
+
def set_dependency_version_in_lines(pubspec_lines: list[str], name: str, new_version: str) -> list[str]:
|
|
92
|
+
"""Returns the given lines of a package-file with the version of the dependency [name] set to [new_version].
|
|
93
|
+
|
|
94
|
+
Only the version itself is replaced, so the indentation, the constraint-prefix and a comment of the line
|
|
95
|
+
stay as they are. A dependency which does not declare a plain version-constraint is not touched, for the
|
|
96
|
+
same reason for which get_dependency_entries does not return it."""
|
|
97
|
+
result: list[str] = list(pubspec_lines)
|
|
98
|
+
for index, _, entry_name, version_constraint in PubDependencies.__enumerate_entries(pubspec_lines):
|
|
99
|
+
if entry_name != name:
|
|
100
|
+
continue
|
|
101
|
+
constraint_match = re.match(PubDependencies.__version_constraint_regex, version_constraint)
|
|
102
|
+
if constraint_match is None:
|
|
103
|
+
continue
|
|
104
|
+
former_constraint: str = constraint_match.group(0)
|
|
105
|
+
new_constraint: str = f"{constraint_match.group(1)}{new_version}"
|
|
106
|
+
# The line is split into what stands in front of the constraint, the constraint itself and what stands
|
|
107
|
+
# behind it (a comment), so that only the constraint is exchanged and the rest of the line is kept.
|
|
108
|
+
line_match = re.match(r"^(\s*"+re.escape(entry_name)+r":\s*)"+re.escape(former_constraint)+r"(.*)$", result[index])
|
|
109
|
+
GeneralUtilities.assert_condition(line_match is not None, f"The line \"{result[index]}\" does not declare the dependency \"{entry_name}\" in the way it was read from it.")
|
|
110
|
+
result[index] = f"{line_match.group(1)}{new_constraint}{line_match.group(2)}"
|
|
111
|
+
return result
|
|
112
|
+
|
|
113
|
+
@staticmethod
|
|
114
|
+
@GeneralUtilities.check_arguments
|
|
115
|
+
def __enumerate_entries(pubspec_lines: list[str]) -> list[tuple[int, str, str, str]]:
|
|
116
|
+
"""Returns every dependency which the given lines of a package-file declare, as tuples of the index of the
|
|
117
|
+
line which declares it, the section it is declared in, its name and the value it is declared with."""
|
|
118
|
+
current_section: str = None
|
|
119
|
+
entry_indentation: int = None
|
|
120
|
+
result: list[tuple[int, str, str, str]] = []
|
|
121
|
+
for index, line in enumerate(pubspec_lines):
|
|
122
|
+
line_without_comment: str = PubDependencies.__remove_comment(line)
|
|
123
|
+
if not GeneralUtilities.string_has_content(line_without_comment):
|
|
124
|
+
continue
|
|
125
|
+
if not line_without_comment.startswith(" "):
|
|
126
|
+
# A line without indentation declares a new top-level key, so the section which was processed until
|
|
127
|
+
# here has ended. Only a key without a value of its own opens a section which can contain
|
|
128
|
+
# dependencies.
|
|
129
|
+
section_match = re.match(r"^([A-Za-z0-9_]+):$", line_without_comment)
|
|
130
|
+
current_section = section_match.group(1) if section_match is not None else None
|
|
131
|
+
entry_indentation = None
|
|
132
|
+
continue
|
|
133
|
+
if current_section not in PubDependencies.__dependency_sections:
|
|
134
|
+
continue
|
|
135
|
+
indentation: int = len(line_without_comment)-len(line_without_comment.lstrip(" "))
|
|
136
|
+
if entry_indentation is None:
|
|
137
|
+
# The first indented line of a section states on which indentation the dependencies of that section
|
|
138
|
+
# are declared. Everything which is indented deeper belongs to the declaration of one of them (the
|
|
139
|
+
# "sdk"-key of a sdk-dependency or the "version"-key of a hosted dependency, for example) and is not
|
|
140
|
+
# a dependency of its own.
|
|
141
|
+
entry_indentation = indentation
|
|
142
|
+
if indentation != entry_indentation:
|
|
143
|
+
continue
|
|
144
|
+
entry_match = re.match(r"^\s+([A-Za-z0-9_]+):\s*(\S.*)$", line_without_comment)
|
|
145
|
+
if entry_match is not None:
|
|
146
|
+
result.append((index, current_section, entry_match.group(1), entry_match.group(2)))
|
|
147
|
+
return result
|
|
148
|
+
|
|
149
|
+
@staticmethod
|
|
150
|
+
@GeneralUtilities.check_arguments
|
|
151
|
+
def __remove_comment(line: str) -> str:
|
|
152
|
+
"""Returns the given line without its comment and without its trailing whitespace. In yaml a "#" starts a
|
|
153
|
+
comment when it stands at the beginning of a line or when a whitespace stands in front of it."""
|
|
154
|
+
comment_match = re.search(r"(^|\s)#", line)
|
|
155
|
+
if comment_match is None:
|
|
156
|
+
return line.rstrip()
|
|
157
|
+
return line[:comment_match.start()].rstrip()
|
|
158
|
+
|
|
159
|
+
@staticmethod
|
|
160
|
+
@GeneralUtilities.check_arguments
|
|
161
|
+
def __content_to_lines(pubspec_content: str) -> list[str]:
|
|
162
|
+
# The lines are taken as they are, because the indentation of a line is what states whether it declares a
|
|
163
|
+
# dependency or a detail of one.
|
|
164
|
+
return GeneralUtilities.string_to_lines(pubspec_content, True, False)
|
|
@@ -134,6 +134,15 @@ class TFCPS_CodeUnit_BuildCodeUnits:
|
|
|
134
134
|
|
|
135
135
|
self.sc.log.log(f"Start building codeunits at {GeneralUtilities.datetime_to_string_for_readable_entry(start_time,False)}. (Target environment-type: {self.target_environment_type})")
|
|
136
136
|
|
|
137
|
+
#ensure common cache-files are available
|
|
138
|
+
#git commit message cache file
|
|
139
|
+
cache_folder=os.path.join(self.repository,".ScriptCollection","Cache")
|
|
140
|
+
GeneralUtilities.ensure_directory_exists(cache_folder)
|
|
141
|
+
git_commit_message_cache_file=os.path.join(cache_folder,"GitCommitMessageDraft.txt")
|
|
142
|
+
GeneralUtilities.ensure_file_exists(git_commit_message_cache_file)
|
|
143
|
+
git_commit_message_cache_file=os.path.join(cache_folder,"GitCommitDescriptionDraft.txt")
|
|
144
|
+
GeneralUtilities.ensure_file_exists(git_commit_message_cache_file)
|
|
145
|
+
|
|
137
146
|
self.tfcps_tools_general.ensure_required_environment_variables_are_set(self.repository)
|
|
138
147
|
|
|
139
148
|
self.__run_custom_pre_codeunit_build_script()
|
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
import os
|
|
2
|
-
import re
|
|
3
|
-
import json
|
|
4
2
|
import shutil
|
|
5
|
-
import requests
|
|
6
3
|
from lxml import etree
|
|
7
|
-
from ...GeneralUtilities import GeneralUtilities
|
|
4
|
+
from ...GeneralUtilities import GeneralUtilities
|
|
8
5
|
from ...SCLog import LogLevel
|
|
6
|
+
from ..NpmDependencies import NpmDependencies
|
|
9
7
|
from ..TFCPS_CodeUnitSpecific_Base import TFCPS_CodeUnitSpecific_Base, TFCPS_CodeUnitSpecific_Base_CLI
|
|
10
8
|
|
|
11
9
|
class TFCPS_CodeUnitSpecific_TypeScript_Functions(TFCPS_CodeUnitSpecific_Base):
|
|
@@ -123,57 +121,16 @@ class TFCPS_CodeUnitSpecific_TypeScript_Functions(TFCPS_CodeUnitSpecific_Base):
|
|
|
123
121
|
|
|
124
122
|
@GeneralUtilities.check_arguments
|
|
125
123
|
def get_dependencies(self) -> dict[str, set[str]]:
|
|
126
|
-
return GeneralUtilities.merge_dependency_lists([self.
|
|
127
|
-
|
|
128
|
-
@GeneralUtilities.check_arguments
|
|
129
|
-
def __get_dependencies_from_package_json_file(self) -> list[Dependency]:
|
|
130
|
-
result: list[Dependency] = []
|
|
131
|
-
for name, dependency_version in self.__enumerate_dependency_entries():
|
|
132
|
-
result.append(Dependency(name, dependency_version))
|
|
133
|
-
return result
|
|
134
|
-
|
|
135
|
-
@GeneralUtilities.check_arguments
|
|
136
|
-
def __enumerate_dependency_entries(self) -> list[tuple[str, str]]:
|
|
137
|
-
"""Returns the dependencies of the package-file as tuples of their name and their version. Only a
|
|
138
|
-
dependency whose version is a plain version-number is returned, because a dependency which points to a
|
|
139
|
-
file, a repository or a tag has no version which could be updated."""
|
|
140
|
-
content = json.loads(GeneralUtilities.read_text_from_file(self.get_package_json_file()))
|
|
141
|
-
result: list[tuple[str, str]] = []
|
|
142
|
-
for section in ("dependencies", "devDependencies"):
|
|
143
|
-
for name, declared_version in content.get(section, {}).items():
|
|
144
|
-
# A declared version usually carries a range-prefix ("^1.2.3" or "~1.2.3"), which is not part of
|
|
145
|
-
# the version itself.
|
|
146
|
-
version_without_prefix = declared_version.lstrip("^~")
|
|
147
|
-
if re.match(r"^\d+\.\d+\.\d+$", version_without_prefix) is not None:
|
|
148
|
-
result.append((name, version_without_prefix))
|
|
149
|
-
return result
|
|
124
|
+
return GeneralUtilities.merge_dependency_lists([NpmDependencies.get_dependencies(self.get_package_json_file())])
|
|
150
125
|
|
|
151
126
|
@GeneralUtilities.check_arguments
|
|
152
127
|
def get_available_versions(self, dependencyname: str) -> list[str]:
|
|
153
|
-
|
|
154
|
-
response = requests.get(f"https://registry.npmjs.org/{dependencyname}", headers={"Accept": "application/vnd.npm.install-v1+json"}, timeout=60)
|
|
155
|
-
response.raise_for_status()
|
|
156
|
-
result: list[str] = []
|
|
157
|
-
for version_string in response.json().get("versions", {}).keys():
|
|
158
|
-
if re.match(r"^\d+\.\d+\.\d+$", version_string) is not None:
|
|
159
|
-
result.append(version_string)
|
|
160
|
-
return result
|
|
128
|
+
return NpmDependencies.get_available_versions(dependencyname)
|
|
161
129
|
|
|
162
130
|
@GeneralUtilities.check_arguments
|
|
163
131
|
def set_dependency_version(self, name: str, new_version: str) -> None:
|
|
164
132
|
package_json_file = self.get_package_json_file()
|
|
165
|
-
|
|
166
|
-
dependency_was_set: bool = False
|
|
167
|
-
for section in ("dependencies", "devDependencies"):
|
|
168
|
-
if name in content.get(section, {}):
|
|
169
|
-
# The range-prefix of the former declaration is kept, because it states how the project wants to
|
|
170
|
-
# accept updates and that is not a decision of this function.
|
|
171
|
-
former_declaration = content[section][name]
|
|
172
|
-
prefix = former_declaration[0] if former_declaration[0] in ("^", "~") else GeneralUtilities.empty_string
|
|
173
|
-
content[section][name] = f"{prefix}{new_version}"
|
|
174
|
-
dependency_was_set = True
|
|
175
|
-
GeneralUtilities.assert_condition(dependency_was_set, f'The package-file "{package_json_file}" does not contain a dependency which is named "{name}".')
|
|
176
|
-
GeneralUtilities.write_text_to_file(package_json_file, json.dumps(content, indent=2, ensure_ascii=False) + "\n")
|
|
133
|
+
GeneralUtilities.assert_condition(NpmDependencies.set_dependency_version(package_json_file, name, new_version), f'The package-file "{package_json_file}" does not contain a dependency which is named "{name}".')
|
|
177
134
|
self._protected_sc.format_json_file(package_json_file)
|
|
178
135
|
|
|
179
136
|
class TFCPS_CodeUnitSpecific_TypeScript_CLI:
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: scriptcollection
|
|
3
|
-
Version: 4.4.
|
|
3
|
+
Version: 4.4.36
|
|
4
4
|
Summary: The ScriptCollection is the place for reusable scripts.
|
|
5
5
|
Author-email: Marius Göcke <marius.goecke@gmail.com>
|
|
6
|
+
License-Expression: GPL-3.0-only
|
|
6
7
|
Project-URL: Homepage, https://github.com/anionDev/ScriptCollection
|
|
7
8
|
Project-URL: Documentation, https://aniondev.github.io/ScriptCollectionReference/index.html
|
|
8
9
|
Project-URL: Changelog, https://github.com/anionDev/ScriptCollection/tree/main/Other/Resources/Changelog
|
|
@@ -10,7 +11,6 @@ Keywords: package,release,build,management
|
|
|
10
11
|
Classifier: Intended Audience :: Developers
|
|
11
12
|
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
|
12
13
|
Classifier: Programming Language :: Python :: 3.11
|
|
13
|
-
Classifier: License :: OSI Approved :: GNU General Public License v3 (GPLv3)
|
|
14
14
|
Classifier: Operating System :: POSIX :: Linux
|
|
15
15
|
Classifier: Operating System :: Microsoft :: Windows :: Windows 10
|
|
16
16
|
Classifier: Topic :: System :: Logging
|
|
@@ -34,7 +34,7 @@ Requires-Dist: Pillow>=11.3.0
|
|
|
34
34
|
Requires-Dist: psutil>=7.2.2
|
|
35
35
|
Requires-Dist: pycdlib>=1.20.0
|
|
36
36
|
Requires-Dist: Pygments>=2.21.0
|
|
37
|
-
Requires-Dist: pylint>=4.0.
|
|
37
|
+
Requires-Dist: pylint>=4.0.9
|
|
38
38
|
Requires-Dist: pyOpenSSL>=25.3.0
|
|
39
39
|
Requires-Dist: PyPDF>=6.19.0
|
|
40
40
|
Requires-Dist: pytest>=8.4.2
|
|
@@ -2,17 +2,17 @@ ScriptCollection/AnionBuildPlatform.py,sha256=LF9b4f4iqgsjgXZjS0RHiEBw73tQANfu0O
|
|
|
2
2
|
ScriptCollection/ArbTranslationsOrganizer.py,sha256=FLJcNP6qFTQOkxL7es0Sq3O7kb_TgoRreqH-uogR4xA,12201
|
|
3
3
|
ScriptCollection/CertificateUpdater.py,sha256=bD0VhKQsD2cNRTG1kzMkhgpd0BZw7igbG30goKw5p1A,9749
|
|
4
4
|
ScriptCollection/Executables.py,sha256=Ovq6LVhtP6mqCPmBxch9WgTmePBk7F8MLyZUBkQloAE,74171
|
|
5
|
-
ScriptCollection/GeneralUtilities.py,sha256=
|
|
5
|
+
ScriptCollection/GeneralUtilities.py,sha256=JO95CNaNjH_ooZ0db56kwRjRDgT_-RdWAvClItlnQBM,72045
|
|
6
6
|
ScriptCollection/HTTPMaintenanceOverheadHelper.py,sha256=TToNtyO1XzsMbBsTBf3o0xgOK0v4Jf03qw2Z0xb2nCk,2007
|
|
7
7
|
ScriptCollection/ProcessesRunner.py,sha256=Va9O-ohWoRfe4pO2gPBzc940gkM5BpP4Txcu1CmLOvg,1494
|
|
8
8
|
ScriptCollection/ProgramRunnerBase.py,sha256=eZenpiIFW1dhvSVCG7cfBs5hO4_KLlOxR7oXoSxUDmk,2286
|
|
9
9
|
ScriptCollection/ProgramRunnerMock.py,sha256=uTu-aFle1W_oKjeQEmuPsFPQpvo0kRf2FrRjAPIwT5Y,37
|
|
10
|
-
ScriptCollection/ProgramRunnerPopen.py,sha256=
|
|
10
|
+
ScriptCollection/ProgramRunnerPopen.py,sha256=swRlWMQ3WiAkF3PTerraXU-LAAIdyvKbpW1CrQmee38,6497
|
|
11
11
|
ScriptCollection/ProgramRunnerSudo.py,sha256=ot9Ib-plQ8wejR9M2XXfnx6GR-va9k8SH1gAC5kjaJ0,5123
|
|
12
12
|
ScriptCollection/RepositoryDiagramGenerator.py,sha256=K_u2NW_p4ozdWD50irJEkkcDVa70TcUJpZN63TeXSLw,7092
|
|
13
13
|
ScriptCollection/RepositoryHistoryAnalyzer.py,sha256=rD8eC5lMUe5MHmCBHfYft_G-N9IbvtsFGkU7EMwPjrY,5779
|
|
14
14
|
ScriptCollection/SCLog.py,sha256=Fjf8Pdi63cXHGMxL_aI6A0dwGm7QIfrv3czjvpSUlaM,4705
|
|
15
|
-
ScriptCollection/ScriptCollectionCore.py,sha256=
|
|
15
|
+
ScriptCollection/ScriptCollectionCore.py,sha256=oqRxDHa1Pd1rl9XNh5i-gRIuu_X8_vrqLVx5oIL6h6s,300376
|
|
16
16
|
ScriptCollection/TestKind.py,sha256=jqLJwNvQeyea7SZf-UFzMC9pM0znv4do7FIC1xq8u9M,1672
|
|
17
17
|
ScriptCollection/UnassignedVariablesCheck.py,sha256=8xNcp1D5HeOLO1a1NEerq2TsnpFhw7yzYPkaay-oisY,3804
|
|
18
18
|
ScriptCollection/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
@@ -31,13 +31,15 @@ ScriptCollection/Resources/CultureChooser/index.html,sha256=gxQzbrSp4WU52TqN-gcB
|
|
|
31
31
|
ScriptCollection/Resources/Dependencies/JRE/Version.txt,sha256=WlFzNJMH4lfVzW5QGHnuE52jLujSGpQ48zVB-Cln-7g,9
|
|
32
32
|
ScriptCollection/Resources/Dependencies/OpenAPIGenerator/Version.txt,sha256=hdAgOhOHx4s13fJ-j0A06oYoM9rdEfDe0RzHoeAKXxo,7
|
|
33
33
|
ScriptCollection/Resources/MaintenanceSite/MaintenanceSite.html,sha256=CX9S1bdOz6xU2aGfr03tJRGczQrlpn-IeODc15d5kc0,232
|
|
34
|
+
ScriptCollection/TFCPS/NpmDependencies.py,sha256=IfUh9EyrkHxovGRWYagNMZjBUXyKjZ4AG-Z8leehw24,6304
|
|
34
35
|
ScriptCollection/TFCPS/PackageSource.py,sha256=tQoMbxrIbV3mYHKH2wgOoGzIHY1TvBH8EAFpWGhryrQ,1311
|
|
35
36
|
ScriptCollection/TFCPS/PlantUMLRenderer.py,sha256=upnafiGKV-SdRI8iRBkbbWHN2u6v9KxoswdKi12AwoY,11060
|
|
37
|
+
ScriptCollection/TFCPS/PubDependencies.py,sha256=hl6BfYjzb0-esO-pqyV_sxBLbHBi55GEgUiub3lma_8,9922
|
|
36
38
|
ScriptCollection/TFCPS/SCTaskRunnerServer.py,sha256=tub8_1QBu0nWAaGnBWp2nErOW-SOHf_UL6qjOSGbnxU,31026
|
|
37
39
|
ScriptCollection/TFCPS/TFCPS_BuildCodeUnitsHook.py,sha256=67_DQwoH5bhxxSmwtuAeoW1NOCMiLMzOy48OqlJX-KY,1744
|
|
38
40
|
ScriptCollection/TFCPS/TFCPS_CodeUnitSpecific_Base.py,sha256=umUfQDErp7xFLkDnSbQMxzUWnKtcGlrZnIvFcTpfGJs,40499
|
|
39
41
|
ScriptCollection/TFCPS/TFCPS_CodeUnit_BuildCodeUnit.py,sha256=Mj9t1SyRpkYZE74cLsGWYv4xB89gXL2ld-RX3xvvGdw,9835
|
|
40
|
-
ScriptCollection/TFCPS/TFCPS_CodeUnit_BuildCodeUnits.py,sha256=
|
|
42
|
+
ScriptCollection/TFCPS/TFCPS_CodeUnit_BuildCodeUnits.py,sha256=DOD4U0TrlUc5uqhr7VTajmuLE6C7cj_gjty8i6px_yg,50626
|
|
41
43
|
ScriptCollection/TFCPS/TFCPS_CreateRelease.py,sha256=kpEmSnfzfgB4OjcCuS_X6jgW_ftcphxEnjjoLoAHTLY,6582
|
|
42
44
|
ScriptCollection/TFCPS/TFCPS_Generic.py,sha256=mRBcf7XuNWOSXbZYc3NuJow18AMZ30D6Z-BtyNYfNcM,2072
|
|
43
45
|
ScriptCollection/TFCPS/TFCPS_MergeToMain.py,sha256=Krt5oyGNcRAN3szsgU7LoTh8yVTOdHW-Kq7R9MDDV-Q,7673
|
|
@@ -57,22 +59,22 @@ ScriptCollection/TFCPS/DotNet/CertificateGeneratorInformationGenerate.py,sha256=
|
|
|
57
59
|
ScriptCollection/TFCPS/DotNet/CertificateGeneratorInformationNoGenerate.py,sha256=i0zEGehj0sttxjjZtoq2KFSKp_ulxVyWp_ZgAhIY_So,241
|
|
58
60
|
ScriptCollection/TFCPS/DotNet/TFCPS_CodeUnitSpecific_DotNet.py,sha256=GCFzDNAnmm40EeqOYgD_EeuEwDY58ujwJ1-Zn_naamc,61797
|
|
59
61
|
ScriptCollection/TFCPS/DotNet/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
60
|
-
ScriptCollection/TFCPS/Flutter/TFCPS_CodeUnitSpecific_Flutter.py,sha256=
|
|
62
|
+
ScriptCollection/TFCPS/Flutter/TFCPS_CodeUnitSpecific_Flutter.py,sha256=R-Ldc6XaPETgwrgGqcX3sJ52bDUabusv3MFmFCHCvGY,58340
|
|
61
63
|
ScriptCollection/TFCPS/Flutter/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
62
64
|
ScriptCollection/TFCPS/Go/TFCPS_CodeUnitSpecific_Go.py,sha256=m4Pax-U6o5XuspLnLfnWjyQMtoC7zBDDNJW9EhLWjeE,9012
|
|
63
65
|
ScriptCollection/TFCPS/Go/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
64
66
|
ScriptCollection/TFCPS/Maven/TFCPS_CodeUnitSpecific_Maven.py,sha256=HDZlU70lF4nxUgsi7-TaFrFpbw_imw6dBagfgL6tDW8,10593
|
|
65
67
|
ScriptCollection/TFCPS/Maven/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
66
|
-
ScriptCollection/TFCPS/NodeJS/TFCPS_CodeUnitSpecific_NodeJS.py,sha256=
|
|
68
|
+
ScriptCollection/TFCPS/NodeJS/TFCPS_CodeUnitSpecific_NodeJS.py,sha256=U2J_jZxy9-tJdShx_bhDkASgDbkL0BsHGtDdEYFhb7o,16534
|
|
67
69
|
ScriptCollection/TFCPS/NodeJS/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
68
70
|
ScriptCollection/TFCPS/Python/TFCPS_CodeUnitSpecific_Python.py,sha256=Wi9anRljuvW1-UplYhI_QNR2szxaitHiXVJ6p4nUEI8,21089
|
|
69
71
|
ScriptCollection/TFCPS/Python/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
70
72
|
ScriptCollection/TFCPS/Rust/TFCPS_CodeUnitSpecific_Rust.py,sha256=yyjWPMHQjPLkMLlfjrOjhEieFEW_PDm7RWbs4I1TWWY,12275
|
|
71
73
|
ScriptCollection/TFCPS/Rust/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
72
|
-
ScriptCollection/TFCPS/TypeScript/TFCPS_CodeUnitSpecific_TypeScript.py,sha256=
|
|
74
|
+
ScriptCollection/TFCPS/TypeScript/TFCPS_CodeUnitSpecific_TypeScript.py,sha256=ILVhJHvwG5TvPBBqSvyACYb7W9QnWrJpxKgHu8IQu4g,9249
|
|
73
75
|
ScriptCollection/TFCPS/TypeScript/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
74
|
-
scriptcollection-4.4.
|
|
75
|
-
scriptcollection-4.4.
|
|
76
|
-
scriptcollection-4.4.
|
|
77
|
-
scriptcollection-4.4.
|
|
78
|
-
scriptcollection-4.4.
|
|
76
|
+
scriptcollection-4.4.36.dist-info/METADATA,sha256=57adtdGzdU5J1VzI3KzV9XVpbUoNLjppxnOB7PS6Kv0,7646
|
|
77
|
+
scriptcollection-4.4.36.dist-info/WHEEL,sha256=YVMoNqKzERt-wjUZwJ33xBGAwnFl-4cqbYkTtWa4itE,91
|
|
78
|
+
scriptcollection-4.4.36.dist-info/entry_points.txt,sha256=GNma7tN0J59EvK71su-G1w22RnZ05bXcPrELyLx3AL0,6151
|
|
79
|
+
scriptcollection-4.4.36.dist-info/top_level.txt,sha256=hY2hOVH0V0Ce51WB76zKkIWTUNwMUdHo4XDkR2vYVwg,17
|
|
80
|
+
scriptcollection-4.4.36.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|