Skip to content

Protection from copying a directory into itself #894

@DanViTrinh

Description

@DanViTrinh

Please describe the problem you're trying to solve

240410_16h23m30s_screenshot

cp has protection against copying a directory into itself.

240410_16h23m56s_screenshot

This is not present in yazi resulting in an operation running forever.
Of course you could just quit yazi, so it is not an urgent feature, just a nice addition to yazi.

Would you be willing to contribute this feature?

  • Yes, I'll give it a shot

Describe the solution you'd like

A warning message when you are about to copy a directory into itself.

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions