From d9fb21595a1b14d28370e1f9eb9bca8593757548 Mon Sep 17 00:00:00 2001 From: sxyazi Date: Mon, 10 Feb 2025 00:23:56 +0800 Subject: [PATCH] feat: support SD card partitions, closes #63 --- mount.yazi/main.lua | 2 ++ 1 file changed, 2 insertions(+) diff --git a/mount.yazi/main.lua b/mount.yazi/main.lua index a6a2dbd..ed91944 100644 --- a/mount.yazi/main.lua +++ b/mount.yazi/main.lua @@ -181,6 +181,8 @@ function M.obtain() main, sub = p.src:match("^(/dev/disk%d+)(.+)$") elseif p.src:find("/dev/nvme", 1, true) == 1 then -- /dev/nvme0n1p1 main, sub = p.src:match("^(/dev/nvme%d+n%d+)(p%d+)$") + elseif p.src:find("/dev/mmcblk", 1, true) == 1 then -- /dev/mmcblk0p1 + main, sub = p.src:match("^(/dev/mmcblk%d+)(p%d+)$") elseif p.src:find("/dev/sd", 1, true) == 1 then -- /dev/sda1 main, sub = p.src:match("^(/dev/sd[a-z])(%d+)$") end