Skip to content
Snippets Groups Projects
Commit f6f14961 authored by Christopher Spinrath's avatar Christopher Spinrath
Browse files

image_umount_if: unount only if something is mounted

parent 0db3d3b8
No related branches found
No related tags found
No related merge requests found
......@@ -493,8 +493,10 @@ image_mount_if : $(IMAGE_PART_FILE)
[ "$$(findmnt --target "$(IMAGE_DIR)" -f -n --output=target)" = "$(IMAGE_DIR)" ] \
|| mount "$(IMAGE_PART_FILE)" "$(IMAGE_DIR)"
image_umount :
umount -d "$(IMAGE_DIR)"
image_umount_if :
#if something is mounted then umount
[ "$$(findmnt --target "$(IMAGE_DIR)" -f -n --output=target)" != "$(IMAGE_DIR)" ] \
|| umount -d "$(IMAGE_DIR)"
image : image_content $(GRUB_ASSEMBLE_DIR)/mbr.img
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment