bug: copy_dir does not copy subdirectories #20

Closed
opened 2026-05-25 17:50:04 +02:00 by michael · 1 comment
Owner

Problem

M.copy_dir copies only top-level files -- subdirectories are ignored.
The function name implies a full recursive copy.

Options

  • Rename to copy_dir_flat to make the limitation explicit
  • Or implement recursive copy (reuse find_recursive internally)

Needs decision before fix.

## Problem `M.copy_dir` copies only top-level files -- subdirectories are ignored. The function name implies a full recursive copy. ## Options - Rename to `copy_dir_flat` to make the limitation explicit - Or implement recursive copy (reuse `find_recursive` internally) Needs decision before fix.
Author
Owner

Implemented full recursive copy (reused list_dirs, per the issue's second option) rather than renaming to copy_dir_flat. copy_dir now recurses into subdirectories via mkdir_p + recursive self-call. Tested with a two-level-deep tree in test_fs.lua.

Implemented full recursive copy (reused list_dirs, per the issue's second option) rather than renaming to copy_dir_flat. copy_dir now recurses into subdirectories via mkdir_p + recursive self-call. Tested with a two-level-deep tree in test_fs.lua.
michael 2026-07-19 17:55:43 +02:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
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
DAW/daw-lua-common#20
No description provided.