Use variable to improve readability #5

Closed
opened 2024-07-11 18:28:05 +02:00 by GuilloteauQ · 0 comments
Owner

ecg.py Lines 145 to 146 in 2f779d0ab0
pkglist_process = subprocess.run(["docker", "run", "--rm", config["image_name"]] + pkgmgr_cmd[pkgmgr][0].split(" "), cwd=path, capture_output=True)
format_process = subprocess.run("cat << EOF | " + pkgmgr_cmd[pkgmgr][1] + "\n" + pkglist_process.stdout.decode("utf-8") + "EOF", cwd=path, capture_output=True, shell=True)

Create a variable to store pkgmgr_cmd[pkgmgr][1] and pkgmgr_cmd[pkgmgr][0] to improve readability

https://forge.chapril.org/GuilloteauQ/study-docker-repro-longevity/src/commit/2f779d0ab09ef81681999c91cfd9f3f27ab621ea/ecg.py#L145-L146 Create a variable to store `pkgmgr_cmd[pkgmgr][1]` and `pkgmgr_cmd[pkgmgr][0]` to improve readability
Sign in to join this conversation.
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: GuilloteauQ/study-docker-repro-longevity#5
No description provided.