Skip to content

bug: extract --force flag is ignored (always overwrites) #77

@bug-ops

Description

@bug-ops

Summary

The --force flag on the extract subcommand is parsed by clap but never read in commands/extract.rs. The result is that extraction always overwrites existing files silently, regardless of whether --force is passed.

Reproduction

mkdir dest
echo "original" > dest/file.txt
exarch extract archive.tar.gz dest/   # overwrites without --force — should fail or warn
exarch extract --force archive.tar.gz dest/  # same behavior as above

Expected behavior

Without --force: if any destination file already exists, extraction should fail with a clear error.
With --force: silently overwrite.

Root cause

crates/exarch-cli/src/commands/extract.rs does not reference args.force at all.
crates/exarch-cli/src/commands/create.rs implements the pattern correctly for reference.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingcoreChanges to exarch-core

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions