Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename files and folders #43

Closed
fabri9532 opened this issue Apr 28, 2020 · 6 comments
Closed

Rename files and folders #43

fabri9532 opened this issue Apr 28, 2020 · 6 comments
Assignees
Milestone

Comments

@fabri9532
Copy link

Is there a method to rename files and folders inside the compressed file?
If it doesn't exist, can it be implemented?

Fabrizio.

@rikyoz rikyoz self-assigned this May 2, 2020
@rikyoz
Copy link
Owner

rikyoz commented May 4, 2020

Hi Fabrizio!
Unfortunately, at the moment there is no such method.
However, it should be possible to implement such a feature, even though it may require quite a few changes in both the external API and internal code of bit7z.
Hopefully, I'll be able to implement it in the next stable version.
Riccardo

@fabri9532
Copy link
Author

Thank you! Riccardo.

Fabrizio.

@rikyoz rikyoz added this to the v4.0 milestone May 6, 2020
@msghera
Copy link

msghera commented Nov 3, 2020

Is this thread still open for contribution ?

@rikyoz
Copy link
Owner

rikyoz commented Nov 4, 2020

Hi! Yeah, sure!
I'm still working on implementing this feature; unfortunately, it requires a lot of changes in the internal code of bit7z.
During these last months, I've been busy with my main job, but now I'm going back to work on bit7z.
I hope to finish this and the other pending features asap.
Anyway, I'm open to any helpful contribution!

@msghera
Copy link

msghera commented Nov 5, 2020

If the task is huge, you can share or I am find new areas for contribution.

rikyoz added a commit that referenced this issue Jan 3, 2021
Lots of refactoring of the internal classes are still needed.
Close issue #43.
rikyoz added a commit that referenced this issue Sep 4, 2021
Lots of refactoring of the internal classes are still needed.
Close issue #43.
@rikyoz
Copy link
Owner

rikyoz commented Oct 2, 2023

Implemented in v4.0.0.

Now the BitArchiveEditor can be used for renaming/deleting files and folders inside archives.

Example:

BitArchiveEditor editor{ lib, "path/to/archive.7z", BitFormat::SevenZip };

// Set compressed_file1.txt to be renamed as compressed_file.txt.
editor.renameItem("compressed_file1.txt", "compressed_file.txt"); 

// Set folder/compressed_file2.txt to be deleted from the archive.
editor.deleteItem("folder/compressed_file2.txt");

// Applying the requested changes
editor.applyChanges();

@rikyoz rikyoz closed this as completed Oct 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants