feat(library): add bulk rename tool and e2e coverage#124
Merged
neonsolstice merged 4 commits intoMay 28, 2026
Conversation
Provides a way to rename all books in a library according to the user's configured file naming template without requiring manual metadata edits. Includes a streaming endpoint to report progress back to the frontend. Closes bookorbit#121
Introduce a comprehensive E2E test suite for the bulk rename functionality to verify behavior across different library modes (book per file, book per folder) and handle edge cases like naming collisions or special characters. Additionally fix a TypeScript compilation error in BulkRenameView.vue by replacing `replaceAll` with a regex-based `replace` for broader target compatibility.
|
🎉 This PR is included in version 1.7.0 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What does this PR do?
Adds a full bulk file rename workflow for libraries that have file rename enabled, including preview, execution, status tracking, and coverage tests.
This PR includes:
GET /api/v1/libraries/:id/bulk-rename/previewGET /api/v1/libraries/:id/bulk-rename/statusPOST /api/v1/libraries/:id/bulk-rename/execute(SSE progress stream)replaceAllreplaced with regex-basedreplace).Closes #121
How did you test this?
git push -u origin BO-121-bulk-rename-bookspnpm run verify:fastlint:check+typecheck)pnpm --filter server test -- src/modules/library/bulk-rename.service.test.ts src/modules/file-write/file-rename.service.test.ts458 passedtest files,5428 passedtests.pnpm --filter client test:unit --run src/features/tools/composables/__tests__/useBulkRename.spec.ts src/features/tools/bulk-rename/components/__tests__/BulkRenameConfirmDialog.spec.ts src/features/tools/bulk-rename/components/__tests__/BulkRenameStatusBadge.spec.ts3 passedtest files,35 passedtests.Anything non-obvious in the diff?
runningLibrariesguard).Checklist
.env, personal configs)