serokell / coffer

Multi-backend password store with multiple frontends
4 stars 2 forks source link

[#22] Copy with equal paths behavior fix #78

Closed sancho20021 closed 2 years ago

sancho20021 commented 2 years ago

Description

Problem

Currently copying entry / directory to itself is allowed in force mode.

This copying is very unnecessary, we can't see such behavior in standard Unix cp command. The same applies to renaming entries to it's current name.

Solution

Check qualified paths for equality before copying.

Related issue(s)

Fixed #22

:white_check_mark: Checklist for your Pull Request

Related changes (conditional)

Stylistic guide (mandatory)

dcastro commented 2 years ago

Please turn on trimming trailing whitespace in your editor.

This. I think you're using vscode, right? If so, you can add this to your preferences:

    "files.insertFinalNewline": true,
    "files.trimFinalNewlines": true,
    "files.trimTrailingWhitespace": true,
sancho20021 commented 2 years ago

Yes, thanks! Didn't have that in my configuration

dcastro commented 2 years ago

There's an issue with the xrefcheck step in the pipeline, @DK318 is working on it (see #79).

Once his PR is merged, please rebase your branch on top of main, and the pipeline for your PR should start passing.