Skip to content

Commit f4edd82

Browse files
committed
move helpers to tools/
1 parent 7599ec4 commit f4edd82

5 files changed

Lines changed: 5 additions & 16 deletions

File tree

Makefile

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -212,12 +212,13 @@ fix-metadata-version:
212212
# .....................
213213

214214
copy:
215-
cp -v ../docker-mirror-packages-repo/docker_mirror.py .
216-
cp -v ../docker-mirror-packages-repo/docker_mirror.pyi .
217-
cp -v ../docker-mirror-packages-repo/docker_image.py .
215+
cp -v ../docker-mirror-packages-repo/docker_mirror.py tools/
216+
cp -v ../docker-mirror-packages-repo/docker_mirror.pyi tools/
217+
cp -v ../docker-mirror-packages-repo/docker_image.py tools/
218218

219219
LOCAL=--local
220-
DOCKER_IMAGE = ./docker_image.py $(LOCAL)
220+
DOCKER_IMAGE_PY = ./tools/docker_image.py
221+
DOCKER_IMAGE = $(PYTHON3) $(DOCKER_IMAGE_PY) $(LOCAL)
221222

222223
python27: $(CONTAINER)/test27
223224
python36: $(CONTAINER)/test36

tests/exectests3.py

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -43,9 +43,6 @@
4343
STRIP="src/strip_python3.py"
4444
VV="-vv"
4545

46-
_maindir = os.path.dirname(sys.argv[0])
47-
_mirror = os.path.join(_maindir, "docker_mirror.py")
48-
4946
def decodes(text: Union[str, bytes, None]) -> str:
5047
if text is None: return ""
5148
if isinstance(text, bytes):
@@ -173,15 +170,6 @@ def get_caller_caller_name() -> str:
173170
frame = currentframe.f_back.f_back.f_back # type: ignore[union-attr]
174171
return frame.f_code.co_name # type: ignore[union-attr]
175172

176-
def detect_local_system() -> str:
177-
""" checks the controller host (a real machine / your laptop)
178-
and returns a matching image name for it (docker style) """
179-
docker = DOCKER
180-
mirror = _mirror
181-
cmd = F"{mirror} detect"
182-
run = X(cmd)
183-
return decodes(run.stdout).strip()
184-
185173
def packages_refresh_tool() -> str:
186174
return "apt-get -o Acquire::AllowInsecureRepositories=true update"
187175

File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)