mirror of
https://gitlab.com/kupfer/kupferbootstrap.git
synced 2025-02-23 05:35:44 -05:00
image/flash: give user output while copying image for shrinking
This commit is contained in:
parent
efe4bf085d
commit
ad80b3e889
1 changed files with 2 additions and 1 deletions
|
@ -1,6 +1,7 @@
|
|||
import shutil
|
||||
import os
|
||||
import click
|
||||
import logging
|
||||
|
||||
from typing import Optional
|
||||
|
||||
|
@ -49,7 +50,7 @@ def test_blockdev(path: str):
|
|||
def prepare_minimal_image(source_path: str, sector_size: int) -> str:
|
||||
minimal_image_dir = get_temp_dir(register_cleanup=True)
|
||||
minimal_image_path = os.path.join(minimal_image_dir, f'minimal-{os.path.basename(source_path)}')
|
||||
|
||||
logging.info(f"Copying image {os.path.basename(source_path)} to {minimal_image_dir} for shrinking")
|
||||
shutil.copyfile(source_path, minimal_image_path)
|
||||
|
||||
loop_device = losetup_rootfs_image(minimal_image_path, sector_size)
|
||||
|
|
Loading…
Add table
Reference in a new issue