feat: rename and move in file manager#630
Conversation
|
I mention that in the PR. I think it's better to just rebuild the index than to migrate, it just adds extra maintenance and complexity. |
True, I missed it! |
Would you like to collaborate on building a new index solution? |
|
that could work. Let's wait and hear what @daveallie has to say and go from there. |
|
Tested on device. Moving and renaming files both seem to work exactly as expected, and old versions are removed from Recent files view (which I regard as a feature rather than a bug, especially since there's no other obvious way to get something off the Recents list. Thank you! 🎉 |
lukestein
left a comment
There was a problem hiding this comment.
My approval based on on-device testing. (I've done no code review.)
* master: feat: add shift lock to KeyboardEntryActivity (crosspoint-reader#513) feat: rename and move in file manager (crosspoint-reader#630) feat: Implement fix for sunlight fading issue (crosspoint-reader#603) chore: Add PR title check on sync (crosspoint-reader#698) feat: Go To Position for epubs (crosspoint-reader#666) feat: Calibre Web Automated (CWA) koreader sync server support (crosspoint-reader#594) chore: Add CI check job to consolidate status (crosspoint-reader#696) chore: CI Build Summary - firmware stats, firmware artifact (crosspoint-reader#601) feat: quick rotate option in epub reader menu (crosspoint-reader#685) feat(settings): add "Cover + Custom" sleep screen mode (crosspoint-reader#582) fix: Artifacts on Thumb on Home Screen (crosspoint-reader#662) feat: holding back button while booting, boots to home screen as a mean of escaping boot loop (crosspoint-reader#587) docs: Add small SCOPE.md and GOVERNANCE.md documents (crosspoint-reader#640) feat: front button remapper (crosspoint-reader#664) feat: UI themes, Lyra (crosspoint-reader#528) feat: Add CSS parsing and CSS support in EPUBs (crosspoint-reader#411) fix: move http upload state to heap (crosspoint-reader#657)
|
Was it planned to be able to rename folders too? Or only files? |
## Summary * **What is the goal of this PR?** (e.g., Implements the new feature for file uploading.) This adds renaming and moving files to the File Manager * **What changes are included?** New `/move` and `/rename` endpoints, and corresponding modals and icons added. Uses the `file.rename()` function, after sanity checking. ## Additional Context * Add any other information that might be helpful for the reviewer (e.g., performance implications, potential risks, specific areas to focus on). Fixes crosspoint-reader#559, crosspoint-reader#661, crosspoint-reader#663. Only touches the File Manager, so low risk of affecting other systems. Simpler than crosspoint-reader#619, at the cost of not migrating the cache of renamed books. <img width="870" height="437" alt="image" src="https://github.com/user-attachments/assets/73e0e750-dfc8-48e0-a7a6-9694470b7ded" /> <img width="575" height="318" alt="image" src="https://github.com/user-attachments/assets/38c5fb19-c38a-436b-b3ad-75c1be7375ab" /> <img width="574" height="293" alt="image" src="https://github.com/user-attachments/assets/1d2a2403-765d-473f-8c4f-c6968e9bbfeb" /> --- ### AI Usage While CrossPoint doesn't have restrictions on AI tools in contributing, please be transparent about their usage as it helps set the right context for reviewers. Did you use AI tools to help write this code? _**YES**_ I used Codex for the implementation itself, and then carefully reviewed the code myself. As this is a simple change and only to the webserver, it is low risk.
Summary
This adds renaming and moving files to the File Manager
New
/moveand/renameendpoints, and corresponding modals and icons added. Uses thefile.rename()function, after sanity checking.Additional Context
specific areas to focus on).
Fixes #559, #661, #663. Only touches the File Manager, so low risk of affecting other systems.
Simpler than #619, at the cost of not migrating the cache of renamed books.
AI Usage
While CrossPoint doesn't have restrictions on AI tools in contributing, please be transparent about their usage as it
helps set the right context for reviewers.
Did you use AI tools to help write this code? YES
I used Codex for the implementation itself, and then carefully reviewed the code myself. As this is a simple change and only to the webserver, it is low risk.